Hs (handle switch), Configuration, Arguments: hs a=b where – Yaskawa LEGEND-MC User Manual

Page 134: A = the first handle of the switch (a - p), B = the second handle of the switch (a - p)

Advertising
background image

124

LEGEND-MC User’s Manual

HS (Handle Switch)

[Configuration]

DESCRIPTION:

The HS command is used to switch the handle assignments between two handles. Handles are assigned by
the controller when the handles are opened with the HC command, or are assigned explicitly with the IH
command. Should those assignments need modifications, the HS command allows the handles to be
reassigned. This command is very useful if the program uses commands such as SB, CB, MB, and SA which
imply that a specific handle is to be used.

ARGUMENTS: HS a=b

where

a = the first handle of the switch (A - P)

b = the second handle of the switch (A - P)

USAGE:

RELATED COMMANDS:

EXAMPLES:

This example demonstrates a master controller, M2, searching for other controllers on each handle and
forcing them to communicate at a specific handle. This is necessary when using the

@IN (Input)

,

SB (Set

Bit)

,

CB (Clear Bit)

,

SA (Send Command)

or

MB (Modbus)

commands, because they reference specific

handles.

The Jump condition logic below ((_IHA0+4)<>_IA)|(_IHA2<>-2) is basically running the

SH (Servo

Here)

command on the given line if the IP address is not equal to the controller own IP address + 4 and if

the connection type is not TCP/IP.

),1'B0

-3),1'B0 B,+$ !B,$ _ B,+$! -3),1'B0
-3),1'B0 B,+% !B,$ _ B,+%! +6% $-3),1'B0
-3),1'B0 B,+& !B,$ _ B,+&! +6& $-3),1'B0
-3),1'B0 B,+' !B,$ _ B,+'! +6' $-3),1'B0
-3)B0B'1 B,++ !B,$ _ B,++  +6+ $-3),1'B0

)B0B'1$%
),1'B0

While Moving

Yes

Default Value

n/a

In a Program

Yes

Default Format

n/a

Command Line

Yes

Can be Interrogated

No

Used as an Operand

No

Distributed Control

No, Local

"HC" Handle

Connect

“HR”

Handle Restore

“IH”

Internet Handle

HSC=D

Connection for handle C is assigned to handle D. Connection for
handle D is assigned to handle C.

Advertising