Go to the documentation of this file.
27 #include <stdatomic.h>
32 #ifdef MODULE_CAN_MBOX
79 #if defined(MODULE_CAN_MBOX) || defined(DOXYGEN)
int16_t kernel_pid_t
Unique process identifier.
can_reg_entry_t entry
entry containing ifnum and upper layer info
Definitions high-level CAN interface.
Messaging API for inter process communication.
Definitions of high-level CAN interface.
void can_pkt_free_rx_data(can_rx_data_t *data)
Free rx data previously allocated by can_pkt_alloc_rx_data()
atomic_uint ref_count
Reference counter (for rx frames)
Mailbox struct definition.
Controller Area Network frame.
void can_pkt_free(can_pkt_t *pkt)
Free a CAN packet.
can_pkt_t * can_pkt_alloc_tx(int ifnum, const struct can_frame *frame, kernel_pid_t tx_pid)
Allocate a CAN packet to transmit.
Type with the same alignment and size as atomic_uint
void can_pkt_buf_free(void *data, size_t size)
Free the data allocated by can_pkt_buf_alloc()
void can_pkt_init(void)
Initialize the CAN packet module.
void * can_pkt_buf_alloc(size_t size)
Allocate size bytes and return the pointer.
uint8_t data[CAN_MAX_DLEN]
Frame data.
int handle
handle (for tx frames
can_rx_data_t * can_pkt_alloc_rx_data(void *data, size_t len, void *arg)
Allocate a can_rx_data_t and initialize it with gieven parameters.
can_pkt_t * can_pkt_alloc_mbox_tx(int ifnum, const struct can_frame *frame, mbox_t *mbox)
Allocate a CAN packet for a mbox to transmit.
can_pkt_t * can_pkt_alloc_rx(int ifnum, const struct can_frame *frame)
Allocate an incoming CAN packet.