
Page 26
Copyright © 2017 Matrix Technology Solutions Limited
www.matrixtsl.com
Connection
Return
Command
Parameter(s)
Description
Status
ComOpen
Port
Open Bluetooth / Serial COM port
Port = 1 to 255
Status = 0 (OK) or 255 (error)
Status
ComClose
Close Bluetooth / Serial COM port
Status = 0 (OK) or 255 (error)
Status
IPOpen
IP0, IP1, IP2, IP3
Open WIFI IP Connection
IP0 - IP3 = 0 to 255
Status = 0 (OK) or 255 (error)
Status
IPClose
Close WIFI IP Connection
Status = 0 (OK) or 255 (error)
Version
GetAPIVersion
Returns the version number of the API
Version = 1 to 65535
API Documentation
Input and Output
MIAC AllCode
Instructional Guide
Inputs
Return
Command
Parameter(s)
Description
Value
ReadDigitalInput
Channel
Reads the binary value of one of the input terminals
Channel = 1 to 8
Value = 0 (Input Low) or 1 (Input High)
Value
ReadInputs
Reads the binary values of all the input terminals
Value = 0 to 255
Value
ReadAnalogInput
Channel
Returns the analog value of one of the input terminals
Channel = 1 to 8
Value = 0 to 1023
Transistor Outputs
Return
Command
Parameter(s)
Description
WriteTran
Channel
Value
Writes a value to control a single transistor output
Channel = 1 to 4
Value = 0 to 1
WriteTrans
Value
Writes a value to control all four transistor outputs at once
Value = 0 to 15
PWMEnable
Value
Enables or Disables PWM functionality on the transistor
outputs
Value = 0 to 63
PWMDuty
Channel
Value
Sets a single PWM duty in terms of mark to space
Channel = 0 to 5 - 0=ENAB / 1=A / 2=B / 3=C / 4=D /
5=ENCD
Value = 0 to 65535
PWMConfig
Channel
Period
Prescaler
Sets the PWM configuration
Channel = 0 to 1 - 0=AB / 1=CD
Period = 0 to 65535
Prescaler = 0 to 3 - 0=1:1 / 1=1:8 / 2=1:64 / 3=1:256
Summary of Contents for MI3932 MIAC AllCode
Page 1: ......