AnsweredAssumed Answered

Basic Cube project for L476VG, works in IAR, not in TrueStudio

Question asked by pullin.andrew on Sep 21, 2016
Latest reply on Oct 2, 2016 by bauch.aaron.001
Hi there,

I was just struggling to get a really simple bare metal project working for the L476 Discovery board. It would just not work in TrueStudio, where the startup would hang on this line:
     if (HAL_UART_Init(&huart2) != HAL_OK)

As far as I can tell, the huart->gState is not being read correctly; it is reported as a value of 5 (decimal), which the comments for the typedef enum seem to indicate should not be possible.

However, if I regenerate the project for IAR, load, build, and debug, it seems to get past that line with no problem. I haven't done the printf redirection to USART2 yet (don't know how to, actually, feel free to sound off on that too), so I haven't verified if the peripheral is actually working or not. But at least execution gets through to the main loop.

So ... bug? Pretty weird. It would be great if TrueStudio worked since I like that IDE and I really don't want to have to buy IAR :\