2015-09-29 03:22 AM
I want to set the CR polynomial according to the most top table in http://users.ece.cmu.edu/~koopman/crc/index.html
However STM32CubeMX does not allow to do it due to the following restrictions: ---- CRCPolynomial should respect this format : Xa+Xb+...+Xc. where a,b,c are the powers of the polynomial : - a,b,c should be less than 8. - a,b,c should be odd. ---- Why is this restriction? How can I work around it? The generated function MX_SPI1_Init() does not allow user code in it, so I would have to modify it evertime I run STM32CubeMX generation! I seem not to be the first one with this issue:[DEAD LINK /public/STe2ecommunities/mcu/Lists/STM32Java/Flat.aspx?RootFolder=/public/STe2ecommunities/mcu/Lists/STM32Java/STM32CubeMX%204.9.0%20issues&FolderCTID=0x01200200770978C69A1141439FE559EB459D758000F9A0E3A95BA69146A17C2E80209ADC21]https://my.st.com/public/STe2ecommunities/mcu/Lists/STM32Java/Flat.aspx?RootFolder=%2Fpublic%2FSTe2ecommunities%2Fmcu%2FLists%2FSTM32Java%2FSTM32CubeMX%204.9.0%20issues&FolderCTID=0x01200200770978C69A1141439FE559EB459D758000F9A0E3A95BA69146A17C2E80209ADC21 #crc-stm32cubemx-crcpolynomial2016-01-06 06:13 AM
Hi CaCO3,
Sorry for this delayed answer.I want to keep you informed that the reported issue is already fixed in CubeMX with the last 2 versions.This restriction is wrong. In fact the polynomial has be odd, not its powers.So it should respect the format: X0+Xa+Xb+....+Xc.The powers have to be less tahn 8.-Mayla-To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.