![]() |
ACU6 Device API
|
CAN Service. More...
Data Structures | |
struct | a_ipc_dyn_array_enum_can_result |
Dynamic-length array of a_ipc_enum_can_result. More... | |
struct | a_ipc_dyn_array_enum_can_type |
Dynamic-length array of a_ipc_enum_can_type. More... | |
struct | a_ipc_dyn_array_enum_can_nominal_bitrate |
Dynamic-length array of a_ipc_enum_can_nominal_bitrate. More... | |
struct | a_ipc_dyn_array_enum_can_data_bitrate |
Dynamic-length array of a_ipc_enum_can_data_bitrate. More... | |
struct | a_ipc_dyn_array_enum_can_state |
Dynamic-length array of a_ipc_enum_can_state. More... | |
struct | a_ipc_msg_can_request_req |
Request a CAN interface. More... | |
struct | a_ipc_msg_can_request_rsp |
CAN interface request result. More... | |
struct | a_ipc_msg_can_release_req |
Release a CAN interface. More... | |
struct | a_ipc_msg_can_release_rsp |
CAN interface release result. More... | |
struct | a_ipc_msg_can_configure_req |
Request to configure a CAN interface. More... | |
struct | a_ipc_msg_can_configure_rsp |
Sent in response to can_configure_req message. More... | |
struct | a_ipc_msg_can_status_req |
Check the state of the CAN interface. More... | |
struct | a_ipc_msg_can_status_rsp |
CAN interface state. More... | |
struct | a_ipc_msg_can_set_wakeup_req |
CAN wakeup configuration. More... | |
struct | a_ipc_msg_can_set_wakeup_rsp |
Sent in response to can_set_wakeup_req message. More... | |
struct | a_ipc_msg_can_reset_req |
CAN reset request. More... | |
struct | a_ipc_msg_can_reset_rsp |
Sent in response to can_reset_req message. More... | |
CAN Service.
This page contains documentation of the CAN Service API.
The IPC API controls the physical interfaces. Data is sent using SocketCAN interfaces (canX
).
struct a_ipc_dyn_array_enum_can_result |
Dynamic-length array of a_ipc_enum_can_result.
Data Fields | ||
---|---|---|
uint32_t | length | Length of the array (number of elements) |
a_ipc_enum_can_result * | value | The contents of the array. |
struct a_ipc_dyn_array_enum_can_type |
Dynamic-length array of a_ipc_enum_can_type.
Data Fields | ||
---|---|---|
uint32_t | length | Length of the array (number of elements) |
a_ipc_enum_can_type * | value | The contents of the array. |
struct a_ipc_dyn_array_enum_can_nominal_bitrate |
Dynamic-length array of a_ipc_enum_can_nominal_bitrate.
Data Fields | ||
---|---|---|
uint32_t | length | Length of the array (number of elements) |
a_ipc_enum_can_nominal_bitrate * | value | The contents of the array. |
struct a_ipc_dyn_array_enum_can_data_bitrate |
Dynamic-length array of a_ipc_enum_can_data_bitrate.
Data Fields | ||
---|---|---|
uint32_t | length | Length of the array (number of elements) |
a_ipc_enum_can_data_bitrate * | value | The contents of the array. |
struct a_ipc_dyn_array_enum_can_state |
Dynamic-length array of a_ipc_enum_can_state.
Data Fields | ||
---|---|---|
uint32_t | length | Length of the array (number of elements) |
a_ipc_enum_can_state * | value | The contents of the array. |
struct a_ipc_msg_can_request_req |
Request a CAN interface.
The interface will not be turned on if it's not configured.
Response is delivered in a_ipc_msg_can_request_rsp.
Create using a_ipc_init_can_request_req().
Message type is A_IPC_MSG_CAN_REQUEST_REQ.
Data Fields | ||
---|---|---|
uint8_t | index | Index of the requested interface. |
a_ipc_dyn_string | user | User identifier, max 15 characters long. |
struct a_ipc_msg_can_request_rsp |
CAN interface request result.
Sent in response to a_ipc_msg_can_request_req.
Create using a_ipc_init_can_request_rsp().
Message type is A_IPC_MSG_CAN_REQUEST_RSP.
Data Fields | ||
---|---|---|
uint8_t | index | Index of the requested interface. |
a_ipc_enum_can_result | result | Result of the operation. |
struct a_ipc_msg_can_release_req |
Release a CAN interface.
Response is delivered in a_ipc_msg_can_release_rsp.
Create using a_ipc_init_can_release_req().
Message type is A_IPC_MSG_CAN_RELEASE_REQ.
Data Fields | ||
---|---|---|
uint8_t | index | Index of the requested interface. |
a_ipc_dyn_string | user | User identifier, max 15 characters long. |
struct a_ipc_msg_can_release_rsp |
CAN interface release result.
Sent in response to a_ipc_msg_can_release_req.
Create using a_ipc_init_can_release_rsp().
Message type is A_IPC_MSG_CAN_RELEASE_RSP.
Data Fields | ||
---|---|---|
uint8_t | index | Index of the requested interface. |
a_ipc_enum_can_result | result | Result of the operation. |
struct a_ipc_msg_can_configure_req |
Request to configure a CAN interface.
If any user has requested the interface prior to configuration, this call will also turn it on. The result is received in a can_configure_rsp
message.
Response is delivered in a_ipc_msg_can_configure_rsp.
Create using a_ipc_init_can_configure_req().
Message type is A_IPC_MSG_CAN_CONFIGURE_REQ.
Data Fields | ||
---|---|---|
a_ipc_enum_can_data_bitrate | data_bitrate | Data bitrate The data bitrate is only used when the CAN type is CAN_FD. |
uint8_t | index | Index of the requested interface. |
a_ipc_enum_can_nominal_bitrate | nominal_bitrate | Nominal bitrate. |
a_ipc_enum_can_type | type | Interface type. |
struct a_ipc_msg_can_configure_rsp |
Sent in response to can_configure_req
message.
Sent in response to a_ipc_msg_can_configure_req.
Create using a_ipc_init_can_configure_rsp().
Message type is A_IPC_MSG_CAN_CONFIGURE_RSP.
Data Fields | ||
---|---|---|
uint8_t | index | Index of the requested interface. |
a_ipc_enum_can_result | result | Result of the operation. |
struct a_ipc_msg_can_status_req |
Check the state of the CAN interface.
Response is delivered in a_ipc_msg_can_status_rsp.
Create using a_ipc_init_can_status_req().
Message type is A_IPC_MSG_CAN_STATUS_REQ.
Data Fields | ||
---|---|---|
uint8_t | index | Index of the requested interface. |
struct a_ipc_msg_can_status_rsp |
CAN interface state.
Sent in response to a_ipc_msg_can_status_req.
Create using a_ipc_init_can_status_rsp().
Message type is A_IPC_MSG_CAN_STATUS_RSP.
Data Fields | ||
---|---|---|
uint8_t | index | Index of the requested interface. |
a_ipc_enum_can_result | result | Result of the operation. |
a_ipc_enum_can_state | state | Current state of the interface. |
struct a_ipc_msg_can_set_wakeup_req |
CAN wakeup configuration.
Response is delivered in a_ipc_msg_can_set_wakeup_rsp.
Create using a_ipc_init_can_set_wakeup_req().
Message type is A_IPC_MSG_CAN_SET_WAKEUP_REQ.
Data Fields | ||
---|---|---|
uint8_t | index | Index of the requested interface. |
uint8_t | state | 0: Disable, 1: Enable |
struct a_ipc_msg_can_set_wakeup_rsp |
Sent in response to can_set_wakeup_req
message.
Sent in response to a_ipc_msg_can_set_wakeup_req.
Create using a_ipc_init_can_set_wakeup_rsp().
Message type is A_IPC_MSG_CAN_SET_WAKEUP_RSP.
Data Fields | ||
---|---|---|
uint8_t | index | Index of the requested interface. |
a_ipc_enum_can_result | result | Result of the operation. |
struct a_ipc_msg_can_reset_req |
CAN reset request.
Resets the CAN interface from e.g. BUS OFF.
Response is delivered in a_ipc_msg_can_reset_rsp.
Create using a_ipc_init_can_reset_req().
Message type is A_IPC_MSG_CAN_RESET_REQ.
Data Fields | ||
---|---|---|
uint8_t | index | Index of the requested interface. |
struct a_ipc_msg_can_reset_rsp |
Sent in response to can_reset_req
message.
Sent in response to a_ipc_msg_can_reset_req.
Create using a_ipc_init_can_reset_rsp().
Message type is A_IPC_MSG_CAN_RESET_RSP.
Data Fields | ||
---|---|---|
a_ipc_enum_can_result | result | Result of the operation. |
Result codes.
enum a_ipc_enum_can_type |
A_IPC_RESULT a_ipc_init_can_configure_req | ( | a_ipc_msg * | msg | ) |
Initialize the message buffer to contain a_ipc_msg_can_configure_req.
msg->info.type
will be A_IPC_MSG_CAN_CONFIGURE_REQ.
This function can be called on an already initialized message to change its type.
msg | The message buffer to initialize |
A_IPC_RESULT a_ipc_init_can_configure_rsp | ( | a_ipc_msg * | msg | ) |
Initialize the message buffer to contain a_ipc_msg_can_configure_rsp.
msg->info.type
will be A_IPC_MSG_CAN_CONFIGURE_RSP.
This function can be called on an already initialized message to change its type.
msg | The message buffer to initialize |
A_IPC_RESULT a_ipc_init_can_release_req | ( | a_ipc_msg * | msg, |
uint32_t | user_maxlength | ||
) |
Initialize the message buffer to contain a_ipc_msg_can_release_req.
msg->info.type
will be A_IPC_MSG_CAN_RELEASE_REQ.
This function can be called on an already initialized message to change its type.
msg | The message buffer to initialize |
user_maxlength | The maximum string length for user in the message. |
A_IPC_RESULT a_ipc_init_can_release_rsp | ( | a_ipc_msg * | msg | ) |
Initialize the message buffer to contain a_ipc_msg_can_release_rsp.
msg->info.type
will be A_IPC_MSG_CAN_RELEASE_RSP.
This function can be called on an already initialized message to change its type.
msg | The message buffer to initialize |
A_IPC_RESULT a_ipc_init_can_request_req | ( | a_ipc_msg * | msg, |
uint32_t | user_maxlength | ||
) |
Initialize the message buffer to contain a_ipc_msg_can_request_req.
msg->info.type
will be A_IPC_MSG_CAN_REQUEST_REQ.
This function can be called on an already initialized message to change its type.
msg | The message buffer to initialize |
user_maxlength | The maximum string length for user in the message. |
A_IPC_RESULT a_ipc_init_can_request_rsp | ( | a_ipc_msg * | msg | ) |
Initialize the message buffer to contain a_ipc_msg_can_request_rsp.
msg->info.type
will be A_IPC_MSG_CAN_REQUEST_RSP.
This function can be called on an already initialized message to change its type.
msg | The message buffer to initialize |
A_IPC_RESULT a_ipc_init_can_reset_req | ( | a_ipc_msg * | msg | ) |
Initialize the message buffer to contain a_ipc_msg_can_reset_req.
msg->info.type
will be A_IPC_MSG_CAN_RESET_REQ.
This function can be called on an already initialized message to change its type.
msg | The message buffer to initialize |
A_IPC_RESULT a_ipc_init_can_reset_rsp | ( | a_ipc_msg * | msg | ) |
Initialize the message buffer to contain a_ipc_msg_can_reset_rsp.
msg->info.type
will be A_IPC_MSG_CAN_RESET_RSP.
This function can be called on an already initialized message to change its type.
msg | The message buffer to initialize |
A_IPC_RESULT a_ipc_init_can_set_wakeup_req | ( | a_ipc_msg * | msg | ) |
Initialize the message buffer to contain a_ipc_msg_can_set_wakeup_req.
msg->info.type
will be A_IPC_MSG_CAN_SET_WAKEUP_REQ.
This function can be called on an already initialized message to change its type.
msg | The message buffer to initialize |
A_IPC_RESULT a_ipc_init_can_set_wakeup_rsp | ( | a_ipc_msg * | msg | ) |
Initialize the message buffer to contain a_ipc_msg_can_set_wakeup_rsp.
msg->info.type
will be A_IPC_MSG_CAN_SET_WAKEUP_RSP.
This function can be called on an already initialized message to change its type.
msg | The message buffer to initialize |
A_IPC_RESULT a_ipc_init_can_status_req | ( | a_ipc_msg * | msg | ) |
Initialize the message buffer to contain a_ipc_msg_can_status_req.
msg->info.type
will be A_IPC_MSG_CAN_STATUS_REQ.
This function can be called on an already initialized message to change its type.
msg | The message buffer to initialize |
A_IPC_RESULT a_ipc_init_can_status_rsp | ( | a_ipc_msg * | msg | ) |
Initialize the message buffer to contain a_ipc_msg_can_status_rsp.
msg->info.type
will be A_IPC_MSG_CAN_STATUS_RSP.
This function can be called on an already initialized message to change its type.
msg | The message buffer to initialize |
a_ipc_enum_can_data_bitrate a_ipc_msg_can_configure_req::data_bitrate |
Data bitrate The data bitrate is only used when the CAN type is CAN_FD.
uint8_t a_ipc_msg_can_request_req::index |
Index of the requested interface.
uint8_t a_ipc_msg_can_request_rsp::index |
Index of the requested interface.
uint8_t a_ipc_msg_can_release_req::index |
Index of the requested interface.
uint8_t a_ipc_msg_can_release_rsp::index |
Index of the requested interface.
uint8_t a_ipc_msg_can_configure_req::index |
Index of the requested interface.
uint8_t a_ipc_msg_can_configure_rsp::index |
Index of the requested interface.
uint8_t a_ipc_msg_can_status_req::index |
Index of the requested interface.
uint8_t a_ipc_msg_can_status_rsp::index |
Index of the requested interface.
uint8_t a_ipc_msg_can_set_wakeup_req::index |
Index of the requested interface.
uint8_t a_ipc_msg_can_set_wakeup_rsp::index |
Index of the requested interface.
uint8_t a_ipc_msg_can_reset_req::index |
Index of the requested interface.
a_ipc_enum_can_nominal_bitrate a_ipc_msg_can_configure_req::nominal_bitrate |
Nominal bitrate.
a_ipc_enum_can_result a_ipc_msg_can_request_rsp::result |
Result of the operation.
a_ipc_enum_can_result a_ipc_msg_can_release_rsp::result |
Result of the operation.
a_ipc_enum_can_result a_ipc_msg_can_configure_rsp::result |
Result of the operation.
a_ipc_enum_can_result a_ipc_msg_can_status_rsp::result |
Result of the operation.
a_ipc_enum_can_result a_ipc_msg_can_set_wakeup_rsp::result |
Result of the operation.
a_ipc_enum_can_result a_ipc_msg_can_reset_rsp::result |
Result of the operation.
a_ipc_enum_can_state a_ipc_msg_can_status_rsp::state |
Current state of the interface.
uint8_t a_ipc_msg_can_set_wakeup_req::state |
0: Disable, 1: Enable
a_ipc_enum_can_type a_ipc_msg_can_configure_req::type |
Interface type.
a_ipc_dyn_string a_ipc_msg_can_request_req::user |
User identifier, max 15 characters long.
a_ipc_dyn_string a_ipc_msg_can_release_req::user |
User identifier, max 15 characters long.