Mercurial > public > mk2
diff code_part1/OSTC_code_asm_part1/start.asm @ 362:64da813d4726 64kByte Logbook
Logbook converter (Needs ~8Minutes and is called one time). Backup your dives before use!!
author | Heinrichsweikamp |
---|---|
date | Wed, 08 Jun 2011 19:47:18 +0200 |
parents | 91352bb698cf |
children | 93a64a19728e |
line wrap: on
line diff
--- a/code_part1/OSTC_code_asm_part1/start.asm Wed Jun 08 01:37:14 2011 +0200 +++ b/code_part1/OSTC_code_asm_part1/start.asm Wed Jun 08 19:47:18 2011 +0200 @@ -40,6 +40,7 @@ start3: clrf STKPTR ; Clear Stackpointer lfsr FSR0,year+1 ; Clear rambank 1-9, do not delete RTC registers +delete RTC registers clear_rambank: clrf POSTINC0 movlw 0x0A @@ -224,6 +225,16 @@ cpfseq EEDATA bcf debug_mode ; clear flag if <> 1 +; Check if logbook has been converted already (Internal EEPROM 0x100=0xAA) + movlw LOW 0x100 + movwf EEADR + movlw HIGH 0x100 + movwf EEADRH + call read_eeprom ; read byte + movlw 0xAA + cpfseq EEDATA ; is 0xAA already? + call logbook_convert_64k ; No, convert now (And write 0xAA to internal EEPROM 0x100) + goto surfloop ; Jump to Surfaceloop!