You are here:
Print

The controller parameters (Kp, Ki, Kd) can be set using object 2067h through the SDO protocol. Each controller parameter (Kp, Ki and Kd) is represented internally with 2 parameters, i.e. the proportional part of position controller, KP, is represented with KPP and SFTKPP variables. The KPx, KIx and KDx parameters have a range between 0 and 32767, while the SFTKPx, SFTKIx and SFTKDx have a range between 0 and 14.

The relationship between the controller parameters and the internal KPx, SFTKPx, KIx, SFTKIx, KDx, SFTKDx is:

Kp = KPx / 32767 * 2^SFTKPx

Ki = KIx / 32767 * 2^SFTKIx

Kd = KDx / 32767 * 2^SFTKDx

For example if the parameter KPP needs to be set with the value 1000 (= 0x03E8 in hex) for the axis with node id 1, the following CANopen message has to be sent:

601    23 67 20 00 E8 03 67 02

Where:
– 601 is the COB ID of the SDO message to axis 1 (600h + Node ID);
– 23 67 20 00 – SDO protocol codification for: write 32 bit data into object 2067h, subindex 00h
– E8 03 67 02 – write 1000 (03E8h) at address 0267h

For more details, please check the description of the object 2067h from the corresponding CANopen programming manual.

Here are the addresses for the controller variables:

1. Current Loop:
Kp – KPI: 0x0271
SFTKPI: 0x0272
Ki –  KII: 0x0273
SFTKII: 0x0274

2. Speed loop:
Kp –  KPS: 0x0267 
SFTKPS: 
0x0268
Ki –  KIS: 0x0269
        SFTKIS: 0x026A

3. Position loop:
Kp –  KPP: 0x025E
        SFTKP: 0x025F
Ki –  KIP: 0x0260
        SFTKIP: 0x0261
Kd –  KDP0x0262
        SFTKDP0x0263