cancel
Showing results for 
Search instead for 
Did you mean: 

STM32 Blue Pill CAN Issues

RetroBuzz
Visitor

The board has passed a authentication test so I currently believe it is a me issue. 

I have been trying to get a CAN bus going using the STM32 Blue Pill board with a TJA1050 CAN Transceiver, but for some reason even with basically copy pasted example code I don't even get activity on the lines. The transceiver modules I am using has the CAN bus terminating resistors built in resulting in a 60ohm resistance between the H and L lines. I've ended up putting together a basic test Tx and Rx bread board in hopes of figuring out whats going on with no clues. The Tx loop eventually goes dead for some reason which makes me think the HAL_addTx started locking up. Linked is a github repository with both projects. Also a video of the boards. 

2 REPLIES 2
kumaichi
Associate III

Looks like the baud rate is different for each board.  Both boards have to be using the same baud rate.  When I tried working with CAN, I followed the ControllersTech videos he did regarding CAN.


STM32 CAN Communication Explained | Send & Receive Data Between Two Microcontrollers 

Kindest regards

Thanks for the response. The baud rate was a missed clock config setting. Unfortunately there was no change and still no activity even in the canRx and canTx lines. I used their web tutorial when making this but tomorrow after work I will go through that video and what I have and see if I can figure it out.