65
Serial Communications
Section 4-1
HLM -> HLS: @13SC0250*
HLS -> HLM: @13SC0052*
Result:
The PC is running in MON mode. Note that this is necessary for writing data
to the PC using HLM_WRITE.
■
Reading PC model code using HLM_COMMAND (timeout)
BASIC program:
HLM_TIMEOUT=500
‘ Destination address: VR(100)
HLM_COMMAND(HLM_MREAD,2,13,MC_VR,100)
Host Link Communication:
HLM -> HLS: @13MM42*
HLS -> HLM: no response
Result:
As no response has been received from the PC, after 500 servo cycles the
HLM_STATUS PORT(2) will have value 256 (bit 8 is set).
4-1-2
Host Link Slave
In Host Link Slave mode, a Host Link Master such as a Programmable Termi-
nal can read data from and write data to the MC Unit. The MC Unit will have
the following mapping for the Host Link Slave.
The following BASIC commands are used:
Refer to SECTION 6 BASIC Motion Control Programming Language for fur-
ther details on the commands.
Host Link Slave
Commands
The list of Host Link commands that are supported for the Host Link Slave are
listed here below. The protocol supports both single frame and multiple frame
transfer. A full description of the Host Link protocol can be found in SYSMAC
CS/CJ Series Communications Commands Reference Manual (W342).
MCW151 Memory
Host Link Mapping
Address Range
VR
CIO
0 to 250
Table
DM
0 to 7999
BASIC Command
Description
SETCOM
SETCOM configures the serial communication port,
including enabling the Host Link protocols.
HLS_NODE
HLS_NODE defines the Slave unit number for the
Host Link Slave protocol.
HLS_MODEL
HLS_MODEL defines the MC Unit model code for
the Host Link Slave protocol.
Type
Header
Code
Name
Function
I/O memory reading
RR
CIO AREA READ
Reads the specified number of words from VR mem-
ory beginning with the designated word.
RD
DM AREA READ
Reads the specified number of words from Table
memory beginning with the designated word.
I/O memory writing
WR
CIO AREA WRITE
Writes the specified data in word units to VR memory
beginning with the designated word.
WD
DM AREA WRITE
Writes the specified data in word units to Table mem-
ory beginning with the designated word.