The text of a manual · part 30 of 37
Sharp Programmable Controller New Satellite JW10 User's Manual: Chapter 13 How to Use Communication Port, pages 235 to 243
Pages 235 to 243 of 307, from Sharp Programmable Controller New Satellite JW10 User's Manual
The original document is the PDF (5.0 MB). This is its text as extracted, unedited; tables and drawings read best in the PDF, and each page heading opens it at that page.
Filed in the catalog under the Sharp jW-10CM
Page 235
Stop PC operation
Function
Stop PC operation.
Communication format
HLT
Command
S S A ・ ・ A D D ? R H L T C C C I ・ ・ (H) (L) (H) (L) R
Response
S S A ・ ・ A D D ♯ R H L T C C C I ・ ・ (H) (L) (H) (L) R
Write mode Mode 0, Mode 1, Mode 2 Execution condition PC operation state Stop, Run
Stop operation of PC03. (Response time: 10 ms) Example for use
Command
03?1HLT45C R Station Response number time
Response
Sum check code
03♯1HLT61C R Station Response number time
Sum check code
Note 1: A PC which has been stopped by HLT command cannot start operation again by support tool such as JW-13PG.
Restart PC operation
Function
Release HLT (stop PC operation) command, restart PC operation.
Communication format
RUN
Command
S S A ・ ・ A D D ? R R U N C C C I ・ ・ (H) (L) (H) (L) R
Response
S S A ・ ・ A D D ♯ R R U N C C C I ・ ・ (H) (L) (H) (L) R
13
Write mode Mode 0, Mode 1, Mode 2 Execution condition PC operation state Stop, Run
Restart operation of PC03. (Response time: 10 ms) Example for use
Command
03?1RUN38C R Station Response number time
Response
Sum check code
03♯1RUN54C R Station Response number time
Sum check code
Note 1: RUN command restarts a PC which has been stopped by HLT command. When the PC has stopped by other causes such as set to program mode by JW-13PG, it cannot restart operation even RUN command is executed. In these cases, response returns normally.
13-19
Page 236
SWE
Read out current write mode status.
Command
A S S ・ ・ A D D ? R S W E C C C I ・ ・ (H) (L) (H) (L) R
Response
A ・ ・ A D D ♯ R S W E I ・ ・ (H) (L)
Data
Data
Communication format
Function
Read out write mode status
S S C C C (H) (L) R
0: Mode 0 .... Write prohibited for all memories 1: Mode 1 .... Write enable only for data memory 2: Mode 2 .... Write enable for all memories
Write mode Mode 0, Mode 1, Mode 2 Execution condition PC operation state Stop, Run Read out write mode status of PC06. (Response time: 10 ms)
Example for use
06?1SWE3B C R
Command
Station Response number time
Response
Sum check code
06♯1SWE03B C R Station Response time number
Sum check code Mode 0
Note 1: Be mode 0 (write prohibited), at power ON.
EWR
Set PC write mode.
Command
A ・ ・ A D D ? R E W R I ・ ・ (H) (L)
Response
A S S ・ ・ A D D ♯ R E W R C C C I ・ ・ (H) (L) (H) (L) R
Data
Data
13
Communication format
Function
Set write mode
S S C C C (H) (L) R
0: Mode 0 .... Write prohibited for all memories 1: Mode 1 .... Write enable only for data memory 2: Mode 2 .... Write enable for all memories
Write mode Mode 1, Mode 2 Execution condition PC operation state Stop, Run Set write mode of PC22 to mode 2 (write allowed for all memories). (Response time: 40 ms)
Example for use
Command
22?4EWR209C R
Station Response time number
Response
Sum check code Mode 2
22♯4EWR57 C R
Station Response time number
Sum check code
Note 1: In order to prevent inadvertent accident, set the mode to "mode 0" (write prohibited) while not writing data.
13-20
Page 237
TST
Communication format
Function
Turn back the message Send back the received command as it is.
Command
A ・ ・ A D D ? R T S T M1 I ・ ・ (H) (L)
…………
S S Mn C C C (H) (L) R
Response
A ・ ・ A D D ♯ R T S T M1 I ・ ・ (H) (L)
…………
S S Mn C C C (H) (L) R
Message visible character strings (20H to 7EH of ASCII code) Max. 1024 characters Data Write mode Mode 0, Mode 1, Mode 2 Execution condition PC operation state Stop, Run
Test sending and returning of a message toward PC01. (Response time: 50 ms) Example for use
Command
01?5TSTTESTCOMMANDF1C R
Station Response time number
Response
Message
01♯5TSTTESTCOMMAND0DC R Station Response time number
Command
A ・ ・ A D D ? R P A S I ・ ・ (H) (L)
Response
A ・ ・ A D D ♯ R P A S I ・ ・ (H) (L)
Data
Sum check code
Release secret function, register password. Data
Communication format
Function
Message
Release secret/password registration
Data
PAS
Sum check code
Password
S S C C C (H) (L) R
13
S S C C C (H) (L) R
0: Release‥‥Release the secret function. 1: Temporary registration‥‥Set before regular registration 2: Regular registration‥‥Set after temporary registration
Pass word Alphanumeric 4 characters Execution condition
Data = 0 Mode 0, Mode 1, Mode 2 Write mode PC operation state Stop, Run
Data = 1, 2 Mode 2 Stop by HLT command
Regularly register password 15AE to PC05. (Response time: 20 ms) Example for use
Command
05?2PAS215AE28 C R Station Response time number
Response
Password Sum check code Regular registration
05♯2PAS62C R
Station Response time number
Sum check code
Note 1: If secret function is set, the following commands cannot be used: RPM, WPM, WSM, CTC, HLT, RUN, SES. In addition, setting of secret function on the JW10 requires a support tool such as JW-13PG to set its password which is connected to the JW10. 13-21
Page 238
Communication format
Function
Set secret function Set secret function.
A ・ A Command ・ D D ? R S E S I ・ ・ (H) (L)
Data
SES
S S C C C (H) (L) R
A S S ・ A D D ♯ R S E S C C C Response ・ I ・ ・ (H) (L) (H) (L) R
Data Execution condition
1: Enable secret function ‥‥Enable secret function by the registered password. F: Delete ‥‥Delete registered password of JW10. Data = 1 Write mode Mode 0, Mode 1, Mode 2 PC operation state Stop, Run
Data = F Mode 2 Stop by HLT command
Enable secret function of PC07. (Response time: 10 ms) Command Example for use
07?1SES10D C R Station Response number time
Response
Sum check code Enable secret function
07♯1SES5A C R Station Response number time
Sum check code
Note 1: If secret function is set, the following commands cannot be used: RPM, WPM, WSM, CTC, HLT, RUN, SES. In addition, setting of secret function on the JW10 requires a support tool such as JW-13PG to set its password which is connected to the JW10.
SEI
Check secret function (enable/disable).
A S S ・ A D D ? R S E I C C C Command ・ I ・ ・ (H) (L) (H) (L) R A ・ A D D ♯ R S E I Response ・ I ・ ・ (H) (L)
Data
Data
13
Communication format
Function
Check secret function
S S C C C (H) (L) R
0: Disable secret function 1: Enable secret function
Write mode Mode 0, Mode 1, Mode 2 Execution condition PC operation state Stop, Run Check secret function (enable/disable) of PC03. (Response time: 30ms)
Example for use
Command
03?3SEI4AC R
Station number
Response
Response time
Sum check code
03♯3SEI135C R
Station Response time number
13-22
Sum check code Enable secret function
Page 239
13-3 Data link [1] Communication specifications • Data link can communicate between one JW10 master station and maximum of seven JW10 slave stations. Master station
Slave station 1 Slave station 2
#234 = 01(H) #235 = 007(D) #237 = 000(8)
#234 = 01(H) #237 = 001(8)
Slave station 7
#234 = 01(H) #237 = 002(8)
#234 = 01(H) #237 = 007(8)
• Data link area of master station and slave station are allocated as shown below. Master station link area
▲
▲
コ1400 to コ1407 コ1410 to コ1417 Slave station 2 link area
▲
▲
コ1400 to コ1407 コ1410 to コ1417
Slave station 7 area
▲
▲
Slave Transmitting コ1400 to コ1407 station 1 Receiving コ1410 to コ1417 Slave Transmitting コ1420 to コ1427 station 2 Receiving コ1430 to コ1437 Slave Transmitting コ1440 to コ1447 station 3 Receiving コ1450 to コ1457 Slave Transmitting コ1460 to コ1467 station 4 Receiving コ1470 to コ1477 Slave Transmitting コ1500 to コ1507 station 5 Receiving コ1510 to コ1517 Slave Transmitting コ1520 to コ1527 station 6 Receiving コ1530 to コ1537 Slave Transmitting コ1540 to コ1547 station 7 Receiving コ1550 to コ1557
Slave station 1 link area
コ1400 to コ1407 コ1410 to コ1417
Note: Data are transferred between master station and slave station. They cannot be transferred between slave stations.
Item Data transfer standard Transfer rate No. of slave stations connected Link area No. of link bytes per station Communication line
Specifications EIA RS-422A or equivalent 76800, 38400 bits/s Max. 7 sets Master station: コ1400 to コ1557, slave station: コ1400 to コ1417 Master station to slave station: 8 bytes Slave station to master station: 8 bytes Shielded twisted pair cable. Party line connection. 2-wire system. Total length: 500 m (76800 bits/s), 1 km (38400 bits/s)
13-23
13
Page 240
[2] Wiring JW10 (001)
JW10 (002)
L1 L2
L1 L2
L1 L2
SHLD
SHLD
SHLD
Class-3 grounding
Class-3 grounding
〜 〜 〜 〜〜 〜〜 〜
JW10 (000)
JW10 (006)
JW10 (007)
L1 L2
L1 L2
SHLD
Class-3 grounding Shielded twisted pair cable
SHLD Class-3 grounding Class-3 grounding
Total cable length: Less than 1 km RS-422A
Note 1 : Do class-3 grounding for SHLD terminal. The operation without class-3 grounding may cause malfunction due to noise. Note 2 : Never branch a communication cable into more than 3 lines.
Good
Bad
Conjunction terminal
Connection using a connector
[3] Setting system memory • When data link function is used, set the following system memory in master and slave stations. (1) System memory of master station #234 Communication mode 01(H): Data link mode #235 No. of slave stations 001 to 007(D) #236 Transfer rate
*Note 1
00(H): 76800 bits/s, 01(H): 38400 bits/s
*Note 2
#237 Own station number 000(8) (2) System memory of slave station
13
#234 Communication mode
01(H): Data link mode
#236 Transfer rate
00(H): 76800 bits/s, 01(H): 38400 bits/s
#237 Own station number 001 to 007(8)
*Note 1 *Note 2
*Note 3
*Note 1 : To quit data link communication, set #234 as 00(H). (Computer link mode) *Note 2 : Set identical communication speed for the master station and slave stations. *Note 3 : Allocate slave station ID numbers for each with sequential numbers from 001. *Note 4 : Communication mode and station number are set on system memory. We recommend to mark these settings on a label and stick it on each case for [Example of label] Data link easily readable the set contents. #001
[4] Communication flag • Communication condition of a master station and each slave station can be confirmed by communication flag. (1) Communication flag of master station (2) Communication flag of slave station Communication flag
Contents
Communication flag
Contents
07340
While normally communicating with all slave stations: ON
07340
While normally communicating with the master station: ON
07341
While normally communicating with slave station 1: ON
07341
Not in use: OFF
07342
While normally communicating with slave station 2: ON
07342
Not in use: OFF
07343
While normally communicating with slave station 3: ON
07343
Not in use: OFF
07344
While normally communicating with slave station 4: ON
07344
Not in use: OFF
07345
While normally communicating with slave station 5: ON
07345
Not in use: OFF
07346
While normally communicating with slave station 6: ON
07346
Not in use: OFF
07347
While normally communicating with slave station 7: ON
07347
Not in use: OFF
13-24
Page 241
[Example of communication flag state] Master station
Slave station 1
Slave station 2
Slave station 3
#234 = 01(H) #235 = 003(D) #236 = 00(H) #237 = 000(8)
#234 = 01(H)
#234 = 01(H)
#234 = 01(H)
#236 = 00(H) #237 = 001(8)
#236 = 00(H) #237 = 002(8)
#236 = 00(H) #237 = 003(8)
1) In case of normal communication (Master station communicates to all save stations normally.) Master station 07340 07341 07342 07343 07344 07345 07346 07347
ON ON ON ON OFF * OFF * OFF * OFF *
Slave station 1 07340 07341 07342 07343 07344 07345 07346 07347
ON OFF * OFF * OFF * OFF * OFF * OFF * OFF *
Slave station 2 07340 07341 07342 07343 07344 07345 07346 07347
ON OFF * OFF * OFF * OFF * OFF * OFF * OFF *
Slave station 3 07340 07341 07342 07343 07344 07345 07346 07347
ON OFF * OFF * OFF * OFF * OFF * OFF * OFF *
* Not in use
2) When master station is error (Power OFF, disconnect, stop mode, module error) Master station OFF OFF OFF OFF OFF * OFF * OFF * 07347 OFF * 07340 07341 07342 07343 07344 07345 07346
Slave station 1 07340 07341 07342 07343 07344 07345 07346 07347
OFF OFF * OFF * OFF * OFF * OFF * OFF * OFF *
Slave station 2 07340 07341 07342 07343 07344 07345 07346 07347
OFF OFF * OFF * OFF * OFF * OFF * OFF * OFF *
Slave station 3 07340 07341 07342 07343 07344 07345 07346 07347
OFF OFF * OFF * OFF * OFF * OFF * OFF * OFF *
13
* Not in use
3) When slave station 1 is error (Power OFF, disconnect, stop mode, module error) Master station Slave station 1 Slave station 2 Slave station 3 OFF OFF ON ON OFF * OFF * OFF * 07347 OFF * 07340 07341 07342 07343 07344 07345 07346
07340 07341 07342 07343 07344 07345 07346 07347
OFF OFF * OFF * OFF * OFF * OFF * OFF * OFF *
07340 07341 07342 07343 07344 07345 07346 07347
ON OFF * OFF * OFF * OFF * OFF * OFF * OFF *
07340 07341 07342 07343 07344 07345 07346 07347
ON OFF * OFF * OFF * OFF * OFF * OFF * OFF *
* Not in use
Note : When slave station 1 has an error (such as power OFF, disconnection, stop mode, or module error), the master station continues communication with other normal slave stations. When slave station 1 recovers from error condition, the master station restart communication with slave station 1. 13-25
Page 242
[5] Communication timing and transmission time required (1) Communication timing of master station • The master station communicates with each slave station asynchronous with master station's scan cycle. • The master station exchanges data for data link and refreshes communication flag with scan cycle after completion of communication with slave stations. Scan time of the master station increases with the interval required for these procedures (approximately 0.2 ms).
▼
Data exchange Refresh communication flag
・・・・・・
I/O
▼
▼
▼
▼
▼
▼
I/O
▼
▼
I/O
▼
Master station PC scan cycle
Data exchange Refresh communication flag
No data exchange
▼
▼
▼
▼
One scan time
▼
Slave Slave Slave Slave Slave station 1 station 2 station 3 station 4 ・・・・ station 7
▼
Slave Slave ・・ station 1 station 2
One communication cycle
• When an error occurs during communication between the master station and slave stations, the master station does not exchange data for data link with the error occurred slave station, and turns OFF this slave station's communication flag. However, the master station exchanges data with other normal slave stations. Possible causes of errors are as follows: ① Occurrence of sum check error. ② Slave station is in stop mode or abnormal condition. ③ Slave station is not connected or there is disconnection of a cable. • When the master station is in stop mode or is in abnormal condition, it does not communicate with any slave station.
▼
▼
One scan time
Data exchange Refresh communication flag
I/O
I/O
・・・・・・
▼
Slave station PC scan cycle
Data exchange Refresh communication flag
No data exchange
I/O
▼
13
(2) Communication timing of slave station • A slave station communicates with the master station asynchronous with slave station's scan cycle. • A slave station exchanges data for data link and refreshes communication flag with scan cycle after completion of communication with the master stations. Scan time of a slave station increases with the interval required for these procedures (approximately 0.2 ms).
▼
▼
Master station
Master station
• When an error occurs during communication between the master station, the slave station does not exchange data for data link, and turns OFF its own communication flag. Possible causes of errors are as follows: ① Occurrence of sum check error. ② Slave station is in stop mode or abnormal condition. ③ Master station is in stop mode or abnormal condition. ④ Slave station is not connected or there is disconnection of a cable. 13-26
Page 243
(3) Transmission time required • Interval that a data linked master station needs to communicate with all of slave stations "T" (one communication cycle time) is as follows:
3.6 ms 7.2 ms 10.8 ms 14.4 ms 18.0 ms 21.6 ms 25.2 ms
1 2 3 4 5 6 7
38400 bits/s (#236 = 01(H))
76800 bits/s (#236 = 00(H))
Number of slave stations
7.6 ms 15.2 ms 22.8 ms 30.4 ms 38.0 ms 45.6 ms 53.2 ms
3.6 × number of slave stations [ms]
7.6 × number of slave stations [ms]
(4) Communication delay time • To receive data with data link, the following delays will occur. a) Communication from master station to slave station
14000
14000
00000
(Master station) Turns ON Input 00000
Master station
One scan time
I/O
T1
Data exchange I/O
I/O
I/O
T3
T2
00400 (Slave station 1)
I/O
I/O
I/O
T4
One scan time
Slave station 1
I/O
I/O
Data exchange I/O
T5
I/O
I/O
I/O
T6
T7
13 Turns ON Output 00400
T1: Delay on input port T2: Time until a PC detects input condition (maximum one scan time) T3: Operation time (one scan time) of data transmitting side PC (master station) T4: Time to complete transmitting operated result (maximum [one communication cycle time + one scan time]). T5: Time that data receiving side PC (slave station 1) completes writing received data onto PC's data memory (maximum one scan time) T6: Operation time of data receiving side PC (slave station 1) (one scan time) T7: Delay of output port Total delay time = T1 + T2 + T3 + T4 + T5 + T6 + T7
13-27