• 沒有找到結果。

Buffer memory detailed description

4.3 Buffer Memory List

4.3.2 Buffer memory detailed description

(1) INPUT area (buffer memory address: 0 to 959 (0H to 3BFH)) Data input from slave stations are stored in this area.

The specifications of the input area differ depending on the operation mode of the A1SJ71PB92D/AJ71PB92D.

POINT (1) Data are assigined to the input area in the order of GX Configurator-DP or MELSEC

ProfiMap parameter settings (in the order of station numbers).

(2) The buffer memory is reassigned if parameters are modified (deletion or addition of some slave stations) in GX Configurator-DP or MELSEC ProfiMap.

Check the sequence program after modifying the parameters.

If there are slave stations to be connected in the future, set them as reserved stations in the parameter setting.

Doing so eliminates the need to check the sequence program.

(3) The input area of the A1SJ71PB92D/AJ71PB92D does not store input data of the slave station that has become incapable of exchanging I/O data and whose bit in the slave status area (buffer memory address: 2113 to 2116 (841H to 844H)) has turned ON.

For the slave station, the input area holds the data that were stored before the failure of I/O data exchange.

(a) Normal service mode (MODE 0)

In the normal service mode (MODE 0), 60 stations are allocated to the input area with 32 bytes (16 words) reserved for each station.

An unused input area for each slave station stores 00H. 1) Example

In the example shown below, the input data lengths for the first and the second stations are set to 29 bytes and 32 bytes respectively.

Since the input data length for the first slave station is 29 bytes, 00H is stored to the unused area (the upper byte of buffer memory address 14 (EH), and 15 (FH)).

1st module input data

2nd module input data

n th module input data

60th module input data

1st module 2nd byte 1st module 4th byte

1st module 1st byte 1st module 3rd byte

1st module 29th byte

b15 b0

2nd module 2nd byte 2nd module 4th byte

2nd module 1st byte 2nd module 3rd byte

2nd module 30th byte 2nd module 32th byte

2nd module 29th byte 2nd module 31th byte b15 (Upper byte) (Lower byte) b0

: Free area (00H)

4. FUNCTIONS MELSEC-A

4-18 (b) Extended service mode (MODE E)

In the extended service mode (MODE E), the input area is allocated based on the variable data length (in byte units) for each slave station.

1) Setting data length

The data length (in byte units) for each slave station is set in the slave parameter setting (Slave Modules) of GX Configurator-DP or MELSEC ProfiMap.

Note that this slave parameter (Slave Modules) does not have to be set for slave stations with fixed data lengths.

2) Setting range for data length

The maximum data length per module is 244 bytes, and the total data length for all slave station can be set up to 1920 bytes.

When the data length is an odd number of bytes, 00H is stored to the final high byte.

3) Example

In the example shown below, the input data lengths for the first and the second stations are set to 23 bytes and 7 bytes respectively.

Since the input data length for the first slave station is 23 bytes, the upper byte of buffer memory address 11 (BH) is occupied by 00H.

The input data of the next station is assigned starting from the next buffer memory address.

0(0H)

11(BH) 12(CH)

1st module input data

2nd module input data

n th module input data

60th module input data

1st module 2nd byte 1st module 4th byte

1st module 1st byte 1st module 3rd byte

1st module 22th byte 1st module 21th byte 1st module 23th byte 0(0H)

10(AH) 11(BH)

2nd module 2nd byte 2nd module 4th byte

2nd module 1st byte 2nd module 3rd byte 12(CH)

13(DH)

2nd module 6th byte 2nd module 5th byte 2nd module 7th byte 14(EH) b15 (Upper byte) (Lower byte) b0

: Free area (00H)

4. FUNCTIONS MELSEC-A

4-19

POINT If a slave station with no input data is assigned, its space in the input area is taken over by the

next station with input data, resulting in the figure shown below.

0 (0H) Each slave station setting

Input data: Present

Input data: None

Input data: Present

Input data: Present (Data length: 0)

Input data: Present 1st station

2nd station 3rd station

4th station

5th station

Input area assignment results in A1SJ71PB92D/AJ71PB92D

