rtlabs-com/c-open

Dead code in co_handle_rx

Closed this issue · 0 comments

In co_handle_rx will different functions be called, depending on the received function code.

However, the function co_emcy_rx will never be called since the value CO_FUNCTION_EMCY is the same as the value CO_FUNCTION_SYNC, which already has been checked.

The correct condition to call co_pdo_sync should be:

else if ((function == CO_FUNCTION_SYNC) && (node == 0))