added function to compute CRC16 on flash data