can-buscanopensdo

How much time does a node have to reply?


Is there a time limit for a node to respond to a message? Is there a difference between PDO and SDO messages in terms of response time? Or does this only depend on how the Master gets implemented?

Is there any documentation about this?


Solution

  • Generally, no. CiA 301 says (Annex A, informative):

    Time-out's [sic]
    Since COB's may be ignored, the response of a confirmed service may never arrive. To resolve this situation, an implementation may, after a certain amount of time, indicate this to the service user (time-out). A time-out is not a confirmation of that service. A time-out indicates that the service has not completed yet. The application may deal with this situation. Time-out values are considered to be implementation specific and do not fall within the scope of this specification. However, it is recommended that an implementation provides facilities to adjust these time-out values to the requirements of the application.

    Furthermore, CANopen separates data and supervision, so checking if nodes are alive should be done with the Heartbeat protocol separately.

    It is reasonably in most applications to implement a timeout, especially on mission-critical data. My general recommendation for control systems (automotive/industrial) that is used to steer some manner of machine or is otherwise safety-related, is to use PDO inhibit time and event timer on the PDO producer, to have it send out data cyclically every 10ms or 100ms.

    And then the PDO consumer should have a corresponding timeout after which it enters a safe mode/error state. Some safety-related protocols expect data to arrive within a certain time window even - neither too late nor too early. It all depends on the specific application, how fast it needs to be reacting and if there are safety-related aspects or not.