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

Start on new decogas display
author heinrichsweikamp
date Sat, 30 Nov 2013 20:41:43 +0100
parents 3096294bb06e
children cc997dde80cf
line wrap: on
line diff
--- a/code_part1/OSTC_code_asm_part1/outputs.asm	Tue Nov 26 12:11:23 2013 +0100
+++ b/code_part1/OSTC_code_asm_part1/outputs.asm	Sat Nov 30 20:41:43 2013 +0100
@@ -890,6 +890,80 @@
 	STRCAT_PRINT " "
 	return
 
+
+DISP_show_deco_gas:                 ; Show the next decogas
+	WIN_LEFT	.90
+	WIN_FONT 	FT_SMALL
+	WIN_INVERT	.0					; Init new Wordprocessor
+    call    DISP_divemask_color     ; Set Color for Divemode mask
+    DISPLAYTEXTH .270               ; Decogas
+
+DISP_show_deco_gas1:
+	WIN_LEFT	.90
+	WIN_FONT 	FT_SMALL
+	WIN_INVERT	.0					; Init new Wordprocessor
+    call    DISP_standard_color
+	WIN_TOP		.192
+    movff       char_O_deco_gas+0,lo
+    tstfsz      lo              ; =0?
+    bra         $+4             ; No
+    bra     DISP_show_deco_gas2
+    incf        lo,F            ;+1
+    STRCPY  TXT_GAS1            ; "G"
+    bsf     leftbind
+    output_8
+    STRCAT  TXT_AT4             ; " at "
+    movlw   .27                 ; 28=Gas 1
+    addwf   lo,W
+    movwf   EEADR
+    clrf    EEADRH              ; Get Change depth
+    call    read_eeprom
+    movff   EEDATA,lo
+    tstfsz      lo              ; =0?
+    bra     $+4                 ; No
+    bra     DISP_show_deco_gas2
+    output_8                    ; Change depth
+    bcf     leftbind
+    STRCAT  "m "
+    clrf    WREG
+    movff   WREG,letter+9       ; Limit to 8 chars
+    STRCAT_PRINT  ""
+
+	WIN_TOP		.216
+    movff       char_O_deco_gas+1,lo
+    tstfsz      lo              ; =0?
+    bra     $+4                 ; No
+    bra     DISP_show_deco_gas3
+    incf        lo,F            ;+1
+    STRCPY  TXT_GAS1            ; "G"
+    bsf     leftbind
+    output_8
+    STRCAT  TXT_AT4             ; " at "
+    movlw   .27                 ; 28=Gas 1
+    addwf   lo,W
+    movwf   EEADR
+    clrf    EEADRH              ; Get Change depth
+    call    read_eeprom
+    movff   EEDATA,lo
+    tstfsz      lo              ; =0?
+    bra     $+4                 ; No
+    bra     DISP_show_deco_gas3
+    output_8                    ; Change depth
+    bcf     leftbind
+    STRCAT  "m "
+    clrf    WREG
+    movff   WREG,letter+9       ; Limit to 8 chars
+    STRCAT_PRINT  ""
+    return
+
+DISP_show_deco_gas2:
+    WIN_BOX_BLACK   .192, .239, .90, .159		;top, bottom, left, right
+    return
+
+DISP_show_deco_gas3:
+    WIN_BOX_BLACK   .216, .239, .90, .159		;top, bottom, left, right
+    return
+
 DISP_show_gf_customview:
 	WIN_LEFT	.93
 	WIN_FONT 	FT_SMALL