X-Git-Url: http://git.smho.de/gw/?p=owSlave2.git;a=blobdiff_plain;f=common%2FOWRomFunctions.s;fp=common%2FOWRomFunctions.s;h=30731e75aba5ed94455ebe4a87a8cf427967b2f4;hp=eac94b9b292abd480738cdf583d028731668858c;hb=5c60b59e9f305ea8d2e72d62f78ec0d15e3dc42d;hpb=3608ace7dd5bd4fa5d7d49224ef770b21596092c diff --git a/common/OWRomFunctions.s b/common/OWRomFunctions.s index eac94b9..30731e7 100644 --- a/common/OWRomFunctions.s +++ b/common/OWRomFunctions.s @@ -320,8 +320,6 @@ h_fwconfiginfo: cpi r_bytep,17 breq h_fwconfiginfo_all #elif defined _CRC16_ - cpi r_bytep,17 - breq h_fwconfiginfo_crc2 cpi r_bytep,18 breq h_fwconfiginfo_all #else @@ -329,15 +327,23 @@ h_fwconfiginfo: breq h_fwconfiginfo_all #warning No CRC known code implemented #endif +h_fwconfiginfo_end: configZ config_info,r_bytep ld r_rwbyte,Z rjmp handle_end_inc h_fwconfiginfo_crc: +#ifdef _CRC8_ lds r_rwbyte,crc rjmp handle_end_inc -h_fwconfiginfo_crc2: - lds r_rwbyte,crc+1 - rjmp handle_end_inc +#elif defined _CRC16_ + lds r_temp,crc + com r_temp + sts config_info+16,r_temp + lds r_temp,crc+1 + com r_temp + sts config_info+17,r_temp + rjmp h_fwconfiginfo_end +#endif h_fwconfiginfo_all: rjmp handle_end_sleep