Mercurial > public > hwos_code
comparison src/divemode.asm @ 385:b075fa71b659
BUGFIX: +5min for stopwatch during simulation did not work
author | heinrichsweikamp |
---|---|
date | Wed, 07 Oct 2015 13:14:09 +0200 |
parents | 6f3530eb48f9 |
children | 3c55627d5f8f |
comparison
equal
deleted
inserted
replaced
384:b62f8b1eaaaa | 385:b075fa71b659 |
---|---|
1033 bcf divemode2 ; Stop divetime | 1033 bcf divemode2 ; Stop divetime |
1034 movlw .5 | 1034 movlw .5 |
1035 addwf divemins+0,F | 1035 addwf divemins+0,F |
1036 movlw .0 | 1036 movlw .0 |
1037 addwfc divemins+1,F ; Add 5 mins | 1037 addwfc divemins+1,F ; Add 5 mins |
1038 movlw LOW (.5*.60) | |
1039 addwf average_divesecs+0,F | |
1040 movlw HIGH (.5*.60) | |
1041 addwfc average_divesecs+1,F ; Add 5*60 seconds | |
1042 movlw LOW (.5*.60) | |
1043 addwf total_divetime_seconds+0,F | |
1044 movlw HIGH (.5*.60) | |
1045 addwfc total_divetime_seconds+1,F ; Add 5*60 seconds | |
1038 movlw .5 | 1046 movlw .5 |
1039 movwf up ; counter | 1047 movwf up ; counter |
1040 ; 1min mode | 1048 ; 1min mode |
1041 divemode_option6_2: | 1049 divemode_option6_2: |
1042 movlw .1 | 1050 movlw .1 |
1390 movff WREG,char_I_first_gas ; Copy for compatibility | 1398 movff WREG,char_I_first_gas ; Copy for compatibility |
1391 rcall setup_dil_registers ; With WREG=Gas 0-4 | 1399 rcall setup_dil_registers ; With WREG=Gas 0-4 |
1392 banksel char_I_first_gas | 1400 banksel char_I_first_gas |
1393 incf char_I_first_gas,F ; 0-4 -> 1-5 | 1401 incf char_I_first_gas,F ; 0-4 -> 1-5 |
1394 banksel common | 1402 banksel common |
1395 rcall calc_deko_divemode_sensor ; External sensor stuff | 1403 call calc_deko_divemode_sensor ; External sensor stuff |
1396 return | 1404 return |
1397 | 1405 |
1398 diveloop_boot: | 1406 diveloop_boot: |
1399 call restart_set_modes_and_flags | 1407 call restart_set_modes_and_flags |
1400 | 1408 |