2023-04-03 02:22 AM
I'm using STM32F446RC controller CAN BUS 1. Trying to operate CAN BUS at 1mbps speed when using 100kbps bit rate it is working fine but not at 1Mbps bit rate. Is there any solution for this.
2023-04-03 03:35 AM
Hi,
The cell can support up to 1Mbps communication.
So please check your bitrate according to the parameters in your application: Clocks, prescalers, BS1, BS2 ..
Could you please provide more details about your HW: provide schematic + bus length
Did you try 1Mbps in loopback mode?
2023-04-03 09:52 PM
Hello @Community member ,
I tried it in loopback mode also but it does not works. I am using main clock 180 MHz with other settings given below. I am attaching schematic and parametre details as bleow.
2023-04-03 09:56 PM
Given below are the details for CAN at 1 Mbps baud rate with Clock at 180MHz.
2023-04-04 01:02 AM
Hi,
The value 1 is very small for BS1 and BS2. You should select a prescaler value as less as possible and BS1 and BS2 values as greater as possible with BS1 > BS2 where BS1 is around 80% of the sum (BS1+BS2).
So please try these values with a simple point at ~75%:
2023-04-04 04:29 AM
Hello, @Community member
I have tried these above mentioned parameters but still it does not work. It is working well at lower baud rates like 100kbps and 200kbps but not at 1mbps.
2023-04-04 04:38 AM
Are you using an external crystal (HSE) or using HSI?
And even with above new parameters loopback mode is not working?
2023-04-04 11:13 PM
Hi @Community member
No, new parameters are not even working in loopback mode. I am using HSE Clock but even tried it with HSI but nothing works.
I have checked that if I use 60 MHz clock for 100kbps baud rate below parameters (attaching below) with HSE clock and HSI it works good in Normal and Loopback mode but if I use same clock 60MHz (tried with HSE and HSI both) for 1Mbps with parameters below given (attaching them also) even this does not work.
2023-04-05 01:05 AM
Hi,
Could you please send you system clock configuration?
Could you also tell which board you are using?
2023-04-05 01:49 AM
@Community member
I am using custom pcb which has STM32F446RCTx controller.