READ PLC status
COMMAND %01#RT ** Cr
RESPONSE %01$RC 04 29 03 81 00 0000 BCC Cr
PLC type prog size Error flag
Version Operating Mode Error code
PLC type 2 digits
03 FP3 10K program type
04 FP1 C14, C16
05 FP1 C24, C40
13 FP3 16K program type
Version 2 digits(decimal)
Prog size 2 digits(decimal) 2720 steps expressed 03K.
Operating mode 2 digits (Hex)
bit 7 Remote mode Yes (1), No (0)
bit 6 Message exist Yes (1), No (0)
bit 5 Step execution Yes (1), No (0)
bit 4 Output refresh Yes (1), No (0)
bit 3 Break position Yes (1), No (0)
bit 2 Break mode Yes (1), No (0)
bit 1 Test mode Yes (1), No (0)
bit 0 RUN (1), PROG (0)
Error flag 2 digits (Hex)
bit 7 Operation error Yes (1), No (0)
bit 6 Battery error hold Yes (1), No (0)
bit 5 Battery error real time Yes (1), No (0)
bit 4 I/O verify error Yes (1), No (0)
bit 3 Advanced unit error Yes (1), No (0)
bit 2 N/A
bit 1 Power voltage dip Yes (1), No (0)
bit 0 Diagnostic error Yes (1), No (0)
Error code 4 digits (Hex)
The higher byte and the lower byte are swapped.
Refer to FP PLC programming manual for self diagnostic error.
ERROR %01! error code BCC Cr
Refer to error code section page.
Note: In any case a “space” can not be contained in the command
code.
SET one bit ON/OFF (output, internal relay)
COMMAND %01#WCS Y 0000 1 ** Cr
RESPONSE %01$WC BCC Cr
Command sent to station # 01 and the PLC sets Y0 (output0) to ON (1). The RESPONSE shall be returned to the computer as an acknowledgment.
Bit type Y(output), R(internal relay)
ON (1), OFF (0)
If you have the same element, in this case Y0, used as a coil in the PLC program, even though the ON/OFF condition is set in PLC, the bit memory shall be overwritten(updated) by the coil in the PLC program as soon as its executed. Therefore if you want to turn a bit ON, make sure the same element is not used as a coil in your program.
Element Number Always 4 digits. The range is variable. You will get error code “60” if element number is out of range. Element numbering method is same as it is used in a ladder program.
ERROR %01! error code BCC Cr
Refer to error code section page.
Note: In any case a “space” can not be contained in the command
code.
SET up to 8 mixed bits ON/OFF (output, internal relay)
COMMAND %01#WCP 3 Y 0002 0 R 001F 1 Y 0000 0 ** Cr
RESPONSE %01$WC BCC Cr
Command sent to station # 01 and the PLC sets 3 bits, Y2 OFF(0), R1F ON(1), Y0 OFF(0). The RESPONSE shall always be returned to the computer as an acknowledgment.
Bit type 1 to 8 bits can be set
Y(output), R(internal relay)
ON (1), OFF (0)
If you have the same element, in this case Y0, used as a coil in the PLC program the bit memory shall be overwritten(updated) by the coil in the PLC program as soon as its executed. Therefore if you want to turn a bit ON, make sure the same element is not used as a coil in your program.
Element Number Always 4 digits. The range is variable. You will get error code “60” if element number is out of range. Element numbering method is same as it is used in a ladder program.
If error %01! error code BCC Cr
Refer to error code section page.
Note: In any case, “space” can not be contained in the command
code.
SET Word unit (output, internal relay, data, timer/counter set/elapsed value)
COMMAND %01#WCC R0000 0002 E803 C800 9CFF ** Cr
start address 1st value 3rd value
end address 2nd value
(to set 3 words from WR0 to WR2)
%01#WD D00100 00103 6400 C800 1027 18FC** Cr
(to set 4 words from DT100 to DT103)
Note: Element number must be expressed by 5 digits for this command.
%01#WS 0000 0001 6400 1400 ** Cr
(to set 2 set values from Timer0 to Timer1. *2)
%01#WK 0005 0007 0000 3200 5000** Cr
(to set 3 elapsed values from Timer5 to Timer7. *2)
*2 This command is for both timers and counters. Based on the element number, it is automatically distinguished it is either timer value or counter value. WS command sends information to SV and WK command sends information to EV.
Start address First element number in range.
End address Last element number in range.
1st value Value for the first element.
2nd value Value for the second element.
3rd value Value for the third element. In this case, this is the value for the last element.
All values have to be expressed in Hex format and the higher byte and the lower byte are reversed. 12 34 -> 34 12(hex)
Maximum length of command is 118 characters. Therefore you can set a maximum of 25 words, for example DT0 to DT24.
If several PLCs are connected over a network and you want to set the same value into the same elements in all the stations then use station number “FF”. You will not get the response but you can save time.
RESPONSE %01$WC BCC Cr
%01$WD BCC Cr
%01$WS BCC Cr
%01$WK BCC Cr
The response shall be returned as an acknowledgment.
In all commands, values should be all expressed in Hex format. The higher byte and the lower byte of values are all reversed. If you want to send 1234(hex), you have to send “3412”.
WC command In this example, WC command sends 1000, 200, -100 *3 (decimal) to respectively WR0, WR1, WR2. Y(output), R(internal relay) can be used with this command.
WD command In this example, WD command sends 100, 200, 10000 and -1000*3 (decimal) to respectively DT100, DT101, DT102 and DT103. DT(data register), FL(file register), LD(link data) can be used with this command.
WS command In this example, WS command sends 100 and 200 (decimal) to respectively Timer 0 and Timer 1 set values. This command can write into SV(set value) of timer and counter.
WK command In this example, WK command sends 0, 50 and 80 (decimal) to respectively Timer 5, Timer 7 and Timer 8 elapsed values. This command can write into EV(set value) of timer and counter.
*3 PLC uses 2’s compliment. The MSB is the sign bit.
Word type WC: Y(output), R(Internal relay), L(link relay)
WD: DT(data register), FL(file register), LD(link data)
WS: SV(set value)
WK: EV(set value)
Y(output), T(timer), C(counter), R(internal relay), X(input) can be read only when PLC is in run mode or you will receive “0” if PLC is in program mode.
Element Number Always 4 digits for word number. The range is variable. You will get error code “60” if element number is out of range. Element numbering method is same as it’s used in a ladder program.
ERROR %01! error code BCC Cr
Refer to error code section page.
Note: In any case a “space” can not be contained in the command
code.