CiA® 305: Layer Setting Services (LSS)

LSS distinguishes between an LSS master (typically residing in the host controller) and the LSS slaves. LSS enables the LSS master to modify the LSS slaves’ CANopen node-ID and to switch the entire network from one data rate to another. LSS utilizes exactly two CAN frames. The CAN data frame 7E5h carries the command from the LSS master to one or several LSS slaves. The CAN frame 7E4h is used to provide the response(s) to the LSS master. LSS is specified in the document CiA 305.

CANopen node-ID assignment via LSS

The entire 128 Bit of the Identity object 1018h (vendor-ID, product-code, revision number, serial number) are called the LSS address. The LSS address allows the LSS master to differentiate between the LSS slaves, even if one or several LSS slaves do not own a valid CANopen node-ID. Via the LSS switch state selective command, the LSS slaves forces exactly one LSS slave to enter the LSS configuration state. Only in this state the LSS slave accepts a new CANopen node-ID that is proposed by the LSS master. It is the LSS master’s task to ensure that during the assignment of the CANopen node-ID, there is only one LSS slave in the LSS configuration state.

In case the LSS addresses of the LSS slaves are unknown to the LSS master, the LSS master may have several means to detect the LSS addresses. In case the LSS slaves own already a valid CANopen node-ID, the LSS master just reads the content of the object 1018h of all LSS slaves in the system, via SDO. In case the LSS slaves do not own a valid CANopen node-ID the LSS master has to rely on additional LSS services. The LSS fastscan service enables the LSS master to scan via bit masks, whether there exists an unconfigured LSS slave, that's LSS address is in a given LSS address range. By executing several scanning cycles, the LSS master can identify exactly one unconfigured LSS slave and can provide subsequently a valid CANopen node-ID. 

CANopen bitrate switch via LSS

The LSS enable the LSS master to switch the entire CANopen system from one to another bit rate. Therefore the LSS master configures via LSS in all CANopen devices in the system the new intended bit rate individually. After the successful configuration, the LSS master requests the bit rate switch via an global LSS service at all LSS slaves at the very same time. After a switch delay, all devices in the network operate on the new bit rate.

It is recommended to use the LSS bitrate switch very carefully. In case there is at least one device that is not switching correctly to the new bitrate, the CANopen network shows a severe error behavior. A proper control system is not available any longer. Devices operating on the “wrong” bit rate have to be identified, and dismantled from the system. Those devices have to be placed in a separate system for reconfiguration, prior to install them again in the control system. For initial bit rate adjustment, LSS bitrate switch is not suitable. For such scenarios, the automatic bitrate switch is to be considered.

Typical identification of unconfigured LSS slaves by means of LSS Fastscan

In case several unconfigured LSS slaves exist in a CANopen system, they can be identified by means of the LSS Fastscan service. To be able to distinguish between the different unconfigured LSS slaves, the LSS master achieves the at the beginning unknown LSS addresses of the unconfigured LSS, by a certain number of LSS fastscan scanning cycles. In the first request of a scanning cycle the LSS master proposes for the IDnumber (either vendor-ID, product code, revision number, serial number of unknown LSS address) a bit-pattern of the size 1 to 31 Bit. All unconfigured LSS slaves evaluate, whether their LSS address matches in the given part with the proposed bit pattern. Only if the proposed bit pattern is identical to the given part of the LSS slave’s LSS address, the LSS slave indicates this to the LSS master and will continue operating in this scanning cycle. All other unconfigured LSS slaves withdraw from the current scanning cycle and will wait for the very next scanning cycle. In the next LSS master’s request the LSS master proposes again a bit-pattern of the size 1 to 31 Bit for another part of the LSS address to be identified. Again all unconfigured LSS slaves participating in this scanning cycle compare the proposed bit pattern with the relevant part of their LSS address and indicate a 100 % match to the LSS master. Other LSS slaves, where the proposed bit mask is not equal to the relevant part of the LSS address, do not take part in this scanning cycle any longer. This way, by repeating this procedure several times, the LSS master is enabled to identify a single, unconfigured LSS slave and gets automatically the entire LSS address. As soon one unconfigured LSS slave is identified, the LSS master can assign a CANopen node-ID value to this LSS slave so that the LSS slave is enabled to take part in the CANopen network.

To decrease the boot-up time in CANopen systems that may be modified by the end user, the LSS master could store LSS addresses that have been identified. On each power-up, the LSS master could try those addresses first and if there is then still an unconfigured LSS slave left in the system, the generic LSS scanning cycle is started.

Title Details
CiA 305 version 3.0.0CANopen layer setting services (LSS) and protocols
DescriptionThis document specifies the layer setting services (LSS) and protocols for CANopen. These services and protocols are used to inquire or to change the settings of three parameters of the physical layer, data link layer, and application layer on a CANopen device with LSS slave capability by a CANopen device with LSS master capability via the CAN network. The following parameters may be inquired or changed: Node-ID of the CANopen device, bit timing parameters of the physical layer (bit rate), LSS address compliant to the identity object (1018h).
DSP2.0 MiB2013-05-08Login