STM32F302K8 CAN bus test

ChibiOS public support forum for topics related to the STMicroelectronics STM32 family of micro-controllers.

Moderators: RoccoMarco, barthess

jslee
Posts: 15
Joined: Thu Jun 11, 2020 9:54 am
Has thanked: 3 times

STM32F302K8 CAN bus test

Postby jslee » Mon Feb 07, 2022 6:52 am

Hi, I'm trying CAN bus test on STM32F302K8(custom board).

I transmit uavcan data using 1Mbit/s(with below cancfg),

Code: Select all

    /* CAN_MCR */
    CAN_MCR_ABOM |      // Automatic Bus-Off Management
    CAN_MCR_AWUM |      // Automatic WakeUp Mode
    CAN_MCR_TXFP,       // Transmit FIFO Priority
    /* CAN_BTR */
    //CAN_BTR_LBKM |    // Loop BacK Mode
    CAN_BTR_SJW(0) |    // reSynchronization Jump Width
    CAN_BTR_TS2(1) |    // Time Segment 2
    CAN_BTR_TS1(6) |    // Time Segment 1
    CAN_BTR_BRP(1)      // Baud Rate Prescaler

but receive the data using 800kbit/s on 'PCAN View' program.
- If set 1Mbit/s on 'PCAN-View' program, I couldn't receive any data.

Can Anybody advice about difference between transmit and receive speed?

For correct result, what information I upload on this page?

User avatar
Giovanni
Site Admin
Posts: 14455
Joined: Wed May 27, 2009 8:48 am
Location: Salerno, Italy
Has thanked: 1076 times
Been thanked: 922 times
Contact:

Re: STM32F302K8 CAN bus test

Postby Giovanni » Mon Feb 07, 2022 7:02 am

Hi,

As far I know the STM32 CAN transmits and receives at the same speed, the driver does nothing except initialize the BTR register.

You could have a problem with your measurement setup.

Giovanni


Return to “STM32 Support”

Who is online

Users browsing this forum: Bing [Bot] and 9 guests