Contents
How to make SPI communication between a RPI and a stm32f410?
I trying to make an SPI communication between a RPi (as MASTER) and an STM32F410 (as SLAVE, on a Nucleo board). My PoC is simple, I send 8 bytes from the Rpi and print them out with the UART-over-USB on the Nucleo.
What happens if I send a second usb-stm32 VCP?
If I try to send a second one, the static int8_t CDC_Receive_FS (char* Buf, uint32_t *Len) callback won’t be called, and on the PC RealTerm hangs. My client program hangs too, when it tries to write in the COM port second time. On microntroller side I removed all of my code in CDC_Receive_FS (), it returns currently only USBD_OK.
Is the STM32 VCP firmware generated by cubemx?
I am using STM32 HAL VCP firmware generated by CubeMX on STM32F4 discovery board. The Virtual COM Port works, I can transmit from the microcontroller to the PC as many messages I want.
How to receive CDC FS in USB STM32?
First of all, I had to complete the generated code in static int8_t CDC_Receive_FS (char* Buf, uint32_t *Len) as it is written in the source above. After that I had to create and implement the int VCP_read (void *pBuffer, int size) function, as it is written in the above mentioned source.
Is there a problem with SPI on stm32h7?
I had a trouble with SPI on STM32H7. The issue was that the clock pulses were missing. The last byte had 4-7 clock pulses instead of 8. The number of the pulses were different each transmission cycle. After investigation I found that only if SPI pins are configured with GPIO_SPEED_FREQ_LOW than this problem exists.
Is the mcp4151 compatible with the STM32F4?
If your device (stm32f4) is clocked at 168MHz and you’ve selected SPI_BAUDRATEPRESCALER_2 that means that your SPI is clocked at 42MHz which is pretty high and I’m pretty sure that the MCP4151 cannot work at so high frequency. In order to find the maximum frequency your device is able to work you have to look in the datasheet.
How does a slave work on a Raspberry Pi?
Slave: STM32F405 chip that is soldered to a custom Raspberry Pi PCB shield. It communicates with an external sensor via interrupts. The sensor is actually an array of small sensors configured from Master and has one pin outputting analogue voltage and other digital pin to signal that the voltage is correct and can be converted to digital value.