Input data of 1st station Input data of 3rd station Input data of 5th station

No area is assigned for the 2nd and 4th stations that have no input data.

4. FUNCTIONS MELSEC-A

4-20

(2) OUTPUT area (buffer memory address: 960 to 1919 (3C0H to 77FH)) Data output from slave stations are stored in this area.

The specifications of the output area differ depending on the operation mode of the A1SJ71PB92D/AJ71PB92D.

POINT (1) Data are assigined to the output area in the order of GX Configurator-DP or MELSEC

ProfiMap parameter settings (in the order of station numbers).

(2) The buffer memory is reassigned if parameters are modified (deletion or addition of some slave stations) in GX Configurator-DP or MELSEC ProfiMap.

Check the sequence program after modifying the parameters.

If there are slave stations to be connected in the future, set them as reserved stations in the parameter setting.

Doing so eliminates the need to check the sequence program.

(a) Normal service mode (MODE 0)

In the normal service mode (MODE 0), 60 stations are allocated to the output area with 32 bytes (16 words) reserved for each station.

Set 00H in an unused output area assigned to each slave station.

1) Example

In the example shown below, the output data lengths for the first and the second stations are set to 1 byte and 3 bytes respectively.

Since the output data length for the first slave station is 1 byte, set 00H in the unused area (the upper byte of buffer memory address 960 (3C0H), and 961 (3C1H) to 975

1st module output data

2nd module output data

n th module output data

60th module output data

1st module 1st byte

b15 b0

960(3C0H) 961(3C1H)

974(3CEH) 975(3CFH)

2nd module 2nd byte 2nd module 1st byte 2nd module 3rd byte 976(3D0H)

977(3D1H)

991(3DFH)

b15 (Upper byte) (Lower byte) b0

: Free area (00H)

4. FUNCTIONS MELSEC-A

4-21 (b) Extended service mode (MODE E)

In the extended service mode (MODE E), the output area is allocated based on the variable data length (in byte units) for each slave station.

1) Setting data length

The data length (in byte units) for each slave station is set in the slave parameter setting (Slave Modules) of GX Configurator-DP or MELSEC ProfiMap.

Note that this slave parameter (Slave Modules) does not have to be set for slave stations with fixed data lengths.

2) Setting range for data length

The maximum data length per module is 244 bytes, and the total data length for all slave station can be set up to 1920 bytes.

When the data length is an odd number of bytes, 00H is stored to the final high byte.

3) Example

In the example shown below, the output data lengths for the first and the second stations are set to 19 bytes and 5 bytes respectively.

Since the output data length for the first slave station is 19 bytes, the upper byte of buffer memory address 969 (3C9H) is occupied by 00H.

The output data of the next station is assigned starting from the next buffer memory address.

1st module output data

2nd module output data

n th module output data

60th module output data

1st module 2nd byte 1st module 4th byte

1st module 1st byte 1st module 3rd byte

1st module 18th byte 1st module 17th byte 1st module 19th byte 2nd module 2nd byte

2nd module 4th byte

2nd module 1st byte 2nd module 3rd byte 2nd module 5th byte

b15 b0

(Upper byte) (Lower byte) 960(3C0H)

4. FUNCTIONS MELSEC-A

4-22

POINT If a slave station with no output data is assigned, its space in the output area is taken over by the next station with output data, resulting in the figure shown below.

960 (3C0H) Each slave station setting

Output data: Present (Data length: 0) Output data: Present

Input area assignment results in A1SJ71PB92D/AJ71PB92D

Output data of 1st station Output data of 3rd station

Output data of 5th station

No area is assigned for the 2nd and 4th stations that have no output data.

(3) Address information area (buffer memory address: 1920 to 2039 (780H to 7F7H)) The station number and I/O data length of each slave station are stored in this area.

Information of 60 modules is stored in the Address information area in the same order for each module.

Information for reserved stations is also stored.

(a) Address information area configuration

The address information area configuration is shown below.

1920(780H)

Station number of 1st module I/O data length of 1st module Station number of 2nd module I/O data length of 2nd module

