comparison code_part1/OSTC_code_asm_part1/menu_gassetup.asm @ 304:ed08d441ed26

Backed out changeset: 9c39cedb662b
author heinrichsweikamp
date Sat, 30 Apr 2011 14:09:38 +0200
parents 9c39cedb662b
children d36fe3651d56
comparison
equal deleted inserted replaced
303:9c39cedb662b 304:ed08d441ed26
334 334
335 ; Show END in m 335 ; Show END in m
336 lfsr FSR2, letter 336 lfsr FSR2, letter
337 WIN_LEFT .90 337 WIN_LEFT .90
338 OUTPUTTEXTH .298 ; END: 338 OUTPUTTEXTH .298 ; END:
339 339 GETCUSTOM8 .18 ; ppO2 warnvalue in WREG
340 rcall gassetup_get_mod ; compute MOD based on CF18 into lo:hi 340 mullw d'10'
341 movff PRODL,xA+0
342 movff PRODH,xA+1 ; ppO2 in [0.01Bar] * 10
343 movf divemins+0,W
344 addlw 0x06
345 movwf EEADR
346 call read_eeprom ; O2 value
347 movff EEDATA,xB+0
348 clrf xB+1
349 call div16x16 ; xA/xB=xC with xA as remainder
350 movlw d'10'
351 subwf xC+0,F ; Subtract 10m...
352 movff xC+0,lo
353 movlw d'0'
354 subwfb xC+1,F
355 movff xC+1,hi ; lo:hi holding MOD in meters
341 movlw d'10' 356 movlw d'10'
342 addwf lo,F 357 addwf lo,F
343 movlw d'0' 358 movlw d'0'
344 addwfc hi,F ; lo:hi holding MOD+10m 359 addwfc hi,F ; lo:hi holding MOD+10m
345 360