OpenLcbCLib 1.0 Alpha
OpenSource C Library to create OpenLcb/Lcc Nodes
Loading...
Searching...
No Matches
can_rx_statemachine.h
Go to the documentation of this file.
1
34#ifndef __DRIVERS_CANBUS_CAN_RX_STATEMACHINE__
35#define __DRIVERS_CANBUS_CAN_RX_STATEMACHINE__
36
37#include <stdbool.h>
38#include <stdint.h>
39
40#include "can_types.h"
41
59typedef struct {
60
62 void (*handle_can_legacy_snip)(can_msg_t *can_msg, uint8_t can_buffer_start_index, payload_type_enum data_type);
63
65 void (*handle_single_frame)(can_msg_t *can_msg, uint8_t can_buffer_start_index, payload_type_enum data_type);
66
68 void (*handle_first_frame)(can_msg_t *can_msg, uint8_t can_buffer_start_index, payload_type_enum data_type);
69
71 void (*handle_middle_frame)(can_msg_t *can_msg, uint8_t can_buffer_start_index);
72
74 void (*handle_last_frame)(can_msg_t *can_msg, uint8_t can_buffer_start_index);
75
77 void (*handle_stream_frame)(can_msg_t *can_msg, uint8_t can_buffer_start_index, payload_type_enum data_type);
78
80 void (*handle_rid_frame)(can_msg_t *can_msg);
81
83 void (*handle_amd_frame)(can_msg_t *can_msg);
84
86 void (*handle_ame_frame)(can_msg_t *can_msg);
87
89 void (*handle_amr_frame)(can_msg_t *can_msg);
90
92 void (*handle_error_info_report_frame)(can_msg_t *can_msg);
93
95 void (*handle_cid_frame)(can_msg_t *can_msg);
96
98 alias_mapping_t *(*alias_mapping_find_mapping_by_alias)(uint16_t alias);
99
101 void (*on_receive)(can_msg_t *can_msg);
102
104
105#ifdef __cplusplus
106extern "C" {
107#endif /* __cplusplus */
108
122 extern void CanRxStatemachine_initialize(const interface_can_rx_statemachine_t *interface_can_rx_statemachine);
123
145
146#ifdef __cplusplus
147}
148#endif /* __cplusplus */
149
150#endif /* __DRIVERS_CANBUS_CAN_RX_STATEMACHINE__ */
void CanRxStatemachine_incoming_can_driver_callback(can_msg_t *can_msg)
Primary entry point called by the hardware CAN driver on frame reception.
Definition can_rx_statemachine.c:529
void CanRxStatemachine_initialize(const interface_can_rx_statemachine_t *interface_can_rx_statemachine)
Registers the dependency-injection interface for this module.
Definition can_rx_statemachine.c:65
Type definitions and constants for the CAN transport layer.
payload_type_enum
Message buffer payload type identifier.
Definition openlcb_types.h:220
Definition can_types.h:173
Definition can_types.h:118
Dependency-injection interface for the CAN receive state machine.
Definition can_rx_statemachine.h:59

Copyright (c) 2026 Jim Kueneman all rights reserved. See the License