From Wiki.IrisDynamics.com
Jump to navigation Jump to search

In Construction...



Theory of Operation

Order of transmissions

  Controller --- OrcaAPI --> Iris motor 
  Controller <-- OrcaAPI --- Iris motor 

Because the API supports simultaneous send and receive, it is possible to begin a new transmission while the response to the previous message is transmitting.

General Description

Iris motors are responsive to messages received using OrcaAPI and respond to all recognized transmissions. Iris motors will initiate any message without first fully receiving a properly formatted transmission. The motor contains several registers that can be read and some modified. In this way, the force can be controlled, the position and temperature read, various settings can be changed and saved, and other features can be accessed. OrcaAPI transmissions in both directions are framed by a header byte, preceding message payload bytes, and followed by a CRC check byte. Transmissions are addressed in the header so that multiple motors may share a single connection to a controller. Messages can be broadcast to all motors on the connection by setting a bit in the header, but only the motor which is addressed in the header will respond.

Physical Protocol - RS422

Iris Dynamics motors use RS422 transceivers to provide the OrcaAPI.

RJ45 connector pinout
RJ45 OrcaAPI
1 Rx+ (from controller, to motor)
2 Rx- (from controller, to motor)
3 Tx+ (to controller, from motor)
4 unused
5 unused
6 Tx- (to controller, from motor)
7 unused

Baud Rate

Unless otherwise specified, Iris motors communicate at a 625 kHz BAUD rate.

Electrical Terminations

Rx+ and Rx- (data lines from the controller to the motor) are terminated by a single resistor between the lines. Unless otherwise specified this value is 120 ohms. Tx+ and Tx- have series resistors of 2.2 ohms.

Message Framing

Header Payload CRC
1 byte 2 bytes 1 byte
Header Payload CRC
1 byte 6 bytes 1 byte

The Header Byte

Header anatomy
0 1 2 3 4 5 6 7
BRD Broadcast flag. When this is set, all motors will interpret the message regardless of an address match. Only a motor with an address match responds to broadcast messages.
ADDR Address bits (0-7). If this value does not match the motor's address, the motor will disregard the transmission, unless the BRD flag is set.
MID Message ID (0-15). This indicates how the following payload should be interpreted.
0 - reserved
1 - Read Register
2 - Write Control Register (8 bit)
3 - reserved
4 - Write (16-bit) Duty
5 - reserved
6 - reserved
7 - reserved
8 - reserved
9 - reserved
10 - reserved
11 - reserved
12 - reserved
13 - reserved
14 - reserved
15 - reserved

The CRC Byte

Message Types

Read Register

Read Register request
Byte 0 Byte 1 Byte 2 Byte 3
Header Register Address ignored CRC
Read Register response
Byte 0 Byte 1 Byte 2 Byte 3 Byte 4 Byte 5 Byte 6 Byte 7
Header Register Address Data (15:0) 0 0 0 CRC

Write Control Register

Write Control Register request
Byte 0 Byte 1 Byte 2 Byte 3
Header Register Address Byte to Write CRC
Write Control Register response
Byte 0 Byte 1 Byte 2 Byte 3 Byte 4 Byte 5 Byte 6 Byte 7
Header Register Address Data Written (7:0) 0 0 0 0 CRC

Write Duty

Commands the motor to perform the specified duty cycle, resulting in force generation. The duty cycle command is a signed-16-bit value. -32,000 is full-power shaft retraction, 0 is no power, 32,000 is full power shaft extension.

Write Duty request
Byte 0 Byte 1 Byte 2 Byte 3
Header Duty (15:0) CRC
Write Duty response
Byte 0 Byte 1 Byte 2 Byte 3 Byte 4 Byte 5 Byte 6 Byte 7
Header Shaft Position (15:0) Temperature (Celsius) Supply Voltage Power Consumption "Active" Error flags CRC

Memory Map

The memory space is divided into 4 parts:

  1. Control Registers (Read-Write, controls mode, settings, calibrations)
  2. Runtime Data Registers (Read Only, reflects sensor data)
  3. Calibration Data Registers (Read Only, set by calibration routines)
  4. Parameter Registers (Read Only, static)


Control Registers
Address (Hex) Address (Dec) Name Description
0x00 0 Control Register 0 Basic Control
bit 7-4 Reserved
bit 3: Motor Polarity
0 - position increases as shaft is extended; positive force commands extend the shaft.
1 - position decreases as shaft is extended; positive force commands retract the shaft.
The reset value of this bit is determined by the EEPROM. See Control Register 2.
bit 2: Clear Errors
Writing 1 will clear the error register's upper 8 bits (latching error flags).
bit 1: Zero Position
Sets the current shaft position to 0.
bit 0: Force Enable
Enables the force output of the motor.
0x01 1 Control Register 1 Calibration Control
bit 5 Stator Interference Calibration status
bit 4 Run stator interference calibration
Shaft must be removed and forces must be enabled.
bit 3 Run commutator zeroing calibration
Shaft must be inserted and allowed to freely position itself without bias (ie resting horizontally). Forces must be enabled. All other calibrations should be done first.
bit 2 Run force sensor zeroing calibration
Forces must be enabled
bit 1 Run position sensor zeroing calibration
Shaft must be removed. If shaft cannot be removed, use bit 0 instead
bit 0 Zero position sensors (blind)
Only use when shaft can not be removed and the position sensors must be rezeroed due to a saved bad calibration
0x02 2 Control Register 2 Save Calibration and Settings Control
bit 1 Save Settings
Saves the state of the control registers to the permanent memory. The following are saved:
Polarity from Control Register 1
Control Register 4, 5, 6, 7.
bit 0 Save Calibration
Saves the values in the all calibration registers to the permanent memory.
0x03 3 Control Register 3 reserved
0x04 4 Control Register 4 Maximum Power
The maximum power of the motor can be reduced by setting this value between 0 and 255. At 255 the full power will be available. At 127 half of the full power (70% force) will be available.
0x05 5 Control Register 5 Temperature Throttle Start
The winding temperature in degrees Celcius at which the maximum force output of the motor begins being constrained.
This value cannot exceed the maximum temperature parameter for the motor.
If the value written to this register is larger than the value in Control Register 6 , it is instead set to the value in Control Register 6.
Winding temperature values between this value and the value stored in Control Register 6 result in a linearly decreasing maximum force.
0x06 6 Control Register 6 Max Temperature
Defines the maximum temperature. If the motor reaches temperatures beyond this setting, power will be disabled to the motor until the temperature falls 5 degrees below this setting.
0x07 7 Control Register 7 Timeout
Timeout in milliseconds. If no valid communications are within this window, forces to the motor are stopped.
On reset, this value is loaded from the EEPROM.
This value is saved to the EEPROM using Control Register 2, bit 1
Runtime Registers
Address (Hex) Address (Dec) Name Description
0x70 128 Error Register If any of the lower 8 bits are are set, the power to the motor is disabled. The upper 8 bits can be zerod using Control Register 0.
bit 11: Voltage Was Too High
bit 10: Voltage Was Too Low
bit 9: Temperature Was Too High
bit 8: Shaft Was Not Detected
bit 3: Voltage Is Too High
bit 2: Voltage Is Too Low
bit 1: Temperature Is Too High
bit 0: Shaft Is Not Detected