DEV Community

Cover image for How to Control SSI Absolute Encoder by EtherCAT Controller?
ZMOTION CONTROLLER
ZMOTION CONTROLLER

Posted on

How to Control SSI Absolute Encoder by EtherCAT Controller?

Before, “How to Use ZMC432-V2 EtherCAT Motion Controller to Read Position from BissC Absolute Encoder” had been shared, you can review that~

Then, today, let’s see another kind of encoder “SSI absolute encoder” in EtherCAT motion controller, still, taking the example of ZMC432-V2 EtherCAT motion controller.

What is SSI Absolute Encoder?

“SSI” means Synchronous Serial Interface, it is one digital interface protocol. Moreover, it is one communication protocol for data transferring between motion control and absolute encoder. And one main feature is "master-slave" interface because it uses synchronous serial interface mode.
Specifically, there are clock signal and pulse on the controller that can transfer data from the encoder to the controller synchronously. And the output data can be binary system or Gray-code.
Therefore, SSI absolute encoder is used to measure the position and angle. It only needs 2 cables to do the data transferring: Data & Clock. The principle is very simple, it converts the position information to binary code, encoding the codes as serial data, during the control, controller “clock” signal will control data’s transferring velocity.

Image description
SSI Absolute Encoder

Image description
SSI Interface

How EtherCAT Motion Controller Controls SSI Absolute Encoder?

(1) EtherCAT Motion Controller

A. Valid EtherCAT Motion Controller
For Zmotion, EtherCAT motion controller must meet below requirements:
*Controller Model: ZMC432-V2, ZMC406-V2

It supports rich motion control interfaces, and this kind of controller “ZMC” can run without PC.

It supports 32 axes motion control at most, that is, it can control 32 motors. All kinds of motion control functions and applications, it is OK.
*Firmware Version: above 4.930-20190305
*AXIS Interface: for ZMC432-V2 series, only AXIS4/5 support SSI/BISS communication.
You can check through "controller status", if there is "Ssi", which means it supports.

Image description

B. Development
--RTSys / ZDevelop: PLC / Basic / HMI.
--PC Languages: C#, C++, LabVIEW, Matlab, Qt, Linux, VB.Net, Python
Image description

(2) Wiring: EtherCAT Controller & SSI Absolute Encoder

EtherCAT motion controller has two pulse axes AXIS 4 & AXIS 5 that support SSI/BISS communication protocol, but SSI absolute encoder must be powered by 5V. And whatever SSI absolute encoder uses +5V power supply, the public end must be connected to controller GND.

Image description

Image description
ZMC432-V2 Controller AXIS 4 / 5 & SSI / BISS Interface

Image description

Wiring of EtherCAT Master & SSI Absolute Encoder

(3) Needed Parameters

--ATYPE: Axis Type--
48 = SSI absolute encoder, 49 = BISS absolute encoder
--UNITS: Pulse Amount--
Take SSI absolute encoder as the example, the resolution is 16-bit, then one circle corresponds to 65535 pulses, that is, the controller sets this axis' pulse amount UNITS according to this parameter.
--ENCODER_BITS: SSI/BISS Encoder Absolute Bit--
Refer to SSI absolute encoder manual data bit.

Image description

(4) Program Configuration

global CONST ENC_AxisStart = 4     'local absolute encoder axis starting axis No.
global CONST ENC_AxisNum = 2     'how many axes of local absolute encoder axes
'set local absolute encoder axis
for i = 0 to ENC_AxisNum - 1
   BASE(ENC_AxisStart + i)
   AXIS_ADDRESS=(-1<<16)+4+i     'map absolute encoder to axis 4, 5
   ENCODER_BITS = 26                     '26-bit absolute
   ATYPE=48                                        'SSI absolute encoder
Next
Enter fullscreen mode Exit fullscreen mode

(5) Origin Settings

Generally, the origin position of absolute encoder is set through the signal.

Image description

If not to use signal, you also can contact with encoder manufacturer.

(6) Absolute Encoder Position Reading

After encoder position cleared when at the origin position, set UNITS, and read axis 4 / 5 MPOS values, then you will know encoder current position, if you need encoder original value, then read “ENCODER” of axis 4 / 5.
Note: SSI absolute encoder position supports power-down storage function.

Image description
Axis 4 SSI Absolute Encoder Position MPOS

Image description
Position Curve Captured by SCOPE when Rotating SSI Absolute Encoder Manually

Q & A of Related SSI Absolute Encoder:

--when downloading, it shows atype 48 error of axis 4 / axis 5--
Please check controller firmware version, it should be above 20190305, if not, contact with us to update it.

--no MPOS / wrong MPOS for axis 4 / axis 5--
Check wiring.
Check encoder_bit parameter configuration. You can online send the command “?* encoder_bits” to see if the parameter is set correctly.

That's all, thank you for your reading -- How to Control SSI Absolute Encoder in EtherCAT Motion Controller?

Top comments (0)