IgH EtherCAT Master
1.5.3
|
EtherCAT CANopen SDO request structure. More...
Go to the source code of this file.
Data Structures | |
struct | ec_sdo_request |
CANopen SDO request. More... | |
Functions | |
void | ec_sdo_request_init (ec_sdo_request_t *) |
SDO request constructor. | |
void | ec_sdo_request_clear (ec_sdo_request_t *) |
SDO request destructor. | |
int | ec_sdo_request_copy (ec_sdo_request_t *, const ec_sdo_request_t *) |
Copy another SDO request. More... | |
int | ec_sdo_request_alloc (ec_sdo_request_t *, size_t) |
Pre-allocates the data memory. More... | |
int | ec_sdo_request_copy_data (ec_sdo_request_t *, const uint8_t *, size_t) |
Copies SDO data from an external source. More... | |
int | ec_sdo_request_timed_out (const ec_sdo_request_t *) |
Checks, if the timeout was exceeded. More... | |
EtherCAT CANopen SDO request structure.
Definition in file sdo_request.h.
int ec_sdo_request_copy | ( | ec_sdo_request_t * | req, |
const ec_sdo_request_t * | other | ||
) |
Copy another SDO request.
req | SDO request. |
other | Other SDO request to copy from. |
Definition at line 91 of file sdo_request.c.
int ec_sdo_request_alloc | ( | ec_sdo_request_t * | req, |
size_t | size | ||
) |
Pre-allocates the data memory.
If the mem_size is already bigger than size, nothing is done.
req | SDO request. |
size | Data size to allocate. |
Definition at line 127 of file sdo_request.c.
int ec_sdo_request_copy_data | ( | ec_sdo_request_t * | req, |
const uint8_t * | source, | ||
size_t | size | ||
) |
Copies SDO data from an external source.
If the mem_size is to small, new memory is allocated.
0 | Success. |
<0 | Error code. |
req | SDO request. |
source | Source data. |
size | Number of bytes in source. |
Definition at line 156 of file sdo_request.c.
int ec_sdo_request_timed_out | ( | const ec_sdo_request_t * | req | ) |
Checks, if the timeout was exceeded.
req | SDO request. |
Definition at line 177 of file sdo_request.c.