Today, we started to code for our board. The switching power supplies are working well and controlled by the STM32. Interrupts are generated if they are not stable. Everything went fine… Until we tried to implement the serial over USB module, and the shell. We were stuck for a loooooong moment. Impossible to obtain anything. It was like the STM32 was not connected to the laptop. We confirmed that it was not an hardware issue by communicating with the preinstalled USB bootloader of the STM32.
After checking the schematic, we (Thanks for all Dryvenn) pointed out the problem. The PA9 is the default pin for VBUS. Ours is connected to the buzzer, with a pull-down resistor. As the STM32 couldn’t detect if any cable was plug-in, it have never engaged the communication.
The problem is solved by defining the symbol BOARD_OTG_NOVBUSSENS in board.h. Now we have to manage the cable detection “manually” with interrupts.