- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Under DAVE 4.4.2 I tried unsuccessfully to change the CAN baudrate with: "CAN_NODE_ConfigBaudrate()".
It turned out that the struct:
static const XMC_CAN_NODE_NOMINAL_BIT_TIME_CONFIG_t CAN_BUS_1_BitTimeConfig = {
.can_frequency = (uint32_t)1.44E8,
.baudrate = (uint32_t)(250 * 1000),
.sample_point = (uint16_t)(80 * 100),
.sjw = (uint16_t)1
};
from the file "can_node_conf.c" was created in Flash,
and therefore could not be changed at runtime.
After changing to:
"static XMC_CAN_NODE_NOMINAL_BIT_TIME_CONFIG_t CAN_BUS_1_BitTimeConfig = {.."
(without "const"),
the struct was created in RAM,
and I was able to change the baudrate with "CAN_NODE_ConfigBaudrate()".
Best Regards,
Hans
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @Hans_ ,
Thank you for sharing us the information as of how to change the baud rate of CAN during runtime.
Regards,