cancel
Showing results for 
Search instead for 
Did you mean: 

CEC HDMI hanshaking example and bug in MX report

MM..1
Chief III

First bug, i start testing CEC on F051DISCO . Open MX create config for KEIL v5 and generate code.

After build and load i spent some hours to locate why code dont receive and hangs. 

Elaborate bad generated startus assembler file where is IRQ named CEC_IRQHandler,

but in code IT !!! void CEC_CAN_IRQHandler(void)

 

And now handshaking code question. Examples in folder firmware is not usable in real life. Can ST or anybody provide CEC for example version 1.4 code with coments... CEC is multidevices bus and developer dont have environment to check and test conflicts etc.

2 REPLIES 2
Piranha
Chief II
  1. The code architecture is amateurish.
  2. They call HAL_CEC_Transmit_IT(), but do not check the return value.
  3. The HAL_CEC_Transmit_IT() itself checks the state outside of the critical section.
  4. The critical section ("HAL lock") itself has been broken since the beginning and ST doesn't give a jack about it.

 

The startup file names the IRQ as CEC_IRQHandler, but in the code, the function definition is void CEC_CAN_IRQHandler(void). This discrepancy might be causing the code not to function correctly.