tonton81 / FlexCAN_T4

FlexCAN (CAN 2.0 / CANFD) Library for Teensy 3.x and 4.0
https://forum.pjrc.com/threads/56035-FlexCAN_T4-FlexCAN-for-Teensy-4
MIT License
195 stars 65 forks source link

ID issue with <FlexCAN_T4.h> #75

Closed Cand0o closed 7 months ago

Cand0o commented 7 months ago

Hi all,

I'm using a Teensy 4.1 and want to communicate with motor. I have a ID issue. Below, my ID configuration.

txBufferTd.id = 0x0CF003d0; txBufferTd.flags.extended = 1; txBufferTd.len = 8;

When I want to read the ID, I have : ID: 0xCF003D0

One "0" is missing, someone have any ideas ?

Thx,

Cand0o

tonton81 commented 7 months ago

it's the same with and without leading zeros, usually in HEX we don't display leading zeros but if you want it to show then pad it

Cand0o commented 7 months ago

Ok thx a lot for this information.