420
Communications Instructions Section 5-30
Limitations N must be IR 000, IR 001, IR 002, or IR 003.
S and S+4 must be in the same data area.
(S can be set to #0000 to change the RS-232C settings to their defaults.)
STUP(––) cannot be executed for the CPU Unit’s built-in RS-232C port if pin 5
on the DIP switch is ON.
STUP(––) cannot be executed within an interrupt subroutine.
Description When the execution condition is OFF, STUP(––) is not executed. When the
execution condition is ON, STUP(––) changes the PC Setup settings for the
port specified by N.
N determines which part of the RS-232C Setup is changed.
If S is a word address, the contents of S through S+4 are copied to the 5
words in the PC Setup that contain the settings for the port specified by N.
If S is input as the constant #0000, the settings for the specified port are reset
to their default values.
The following table lists the Settings Changing Flags or Protocol Macro Exe-
cuting Flags for each port. The corresponding flag will remain ON while
STUP(––) is being executed and will be turned OFF when the change has
been completed.
Application Example This example shows a program that transfers the contents of DM 0100
through DM 0104 to the PC Setup area for Serial Communications Board port
1 (DM 6555 through DM 6559) when IR 00000 is ON and IR 20708 is OFF.
NSpecified Port
IR 000 Built-in RS-232C port (PC Setup: DM 6645 to DM 6649)
IR 001 Serial Communications Board port 1 (PC Setup: DM 6555 to DM 6559)
IR 002 Serial Communications Board port 2 (PC Setup: DM 6550 to DM 6554)
IR 003 Peripheral port (PC Setup: DM 6650 to DM 6654)
SFunction
Word
address
The contents of S through S+4 are copied to the part of the PC Setup that
contains the settings for the port specified by N.
Constant
(#0000)
The settings for the port specified by N are reset to their default values.
Port Flag name Flag address
Built-in RS-232C port CPU Unit RS-232C Port Settings
Changing Flag
AR 2404
Peripheral port CPU Unit Peripheral Port Settings
Changing Flag
AR 2403
Serial Communi-
cations Board
Port 1 Protocol Macro Executing Flag IR 20708
Port 2 Protocol Macro Executing Flag IR 20712
@STUP(−−)
001
DM 0100
Address Instruction Operands
00000 LD 00000
00001 AND NOT 20708
00002 @STUP(−−)
001
DM 0100
2070800000