P
ar
t
1: P
rog
ra
m
ming
Moog Animatics SmartMotor™ Developer's Guide, Rev. L
Page 223 of 909
Analog Functions of I/O Ports
An I/O port’s analog value can be monitored with the following commands. The 24V I/O of a
SmartMotor offers more flexibility than the 5V I/O, as shown below. All scaled readings are in
millivolts.
The analog reads can help diagnose wiring issues external to the SmartMotor. For example,
while Ports 4 and 5 are being used as RS-485, the signal bias could be monitored; if a 5V I/O
pin is being driven as an output, the analog reading can help find a short.
The following commands are used to access the analog functions of the 5V and 24V I/O:
5 Volt Push-Pull I/O Analog Functions (D-Style Motors)
INA(A,IO)
Raw analog read: 10-bit res. 0-32736=0-5 VDC
INA(V1,IO)
Scaled voltage reading in millivolts, where 3456 would be 3.456
VDC. 0-5000=0-5 VDC
NOTE:
For the 5V I/O in the Class 5 motor's D-Sub connector, the value can be 0 -
6 for I/Os 0 - 6. For the 24V I/O, the value can be 16 - 25 for the ten I/Os 16 - 25.
24 Volt I/O Analog Functions (D-Style AD1 Option Motors, M-Style Motors)
INA(A,IO)
Raw analog read: 10-Bit res. 0-38130=0-41.25 VDC
INA(V,IO)
Scaled read 0-24000, where 15500 is 15.5 Volts
INA(V1,IO)
Scaled read 0-5100, where 550 is 0.55 Volts
INA(V2,IO)
Scaled read 0-610, where 60 is 0.06 Volts
INA(S,x)
Sourcing voltage for the I/O port (when output pin), where x is
16-25 for the Class 5 D-style, use 0 for the M-style.
INA(T,x)
I/O chip temperature, where x is 16-25 for the Class 5 D-style,
use 0 for the M-style.
NOTE:
With the 24V I/O, the V1 and V2 settings focus the 10 bits of resolution on
the finer voltage spans of 5V and 0.6V, respectively.
CAUTION:
For Class 5 D-style AD1 option motors, at no time should the
voltage to any input exceed the level on the I/O power input (Pin 11). Doing
so could cause immediate damage to the expanded I/O hardware.
For more details, see Part 2: SmartMotor Command Reference on page 238.
Part 1: Programming: Analog Functions of I/O Ports