CAN message Rx timestamp source
Posted: Mon 9. May 2022, 14:26
Hello PEAK-Systems team,
I would appreciate if you could describe the time and encoding format of the time array / timestamp, which you are using in your examples (can.h) in the RX CAN message struct:
Are these absolute or relative time stamps (relative to what event/source, to device start or RTC, etc.)?
Or are these Systemticks (--> I'm looking for a RX value in Micro- or Milliseconds, which would require some conversions from systicks)?
Thank you!
I would appreciate if you could describe the time and encoding format of the time array / timestamp, which you are using in your examples (can.h) in the RX CAN message struct:
Code: Select all
//! @brief
//! struct for a CAN receive message.
typedef struct {
uint16_t size; //!< size of the whole struct
uint16_t bufftype:12; //!< type of the BUFFER (CAN_BUFFER_RX_MSG)
uint16_t hBus:4;
uint32_t time[2]; //!< timestamp of message <<<<<<<<<<<---- Which format is used? Is this a hardware timer, RTC, etc.???
uint32_t tag[2]; //!< a tag field for user e.g. object pointer
uint8_t res1:4; //!< reserved
uint8_t dlc:4; //!< data length code of message
uint8_t res2; //!< reserved
uint16_t msgtype; //!< type of message, bitfield, see CAN_MSGTYPE_...
uint32_t id; //!< identifier of message
union {
uint8_t data8[64]; //!< data of message (byte based)
uint16_t data16[32]; //!< data of message (half word based)
uint32_t data32[16]; //!< data of message (word based)
};
} CANRxMsg_t;
Or are these Systemticks (--> I'm looking for a RX value in Micro- or Milliseconds, which would require some conversions from systicks)?
Thank you!