comparison src/tft_outputs.asm @ 55:448ba265fdae

Change "O2" warning to "ppO2"
author heinrichsweikamp
date Mon, 30 Sep 2013 01:00:07 +0200
parents 7d626c15b577
children 1464cd73d184
comparison
equal deleted inserted replaced
54:7d626c15b577 55:448ba265fdae
1568 movff CCPR1L,lo 1568 movff CCPR1L,lo
1569 output_8 1569 output_8
1570 STRCAT_PRINT "" 1570 STRCAT_PRINT ""
1571 return 1571 return
1572 1572
1573 global TFT_divetimeout ; Show timeout counter
1574 TFT_divetimeout:
1575 call TFT_warning_set_window ; Sets the row and column for the current warning
1576 tstfsz WREG ; Is there room for the warning?
1577 return ; No
1578
1579 call TFT_standard_color
1580 STRCPY 0x94 ; "End of dive" icon
1581 movlw LOW divemode_timeout
1582 movwf sub_a+0
1583 movlw HIGH divemode_timeout
1584 movwf sub_a+1
1585 movff timeout_counter,sub_b+0
1586 movff timeout_counter2,sub_b+1
1587 call subU16 ; sub_c = sub_a - sub_b (with UNSIGNED values)
1588 movff sub_c+0, lo
1589 movff sub_c+1, hi
1590 call convert_time ; converts hi:lo in minutes to hours (hi) and minutes (lo)
1591 movf hi,W
1592 movff lo,hi
1593 movwf lo ; exchange lo and hi
1594 output_99x
1595 PUTC ':'
1596 movff hi,lo
1597 output_99x
1598 movlw warning_length ; Divemode string length
1599 call TFT_fillup_with_spaces ; Fillup FSR2 with spaces (Total string length in #WREG)
1600 STRCAT_PRINT ""
1601 return
1602
1573 global TFT_ftts 1603 global TFT_ftts
1574 TFT_ftts: 1604 TFT_ftts:
1575 movff char_I_extra_time,lo 1605 movff char_I_extra_time,lo
1576 tstfsz lo 1606 tstfsz lo
1577 bra $+4 1607 bra $+4
3261 movwf temp1 3291 movwf temp1
3262 movff temp1,win_bargraph 3292 movff temp1,win_bargraph
3263 call TFT_box 3293 call TFT_box
3264 return 3294 return
3265 3295
3296
3266 global TFT_display_cns 3297 global TFT_display_cns
3267 TFT_display_cns: 3298 TFT_display_cns:
3268 rcall TFT_warning_set_window ; Sets the row and column for the current warning 3299 rcall TFT_warning_set_window ; Sets the row and column for the current warning
3269 tstfsz WREG ; Is there room for the warning? 3300 tstfsz WREG ; Is there room for the warning?
3270 return ; No 3301 return ; No
3288 TFT_display_ppo2: ; Show ppO2 (ppO2 stored in xC, in mbar!) 3319 TFT_display_ppo2: ; Show ppO2 (ppO2 stored in xC, in mbar!)
3289 rcall TFT_warning_set_window ; Sets the row and column for the current warning 3320 rcall TFT_warning_set_window ; Sets the row and column for the current warning
3290 tstfsz WREG ; Is there room for the warning? 3321 tstfsz WREG ; Is there room for the warning?
3291 return ; No 3322 return ; No
3292 TFT_color_code warn_ppo2 ; Color-code output (ppO2 stored in xC) 3323 TFT_color_code warn_ppo2 ; Color-code output (ppO2 stored in xC)
3293 STRCPY "O2:" 3324 STRCPY "ppO2:"
3294 ; Check very high ppO2 manually 3325 ; Check very high ppO2 manually
3295 tstfsz xC+2 ; char_I_O2_ratio * p_amb/10 > 65536, ppO2>6,55bar? 3326 tstfsz xC+2 ; char_I_O2_ratio * p_amb/10 > 65536, ppO2>6,55bar?
3296 bra TFT_show_ppO2_3 ; Yes, display fixed Value! 3327 bra TFT_show_ppO2_3 ; Yes, display fixed Value!
3297 movff xC+0,lo 3328 movff xC+0,lo
3298 movff xC+1,hi 3329 movff xC+1,hi