Station number of 60th module I/O data length of 60th module

The station number of the 1st module is stored. (Initial value: FFFFH) 0000H to 007DH (0 to 125): station number

FFFFH: No station number assigned

*1 FFH: Output data not assigned

b0 b7

b8 b15

The input data length of the 1st module is stored. (Initial value:

FFH)

The output data length of the 1st module is stored. (Initial value:

FFH)

00H: The set data length is 0 although input or output data is assigned.

FFH: Input or output data are not assigned.

The A1SJ71PB92D/AJ71PB92D assigns the input and output areas according to the information stored in the address information area.

4. FUNCTIONS MELSEC-A

4-23

Example: At extended service mode (MODE E)

Address information area

Station number : 10 Input data length : 7 byte Output data length : 5 byte

963(3C3H)

1st module 2nd input byte

INPUT/OUTPUT area

1st module1st input byte

3(3H) 4(4H) 5(5H) 6(6H)

1st module 3rd input byte 2nd module 2nd input byte 2nd module 1st input byte 2nd module 4th input byte

2nd module 6th input byte

2nd module 3rd input byte 2nd module 5th input byte 2nd module 7th input byte

2nd module 2nd output byte 2nd module 1st output byte 2nd module 4th output byte 2nd module 3rd output byte 2nd module 5th output byte

b15 b0 b15 b0

Station number : 5 Input data length : 3 byte Output data length : 0 byte

1 Station number (FFFFH if not assigned) 2 Input data length (FFH if not assigned) 3 Output data length (FFH if not assigned) 1, 2 and 3 are also set in a reserved station.

(The free areas in the INPUT area are initialized with [00H].)

4 Since output from the first station has a data length of 0, (1) Data are assigined to the address information area in the order of GX Configurator-DP or

MELSEC ProfiMap parameter settings (in the order of station numbers).

(2) The buffer memory is reassigned if parameters are modified (deletion or addition of some slave stations) in GX Configurator-DP or MELSEC ProfiMap.

Check the sequence program after modifying the parameters.

If there are slave stations to be connected in the future, set them as reserved stations in the parameter setting.

Doing so eliminates the need to check the sequence program.

4. FUNCTIONS MELSEC-A

4-24

(4) Communication trouble area (buffer memory address: 2040 to 2079 (7F8H to 81FH))

When some kind of trouble occurs during communication the A1SJ71PB92D/AJ71PB92D stores the contents of the trouble in this area.

(a) Communication trouble area configuration

As shown in the following diagram, a total of 8 pieces of trouble information that consist of the trouble code, detailed data length, and detailed data can be stored.

2040(7F8H)

Trouble information area 1

Trouble information area 2

Trouble information area 3

Trouble information area 8

2040(7F8H) 2041(7F9H) 2042(7FAH) 2043(7FBH) 2044(7FCH)

Error code (refer to (4) (b) in this section.) Detailed data length (0 to 3)

Detailed data 1 Detailed data 2 Detailed data 3

How to store the trouble information can be selected from the ring type and the fixed type by turning ON or OFF the communication trouble area type selection signal (Y03).

1) Ring type

Trouble information is stored in order from the head area of the communication trouble area.

The latest trouble information is always stored in the head area of the communication trouble area.

Data 1

Ring type

Trouble information area 1 Trouble information area 2

Trouble information area 8

Data 2 Data 8 Data 9

Data 1 Data 7

Data 1

Data 8

Data 2 : The latest data

2) Fixed type

Trouble information data in areas 2 to 8 (data 1 to 7) are fixed even if the 9th or later trouble information is generated.

The data of the 9th trouble or later is stored in area 1. (Area 1 only is updated.)

Fixed type

Trouble information area 1 Trouble information area 2

Trouble information area 8

Data 2 : The latest data

All the trouble information in either type can be cleared by turning ON the communication trouble area clear request signal (Y02).

When the communication trouble detection signal reset (Y01) is turned ON, the

communication trouble detection signal (X01) turns OFF with the data in the communication trouble area retained.

4. FUNCTIONS MELSEC-A

4-25

相關文件