Mercurial > public > hwos_code
comparison src/ghostwriter.asm @ 23:e402813343b6
new option to switch samplingrate between 10s and 2s
author | heinrichsweikamp |
---|---|
date | Mon, 08 Jul 2013 12:38:16 +0200 |
parents | 13cda523891f |
children | eca4a201d8cf |
comparison
equal
deleted
inserted
replaced
22:e01c39be267c | 23:e402813343b6 |
---|---|
577 movf batt_voltage+0,W ; Battery voltage | 577 movf batt_voltage+0,W ; Battery voltage |
578 rcall ghostwrite_byte_header | 578 rcall ghostwrite_byte_header |
579 movf batt_voltage+1,W | 579 movf batt_voltage+1,W |
580 rcall ghostwrite_byte_header | 580 rcall ghostwrite_byte_header |
581 | 581 |
582 movlw samplingrate ; Sampling rate | 582 movf samplingrate,W ; Sampling rate |
583 btfsc FLAG_apnoe_mode ; Apnoe mode? | 583 btfsc FLAG_apnoe_mode ; Apnoe mode? |
584 movlw samplingrate_apnoe ; Apnoe sampling rate | 584 movlw samplingrate_apnoe ; Apnoe sampling rate |
585 rcall ghostwrite_byte_header ; WREG -> Header in ext. flash | 585 rcall ghostwrite_byte_header ; WREG -> Header in ext. flash |
586 | 586 |
587 ; CNS at gebinning of dive | 587 ; CNS at gebinning of dive |
588 movff CNS_start+0,WREG | 588 movff CNS_start+0,WREG |
589 rcall ghostwrite_byte_header ; WREG -> Header in ext. flash | 589 rcall ghostwrite_byte_header ; WREG -> Header in ext. flash |
802 movlw 0xFA | 802 movlw 0xFA |
803 rcall ghostwrite_byte_profile ; WREG -> Profile in ext. flash | 803 rcall ghostwrite_byte_profile ; WREG -> Profile in ext. flash |
804 ; Keep room for dive length ext_flash_dive_counter:3 (Stored at the end of the dive) | 804 ; Keep room for dive length ext_flash_dive_counter:3 (Stored at the end of the dive) |
805 incf_ext_flash_address_0x20 d'3' ; Skip Bytes in external flash (faster) | 805 incf_ext_flash_address_0x20 d'3' ; Skip Bytes in external flash (faster) |
806 | 806 |
807 movlw samplingrate ; Sampling rate | 807 movf samplingrate,W ; Sampling rate |
808 btfsc FLAG_apnoe_mode ; Apnoe mode? | 808 btfsc FLAG_apnoe_mode ; Apnoe mode? |
809 movlw samplingrate_apnoe ; Apnoe sampling rate | 809 movlw samplingrate_apnoe ; Apnoe sampling rate |
810 rcall ghostwrite_byte_profile ; WREG -> Profile in ext. flash | 810 rcall ghostwrite_byte_profile ; WREG -> Profile in ext. flash |
811 | 811 |
812 movlw .7 ; Number of divisors | 812 movlw .7 ; Number of divisors |