-
Notifications
You must be signed in to change notification settings - Fork 23
iSV57 servo communication
The iSV57 features multiple interfaces, each with a dedicated function.
Via this port, the servo is provided with DC power. It's recommended to use 36V.
A step-dir interface (short for "step and direction interface") is a simple control method for motion control systems, often used in applications like stepper motors, servo motors, and CNC machinery. It involves two signals:
Step: A pulse signal that increments or decrements the position of the motor. Each pulse moves the motor a set distance, effectively controlling its position.
Direction: A binary signal (high or low) that dictates the motor’s movement direction, such as clockwise or counterclockwise.
With a step-dir interface, controllers can achieve precise position control with minimal wiring, making it popular for applications requiring accuracy and ease of integration.
On the topside of the iSV57 servo, the RS232 port can be found, over which the ESP can obtain servo states and parameterize its settings.
To communicate with the servo via the RS232 port, the communication structure was reverse engineered.
The picture below shows a trace taken with an Hantek 6022BE oscilloscope. The iSV57 was connected to the Stepperonline application in monitoring mode.
Channel 1 & 2 of the oscilloscope were connected to the servos Rx and Tx port. The PCs sends a request (to the servos Rx channel) and the servo respons shortly after (on the Tx channel). The logic levels on both channels were -5V for low state and +5V for high state. The time between the channel 1 burst end and start of the response burst on channel 2 is approximately 2.5ms on average.
Similarly, the channel can be probed, when the iSV57 is connected to the ESP. Again, channel 1 & 2 of the oscilloscope were connected to the servos Rx and Tx port and an exemplary trace is depicted below
The voltage levels for low/high are -5V/+5V too. The latency between the end of a hosts Tx burst (channel 1) and the start of the clients burst (channel 2) was up to 3.5ms.
Above, the analog signals of the RS232 port have been analyzed. To obtain human readable information from the analog signals, first the analog signal needs to be converted into a digital serial signal, e.g. with sigrok.
The analog signal follows the modbus protocol and can be decoded as such. An example of the decoded bursts is shown below
The picture was taken in sigrok, where the modbus decoder was selected with the setting as shown below
With some knowledge about the data structure and the register addresses, the numbers can be interpreted like such
Please find the different entries on the right hand side.