Tool/software: Code Composer Studio
CRCDataProcess function always replaces the value in the CCM_CRCDIN register with the next element, so it calculates the CRC for each element and returns the CRC result for the last element only, right?
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Tool/software: Code Composer Studio
CRCDataProcess function always replaces the value in the CCM_CRCDIN register with the next element, so it calculates the CRC for each element and returns the CRC result for the last element only, right?
No, computing a CRC is like doing a sum. The new result is a function of the previous result and the value written to CRCDIN. The previous result is in CRCSEED which needs to be initialized whenever the CRC of a new block of data is to be computed.