Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
User10696
Level 4
Level 4
First solution authored
We are using the UART to receive standard 8 bit data streams of variable length. These messages have a CCITT CRC-16 bit checksum.
I want to use the FCE module to check the CRC, but it seems the FCE requires 16 bit data and an even number of bytes. Is this correct?
Is there any way to use the FCE with serial UART 8 bit data? The CCITT CRC-16 is the standard CRC for serial interfaces so it seems strange if the FCE cannot be used in this normal situation.
0 Likes
5 Replies
Travis
Employee
Employee
First solution authored Welcome! 500 replies posted
Yes, you can use CRC kernel 3 which offer CRC 8 bit checking.
0 Likes
User10696
Level 4
Level 4
First solution authored
The problem is that the CRC kernel 3 does not use the CCITT CRC 16 polynomial.
I need to enter the data byte (8 bit) wise and then read a 16 CRC.
0 Likes
Travis
Employee
Employee
First solution authored Welcome! 500 replies posted
Hi,

Do you have to do it sequentially for every 8bit? Otherwise you can consider combine 2 x 8bit within an array before the CRC check.
0 Likes
User10696
Level 4
Level 4
First solution authored
I had already thought of that, but some of the messages have an odd number of data bytes, so that does not work.
0 Likes
Travis
Employee
Employee
First solution authored Welcome! 500 replies posted
amanning wrote:
I had already thought of that, but some of the messages have an odd number of data bytes, so that does not work.


Well I think you have to implement some kind of buffering FIFO.
0 Likes