2025-04-24 4:36 AM - last edited on 2025-04-24 4:43 AM by mƎALLEm
Hello,
I’m working with the STM32F407VG microcontroller and I want to establish communication between the PC and the board using CAN protocol. My goal is to transmit and receive user data via CAN between the STM32 and a PC application. Which USB-to-CAN adapter is recommended for CAN communication with Board.
[STM32 Board] --- [USB-to-CAN Adapter] --- [PC]
2025-04-24 4:42 AM - edited 2025-04-24 4:43 AM
Hello @Loganathan and welcome to the ST community,
So where is the question? and which board are you using for STM32F407VG microcontroller?
2025-04-24 4:53 AM
Hi,
How to establish CAN communication between STM32F407VG and PC via USB-to-CAN adapter? Which USB-to-CAN adapter do you recommend for stable and compatible CAN communication between the STM32F407VG board and a Windows PC?
2025-04-24 5:41 AM - edited 2025-04-24 5:44 AM
First of all you need to establish a complete CAN bus with at least two CAN nodes. Then, in your case, the first node contains STM32F407 MCU with a CAN transceiver + a terminating resistor of 120 ohm and the second node a CAN/USB adapter on which you need to enable an internal 120ohm terminating resistor.
This is a minimal CAN bus structure:
I cannot give a recommendation for an USB-to-CAN adapter. But I can give an example: https://www.waveshare.com/usb-can-a.htm
But this is not a recommendation it's up to you to decide as this is not an ST product.
Meanwhile, from the microcontroller side, you need to add a transceiver for example what was used on several ST boards: SN65HVD230.
CAN communication example is provided here.
If you are not familiar with the CAN bus you need to study it before going ahead with using as communication medium.
Hope that helps.