Fix crc routine to use buffered reads on stm32.
Wrap target methods with functions instead of macros.