EtherCAT PDO list methods.
More...
Go to the source code of this file.
EtherCAT PDO list methods.
Definition in file pdo_list.c.
◆ ec_pdo_list_init()
PDO list constructor.
- Parameters
-
Definition at line 42 of file pdo_list.c.
◆ ec_pdo_list_clear()
PDO list destructor.
- Parameters
-
Definition at line 53 of file pdo_list.c.
◆ ec_pdo_list_clear_pdos()
Clears the list of mapped PDOs.
- Parameters
-
Definition at line 62 of file pdo_list.c.
◆ ec_pdo_list_total_size()
Calculates the total size of the mapped PDO entries.
- Return values
-
- Parameters
-
Definition at line 79 of file pdo_list.c.
◆ ec_pdo_list_add_pdo()
Add a new PDO to the list.
- Returns
- Pointer to new PDO, otherwise an ERR_PTR() code.
- Parameters
-
pl | PDO list. |
index | PDO index. |
Definition at line 109 of file pdo_list.c.
◆ ec_pdo_list_add_pdo_copy()
Add the copy of an existing PDO to the list.
- Returns
- 0 on success, else < 0
- Parameters
-
pl | PDO list. |
pdo | PDO to add. |
Definition at line 133 of file pdo_list.c.
◆ ec_pdo_list_copy()
Makes a deep copy of another PDO list.
- Returns
- 0 on success, else < 0
- Parameters
-
pl | PDO list. |
other | PDO list to copy from. |
Definition at line 169 of file pdo_list.c.
◆ ec_pdo_list_equal()
Compares two PDO lists.
Only the list is compared, not the PDO entries (i. e. the PDO mapping).
- Return values
-
1 | The given PDO lists are equal. |
0 | The given PDO lists differ. |
- Parameters
-
pl1 | First list. |
pl2 | Second list. |
Definition at line 199 of file pdo_list.c.
◆ ec_pdo_list_find_pdo()
Finds a PDO with the given index.
- Returns
- Search result, or NULL.
- Parameters
-
pl | PDO list. |
index | PDO index. |
Definition at line 235 of file pdo_list.c.
◆ ec_pdo_list_find_pdo_const()
Finds a PDO with the given index and returns a const pointer.
- Returns
- Search result, or NULL.
- Parameters
-
pl | PDO list. |
index | PDO index. |
Definition at line 257 of file pdo_list.c.
◆ ec_pdo_list_find_pdo_by_pos_const()
Finds a PDO via its position in the list.
Const version.
- Returns
- Zero on success, otherwise a negative error code.
- Parameters
-
pl | PDO list. |
pos | Position in the list. |
Definition at line 281 of file pdo_list.c.
◆ ec_pdo_list_count()
Get the number of PDOs in the list.
- Returns
- Number of PDOs.
- Parameters
-
Definition at line 303 of file pdo_list.c.
◆ ec_pdo_list_print()
Outputs the PDOs in the list.
- Parameters
-
Definition at line 321 of file pdo_list.c.