diff code_part1/OSTC_code_asm_part1/customview.asm @ 759:ae830d5e63ef

Start on new decogas display
author heinrichsweikamp
date Sat, 30 Nov 2013 20:41:43 +0100
parents 3096294bb06e
children 43ef5a003df7
line wrap: on
line diff
--- a/code_part1/OSTC_code_asm_part1/customview.asm	Tue Nov 26 12:11:23 2013 +0100
+++ b/code_part1/OSTC_code_asm_part1/customview.asm	Sat Nov 30 20:41:43 2013 +0100
@@ -103,6 +103,8 @@
 	bra		customview_1sec_pSCR_ppO2	; Show/Update pSCR ppO2
 	dcfsnz	WREG,F
 	bra		customview_1sec_show_change_gf; Show and/or change GF values
+    dcfsnz	WREG,F
+    bra     customview_1sec_show_deco_gas
 	; Menupos3=0, do nothing
 	return
 
@@ -149,8 +151,11 @@
 
 customview_1sec_pSCR_ppO2:
 	goto	DISP_show_pSCR_ppO2			; Yes, compute and show value
+
+customview_1sec_show_deco_gas:
+    goto    DISP_show_deco_gas1           ; Show the next decogas
+
 	
-
 ;=============================================================================
 ; Do every-minute tasks for the custom view area
 
@@ -178,6 +183,8 @@
 	bra		customview_minute_pSCR_ppO2; Show pSCR ppO2 level
 	dcfsnz	WREG,F
 	bra		customview_minute_show_change_gf; Show and/or change GF values
+    dcfsnz	WREG,F
+    bra     customview_minute_show_deco_gas ; Show the next decogas
 
 	; Menupos3=0, do nothing
 	return
@@ -197,6 +204,7 @@
 customview_minute_average:				; Do nothing extra
 customview_minute_graphs:               ; Do nothing extra
 customview_minute_pSCR_ppO2:            ; Do nothing extra
+customview_minute_show_deco_gas:        ; Do nothing extra
 	return
 
 ;=============================================================================
@@ -211,7 +219,7 @@
 	btfsc	FLAG_apnoe_mode					; In Apnoe mode?
 	bra		customview_toggle_exit			; Yes, ignore custom view in divemode completely
 
-	movlw	d'11'							; Max number
+	movlw	d'12'							; Max number
 	cpfsgt	menupos3			            ; Max reached?
 	bra		customview_mask		            ; No, show
 	clrf	menupos3			            ; Reset to zero (Zero=no custom view)
@@ -243,6 +251,8 @@
 	bra		customview_init_pSCR_ppo2	    ; 10: Show ppO2 for pSCR users
     dcfsnz	WREG,F
 	bra		customview_init_show_change_gf  ; 11: Show and/or change GF values
+    dcfsnz	WREG,F
+	bra		customview_init_show_deco_gas   ; 12: Show deco gas
 
 customview_init_nocustomview:
 	bra		customview_toggle_exit	
@@ -386,6 +396,18 @@
     call        DISP_show_gf_customview ; Show info
     bra         customview_toggle_exit
 
+customview_init_show_deco_gas:
+    bra			customview_toggle		; mH: Ignore now
+
+    btfsc		no_deco_customviews		; no-deco-mode-flag = 1
+	bra			customview_toggle		; Yes, use next Customview!
+    btfsc       FLAG_const_ppO2_mode    ; in ppO2 mode
+    bra         surfcustomview_toggle	; Yes, use next Customview!
+
+    call        DISP_show_deco_gas      ; Show the next decogas
+
+    bra         customview_toggle_exit
+
 customview_toggle_exit:
 	bcf		toggle_customview			; Clear flag
 	ostc_debug	'Y'		                ; Sends debug-information to screen in debugmode