Configuration Function - Zmotion ZMIO300-4AD Manual

Hide thumbs Also See for ZMIO300-4AD:
Table of Contents

Advertisement

SLOT_SCAN (0)
'Bus scan
? RETURN
'Scan successfully returned -1
? "node num" NODE_COUNT (0)
'Number of scanned nodes
NODE_AIO (0,0) = 32
? "node 0 start aio" NODE_AIO (0,0)
SLOT_START (0)
? RETURN
'Open successfully returns -1
Refer to the above sample code, create a new project and Basic file for programming,
connect the controller, download the project to ROM and run
The controller status is as follows:
ZMIO300-4AD/ DAExpansion submodule hardware manual Version 1.1
'Expansion moduleAIO start number is set to 32
'Turn on the bus
By using input and output related instructions AIN, AOUT operationAD/ DA.Since
4AD,4The resolution of the DA expansion sub-module is 16 bits, and the scale value of the
AIN and AOUT commands ranges from 0 to 65535.
Each 4AD / DA expansion sub-module can only select voltage input / output or current
input / output, and does not support the simultaneous use of voltage and current. If both
voltage and current need to be used, please connect another 4AD / DA expansion sub-
module.

Configuration function

4AD expansion submodule
function
Channel enable configuration
name
Function
This function is used to select whether the 4 input channels of the 4AD
Description
expansion submodule need to be enabled. There are a total of 16 channel
enable modes.
A four-bit binary number represents the enable state of the four channels.
Each bit represents a channel, the lowest bit is the 0th channel, and the
highest bit is the third channel.
Instructions
Command SDO via bus_WRITETo write SDO messages.
Its SDO_WRITEExplanation
Use
SDO_WRITE (slot, node, index, subindex, type, value)
grammar
Controller
slot
slot number
node
device ID
parameter
Data dictionary
index
list
number
subindex
Subnumber
type
type of data
value
Data value
'The first submodule of the extension isAD expansion submodule
Usage
SDO_WRITE (0,0, $ 5001,2,6,0)
example
SDO_WRITE (0,0, $ 5001,2,6,3)
SDO_WRITE
bus
Default 0
Start from 0, 0-
Number 5000 plus the address
of the submodule
2
6
0-15
'All channels are closed
'Channel 0, 1 open

Advertisement

Table of Contents
loading

Table of Contents