...
If one of these errors is detected, this function call will change nothing.
Important: After successful operation, the function CONmtReset()
must be called to re-initialize the internal SDO and PDO tables.
Example
The following example shows how to set a dynamically determined node-ID for the CANopen node AppNode:
Code Block | ||
---|---|---|
| ||
CO_ERR err;
CPU_INT08U id;<br> :
id = <code>AppCalculateNodeId()</code>;
CONmtSetNodeId (&(AppNode.Nmt), id);
err = CONodeGetErr(&AppNode);
if (err == CO_ERR_NONE) {
/* calculated node-ID is set */
} else {
/* error during setting the node-ID */
}
: |