2025-11-12 7:25 AM
Hello everyone,
I’m currently facing an issue with PDO data exchange between a CANopen Master and Slave running on STM32 using CanopenSTM32 and CANopenEditor.
I can successfully see PDO frames on the CAN bus using a Waveshare USB-CAN-FD analyzer, but my Slave does not seem to receive or update the mapped object as expected.
These are the Details of my Setup:
Master Node-ID: 0x18
Slave Node-ID: 0x02
Stack: CANopenNode V4 (ported for STM32)
ODs generated with: CANopenEditor v4.2.3
Bus monitoring tool: Waveshare USB-CAN-FD
Master TPDO1 (0x1800):
COB-IDUsedByTPDO = 0x40000180
Mapping = 0x60010020 (x6001_counter)
TransmissionType = 0xFFSo, on the CAN bus, the Master sends messages with ID: 0x180 + Node-ID = 0x180 + 0x18 = 0x198. And I can confirm this with my USB-CAN-FD analyzer i see CAN frames with ID 0x198 and correct payload.
Slave RPDO1 (0x1400):
COB-IDUsedByRPDO = 0x40000180 <-- initially
Mapping = 0x60020020 (x6002_counterFromH7)
TransmissionType = 0xFF
So the Slave was originally listening on 0x180, but the Master sends on 0x198.
but i changed the RPDO COB-ID in the Slave OD to 0x40000198.
And On my Master : i am just sending through the network, which is also visible with my Analyser.
OD_PERSIST_COMM.x6001_counter ++ ;
CO_TPDOsendRequest(&canopenNodeSTM32->canOpenStack->TPDO[0]);
HAL_Delay(1000);
However, no matter what I change in the Slave configuration,
the received value always stays 0 (default).
CO_process_RPDO(CO, false);
printf("Received: %lu\n", (unsigned long)OD_PERSIST_COMM.x6002_counterFromH7);Has anyone experienced a similar issue where PDO messages appear correctly on the CAN bus, but the Slave’s mapped variable never updates?
Is there anything else I should check — such as modifying the COB-ID or whatever?
2025-11-12 7:52 AM
This is a Canopen Stack specific question, probably better to ask on the CanOpenNode forum (https://sourceforge.net/p/canopennode/discussion/387151/).
Normaly the Master has to send the PDO's with the COB-ID of the slave (in your case 0x182).
If You have modifed the COB-ID directly in the CanOpenEditor, the probably the slave is now expecting COB-ID 0x198 + 0x02 = 0x19A.