Browse
(440) 299-7778
Menu
(440) 299-7778
One-year parts and labor warranty30-day money-back guaranteeContact

The text of a manual · part 8 of 21

Remote I/O Scanner 1747-SN User Manual: Scanner Configuration and Programming, pages 54 to 62

Pages 54 to 62 of 171, from Remote I/O Scanner 1747-SN User Manual

The original document is the PDF (1.1 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.

For the Allen-Bradley 1747-SN

Page 54

4-10

Scanner Configuration and Programming

Illegal Configuration Examples Having a primary device configured at Logical Rack 1, Logical Group 2 (bit 5) would be illegal since this image space is already being used by a complementary device. Having a complementary device configured at Logical Rack 10, Logical Group 2 (bit 9) would also be illegal since this image space is already being used by a primary device. Note that the complementary device at Logical Rack 8, Logical Group 2 could be an ASB using 10 words (1-1/4 logical racks) of data, and thereby cross into RIO Logical Rack 9. The G file configuration on page 2-6 would provide the primary and complementary input images to the scanner, which are illustrated on the following pages. Note that the output images would be the same.

Example Scanner Input Image of the Primary Devices Below are the primary device addresses and sizes. The following page contains complementary device addresses and sizes. • Device 1 - starting at Logical Rack 0, Logical Group 2 is a primary 3/4 logical rack device. • Logical Rack 1, Logical Group 0 contains no primary device. • Device 2 - starting at Logical Rack 1, Logical Group 6 is a primary 1/4 logical rack device. • Device 3 - starting at Logical Rack 2, Logical Group 0 is a primary 3/4 logical rack device. • Device 4 - starting at Logical Rack 3, Logical Group 2 is a primary 1/4 logical rack device. • Device 5 - starting at Logical Rack 3, Logical Group 6 is a primary 1/4 logical rack device.

Publication 1747-UM013B-EN-P - January 2005

Page 55

Scanner Configuration and Programming

4-11 e = slot number of the SLC chassis containing the scanner

Bit Number (decimal) Logical Rack 0 Group 0

15

14

13

12

11

10

9

8

7

6

5

4

3

2

1

0

Word 0

SLC Input File Address I:e.0

Logical Rack 0 Group 1

Word 1

I:e.1

Logical Rack 0 Group 2

Word 2

I:e.2

Logical Logical Rack 0 Group 3 Rack 0 Logical Rack 0 Group 4

Word 3

I:e.3

Word 4

I:e.4 I:e.5

Logical Rack 0 Group 6

Word 5 Word 6

Logical Rack 0 Group 7

Word 7

I:e.7

Logical Rack 1 Group 0

Word 8

I:e.8

Logical Rack 1 Group 1

Word 9

I:e.9

Logical Rack 1 Group 2

Word 10

I:e.10

Word 11

I:e.1 1 I:e.12

Logical Rack 1 Group 5 Logical Rack 1 Group 6

Word 12 Word 13 Word 14

Logical Rack 1 Group 7

Word 15

Logical Rack 2 Group 0

Word 16

I:e.15 I:e.16

Logical Rack 2 Group 1 Logical Rack 2 Group 2

Word 17 Word 18

I:e.17

Logical Logical Rack 2 Group 3 Rack 2 Logical Rack 2 Group 4

Word 19

I:e.19

Word 20 Word 21

I:e.20

Word 22

I:e.22

Logical Rack 2 Group 7

Word 23

I:e.23

Logical Rack 3 Group 0

Word 24

I:e.24

Logical Rack 3 Group 1

Word 25

I:e.25

Logical Rack 3 Group 2

Word 26

I:e.26

Word 27

I:e.27

Word 28

I:e.28

Logical Rack 3 Group 5 Logical Rack 3 Group 6

Word 29 Word 30

I:e.29

Logical Rack 3 Group 7

Word 31

I:e.31

Logical Rack 0 Group 5

Logical Logical Rack 1 Group 3 Rack 1 Logical Rack 1 Group 4

Logical Rack 2 Group 5 Logical Rack 2 Group 6

Logical Logical Rack 3 Group 3 Rack 3 Logical Rack 3 Group 4

Bit Number (octal)

Device 1

I:e.6

I:e.13 I:e.14

I:e.18

Device 2

Device 3

I:e.21

I:e.30

17 8

16 8

15 8

14 8

13 8

12 8

11 8

10 8

78

68

58

48

38

28

18

Device 4

Device 5

08 = not used

Example Scanner Input Image of the Complementary Devices Below are the complementary device addresses and sizes. The previous page contains primary device addresses and sizes. • Device 6 - starting at Logical Rack 8, Logical Group 2 is a complementary 3/4 logical rack device. • Device 7 - starting at Logical Rack 9, Logical Group 0 is a complementary 1/2 logical rack device. • Device 8 - starting at Logical Rack 9, Logical Group 6 is a complementary 1/4 logical rack device. • Device 9 - starting at Logical Rack 10, Logical Group 0 is a complementary 1/4 logical rack device. • Device 10 - starting at Logical Rack 11, Logical Group 2 is a complementary 1/2 logical rack device. • Logical Rack 11, Logical Group 6 has no complementary device.

Publication 1747-UM013B-EN-P - January 2005

Page 56

4-12

Scanner Configuration and Programming e = slot number of the SLC chassis containing the scanner

Bit Number (decimal) Logical Rack 8 Group 0

15

14

13

12

11

10

9

8

7

6

5

4

3

2

1

0

Word 0

SLC Input File Address I:e.0

Logical Rack 8 Group 1

Word 1

I:e.1

Logical Rack 8 Group 2

Word 2

I:e.2

Logical Logical Rack 8 Group 3 Logical Rack 8 Group 4 Rack 8 Logical Rack 8 Group 5

Word 3

I:e.3

Word 4

I:e.4

Word 5 Word 6

I:e.5

Logical Rack 8 Group 6 Logical Rack 8 Group 7

Word 7

I:e.7

Logical Rack 9 Group 0

Word 8

I:e.8

Logical Rack 9 Group 1

Word 9

I:e.9

Logical Rack 9 Group 2

Word 10

I:e.10

Logical Logical Rack 9 Group 3 Logical Rack 9 Group 4 Rack 9 Logical Rack 9 Group 5

Word 11

I:e.11

Word 12

I:e.12

Word 13

I:e.13

Logical Rack 9 Group 6 Logical Rack 9 Group 7 Logical Rack 10 Group 0

Word 14 Word 15 Word 16

I:e.14

Logical Rack 10 Group 1

Word 17

I:e.17

Logical Rack 10 Group 2

Word 18

I:e.18

Logical Logical Rack 10 Group 3 Logical Rack 10 Group 4 Rack 10 Logical Rack 10 Group 5

I:e.15 I:e.16

Word 19

I:e.19

Word 20 Word 21

I:e.20

Logical Rack 10 Group 6

Word 22

I:e.22

Logical Rack 10 Group 7 Logical Rack 1 1 Group 0

Word 23

I:e.23

Word 24

I:e.24

Logical Rack 1 1 Group 1

Word 25

I:e.25

Logical Rack 1

1 Group 2

Word 26

I:e.26

Logical Rack 1 1 Group 3

Word 27

I:e.27

1 Group 6

Word 30

Logical Rack 1 1 Group 7

Word 31

Bit Number (octal)

Device 7

Device 8 Device 9

I:e.21

Logical Logical Rack 1 1 Group 4 Word 28 Rack 11 Logical Rack 1 1 Group 5 Word 29 Logical Rack 1

Device 6

I:e.6

I:e.28

Device 10

I:e.29 I:e.30 I:e.31

17 8

16 8

15 8

14 8

13 8

12 8

11 8

10 8

78

68

58

48

38

28

18

08 = not used

Considerations When Configuring Remote I/O

The following sections contain information that you must understand before you configure your scanner’s G file.

G File Considerations • You can only change the RIO configuration by modifying the G file while offline in your program file. Your application program cannot access the G file, nor can you access it while online with your programming device. However, your SLC control program can dynamically inhibit and uninhibit RIO devices via the M0 file. • RIO devices larger than 1 logical rack appear as multiple devices on the RIO link. Refer to the Crossing Logical Rack Boundaries section below.

Publication 1747-UM013B-EN-P - January 2005

Page 57

Scanner Configuration and Programming

4-13

• The address and size of the devices you list in the G file must match the settings of each RIO device.

Crossing Logical Rack Boundaries You express remote I/O image boundaries in an even number of groups. For example, the 1747-ASB image can be any size from two logical groups up to 32 logical groups (four logical racks), in 2 logical group increments. If the scanner image assigned to an adapter is greater than 8 logical groups (one logical rack), the image crosses logical rack boundaries. If the scanner image assigned to an adapter is less than 8 logical groups, it too can cross a logical rack boundary depending upon the starting logical group number. The significance of crossing logical rack boundaries is discussed in the next section.

Examples of Crossing Logical Rack Boundaries Examples 1 and 2 that follow show adapters with logical image sizes that cross logical racks 0 and 1. The image size of the adapter in example 1 consumes all of logical rack 0 (eight logical groups) and half of logical rack 1 (four logical groups). The image size of the adapter in example 2 consumes two groups in logical rack 0 and four groups in logical rack 1.

Crossing Logical Rack Boundaries - Example 1

Crossing Logical Rack Boundaries - Example 2

Scanner Input or Output Image Bit Number (Decimal)

Logical Rack 0

Logical Rack 1

15

8 7

Scanner Input or Output Image Bit Number (Decimal)

0

Group 0 Group 1 Group 2 Group 3 Group 4 Group 5 Group 6 Group 7 Group 0 Group 1 Group 2 Group 3 Group 4 Group 5 Group 6 Group 7

Adapter Image

Logical Rack 0

Logical Rack 1

Adapter image is 12 logical groups in size and crosses a logical rack boundary due to its size.

15

8 7

Group 0 Group 1 Group 2 Group 3 Group 4 Group 5 Group 6 Group 7 Group 0 Group 1 Group 2 Group 3 Group 4 Group 5 Group 6 Group 7

0

Adapter Image

Adapter image is 6 logical groups in size and crosses a logical rack boundary due to its starting logical group number. .

Creating More than One Logical Rack Device RIO discrete transfers occur on a logical device basis, not on an adapter basis. A logical device is any portion of a logical rack that is assigned to a single adapter. Publication 1747-UM013B-EN-P - January 2005

Page 58

4-14

Scanner Configuration and Programming

When the scanner image assigned to an adapter is more than one logical device, the scanner sees the single physical device as multiple logical devices on the RIO link. The scanner communicates with each logical device independently, even if the logical devices are all assigned to one adapter. If a physical device image is more than one logical device, the following is true: • The scanner does not update all of the adapter image at the same time. The number of logical devices determines the number of RIO discrete transfers that are needed to update the entire adapter image. • The adapter may receive different communication commands for each logical device. In this case, the adapter decides which command it responds to.

Scanner Input or Output Image Bit Number (Decimal)

In this example the adapter is configured to start at Logical Rack 0, Logical Group 0, and uses 14 words of I/O image. Note that two RIO discrete transfers are required for the scanner to update the adapter image containing two logical devices.

Logical Rack 0

Logical Rack 1

Understanding M Files

Group 0 Group 1 Group 2 Group 3 Group 4 Group 5 Group 6 Group 7 Group 0 Group 1 Group 2 Group 3 Group 4 Group 5 Group 6 Group 7

15

8 7

0

Logical Device

Adapter Image Logical Device

M Files Overview The scanner provides RIO device control and status information through the M0 and M1 files. The M0 file is a control file. The M1 file is a status file The SLC processor does not automatically update M file data during the end of the program scan as it does I/O scans. Instead, M file values act as interrupts and are immediately read from or written to upon the execution of the ladder logic instruction in which they are used. When M file data (bits or words) is addressed in the ladder program, the processor stops scanning the program to read or write the M file data to/from the scanner module. M file bits/words in the ladder program will, therefore, impact the ladder scan time. If scan time is critical, it is better to set binary file bits and copy them all at once to the M0 file, or copy a portion of the M1 file to a binary file and then address the binary file in the program. Refer to the ladder example that follows. For more information on M files, refer to

Publication 1747-UM013B-EN-P - January 2005

Page 59

Scanner Configuration and Programming

4-15

Appendix B. You can find M file information relating to Block Transfer operations in Chapter 5, Block Transfer.

Rung 2:0 To decrease program scan time, copy the first four words of the M1 File to a binary file and use these addresses throughout the program to access block transfer done, error, data, etc. information without interrupting the program scan many times. | +COP±±±±±±±±±±±±±±±±+ |±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±+COPY FILE +±| | |Source #M1:1.100| | |Dest #B3:0| | |Length 4| | +±±±±±±±±±±±±±±±±±±±+ Rung 2:1 Examine B3/13 (B3:0/13), an internal storage bit, to determine when a block transfer is done. Note that examining multiple individual M±file bits directly (every scan) can measurably increase processor scan time. | ºBT DONEº | B3 +COP±±±±±±±±±±±±±±±±+ |±±±±] [±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±+COPY FILE +±| | 13 |Source #B3:10| | |Dest #N10:0| | |Length 64| | +±±±±±±±±±±±±±±±±±±±+ | Rung 2:2 Examine B3/12 (an internal storage bit) to determine if a BT error occurred. Buffer the BT status from B3:3 if an error does occur. | ºBT ERRORº | | B3 +MOV±±±±±±±±±±±±±±±±+ |±±±±] [±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±+MOVE +± | 12 |Source B3:3| | | 0000000000000000| | |Dest N10:64| | | 0| | +±±±±±±±±±±±±±±±±±±±+ Rung 2:3 | |±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±±+END+±±±±±±±±±±±±±±±±±±±±±±±±±±±±± |

IMPORTANT

If you are using an SLC 5/02 processor, M file data cannot be directly monitored. To monitor M files, you must move the M file words into an SLC file that can be monitored, e.g., an integer “N” file. SLC 5/03 or later processors allow you to monitor M files directly. However, do not address M file bits more than necessary throughout your application program. The processor accesses M files like immediate I/O. Therefore, excessive addressing of M files can greatly increase SLC processor scan time. For more information on M files, refer to Appendix B.

Publication 1747-UM013B-EN-P - January 2005

Page 60

4-16

Scanner Configuration and Programming

M0 Control File Description You can control the operation of individual devices on the RIO link with M0 word 8 through M0 word 27 (M0:e.8 through M0:e.27). Through your application program, you can use the M0 file to: • Device Inhibit - command the 1747-SN RIO Scanner to stop scanning an RIO device by using words 8 through 11. • Device Reset - command an RIO device’s outputs to reset while the SLC processor is in Run or Test mode by using words 16 through 19. • Remote Output Reset - command an RIO device’s outputs to reset upon the SLC processor leaving Run mode (regardless of the RIO device’s Hold Last State setting), or while in Test mode by using words 24 through 27. If you do not modify the Device Reset and Remote Output Reset words, the device outputs reflect the scanner output image whenever the SLC processor is in Run mode. If the SLC processor is in Program, Test, or Fault mode, it instructs the device to reset its outputs. M file data is nonretentive. Upon entering Run or Test modes, the SLC processor sets the M0 file to a default state. The processor does not use the M0 file until a full program scan occurs (after entering Run mode). This allows you to change the M file settings before they take effect.

IMPORTANT

Publication 1747-UM013B-EN-P - January 2005

The 1747-SN RIO Scanner does not use M0 words 0 through 7.

Page 61

Scanner Configuration and Programming

4-17

M0 (Control) File - RIO Device Control Words 15

14

13

12

11

10

9

8

7

6

5

4

3

2

1

0

Logical Rack 0 Device Inhibit Word 8 x x x x x x x x x x x x

0

1

1

0

M0:e.8

Logical Rack 1 Device Inhibit Word 9 x x x x x x x x x x x x

0

0

0

0

M0:e.9

Logical Rack 2 Device Inhibit Word 10 x x x x x x x x x x x x

1

0

0

1

M0:e.10

Logical Rack 3 Device Inhibit Word 11 x x x x x x x x x x x x

0

0

0

1

M0:e.11

Logical Rack 0 Device Reset Word 16 x x x x x x x x x x x x

0

0

0

0

M0:e.12

Logical Rack 1 Device Reset Word 17 x x x x x x x x x x x x

0

0

0

0

M0:e.13

Logical Rack 2 Device Reset Word 18 x x x x x x x x x x x x

0

0

0

0

M0:e.14

Logical Rack 3 Device Reset Word 19 x x x x x x x x x x x x

0

0

0

0

M0:e.15

Logical Rack 0 Remote Output Reset Word 24 x x x x x x x x x x x x

1

0

0

1

M0:e.16

Logical Rack 1 Remote Output Reset Word 25 x x x x x x x x x x x x

0

0

0

1

M0:e.17

Logical Rack 2 Remote Output Reset Word 26 x x x x x x x x x x x x

0

0

1

0

M0:e.18

Logical Rack 3 Remote Output Reset Word 27 x x x x x x x x x x x x

0

0

1

0

M0:e.19

Bit Number

Device Inhibit Control Device Reset Control Output Reset Control e = slot number of the SLC rack containing the scanner x = bit not used/defined

IMPORTANT

Control functions (i.e., device inhibit, device reset, and device output reset) are only selectable for the primary device, but also apply to the complementary device. Control functions for complementary devices cannot be exclusively enabled.

M0 File - RIO Device Inhibit Control M0 Words 8 through 11 - you use these words to command the scanner to stop scanning logical racks 0, 1, 2, and 3. Bits 0 to 3 in each word correspond to I/O group locations within logical racks 0, 1, 2, and 3. To stop scanning (inhibit) a device listed in the configuration (G) file, set the bit corresponding to the starting group address of the device to 1. Setting bits that do not correspond to the device logical starting group address will not inhibit the device. To resume scanning a device, reset the bit (which corresponds to the starting group address of the device) to 0. Inhibiting a device does not affect the current settings of the Device Fault Status (words 12 to 15 of the M1 file). Inhibited devices eventually time out and either return to their last state or reset (depending on the device’s last state setting).

Publication 1747-UM013B-EN-P - January 2005

Page 62

4-18

Scanner Configuration and Programming

Default: When the processor enters the Run mode, the scanner automatically inhibits any device not configured in the G file (bit set to 1). Attempting to inhibit an unconfigured device has no effect.

M0 (Control) File Words 8 through 11 Bit Number (decimal)

15

14

13

12

11

Not 10

Defined 9 8

Logical Rack 0 Device Inhibit Word 8 x x x x x x x

Logical Rack 1 Device Inhibit Word 9 x x x x x x

Logical Rack 2 Device Inhibit Word 10 x x x x x

Logical Rack 3 Device Inhibit Word 11 x x x x x

Starting Group 4 2

6

0

7

6

5

4

3

2

1

0 x x x x x

0

1

1

0

M0:e.8 x x x x x x

0

0

0

0

M0:e.9 x x x x x x x

1

0

0

1

M0:e.10 x x x x x x x

0

0

0

1

M0:e.11

M0 File e = slot number of the SLC rack containing the scanner x = not used/defined

Example of Device Inhibit Control The 1747-SN Scanner inhibits (sets to 1) the bits in M0:e.8 through M0:e.11 (by default) wherever there are no configured devices present. The illustration below compares the configured devices (G file word 2) to the groups that the scanner automatically inhibits.

G File 6 Device Address, Word 1

RIO Logical Rack 3 Starting Group 4 2 0

RIO Logical Rack 2 Starting Group 4 2 0

6

6

RIO Logical Rack 1 Starting Group 4 2 0

RIO Logical Rack 0 Starting Group 4 2 0

6

1

1

1

0

0

1

1

0

1

1

1

1

1

0

0

1

Bit Number (decimal) Logical Rack 0 Device Inhibit Word 8

15

14

13

12

11

10

9

8

7

6

5

4

3

2

1

0

M0 File x x x x x x x x x x x x

0

1

1

0

M0:e.8

M0 (Control) File Logical Rack 1 Device Inhibit Word 9 x x x x x x x x x x x x

0

0

0

0

M0:e.9

Logical Rack 2 Device Inhibit Word 10 x x x x x x x x x x x x

1

0

0

1

M0:e.10

Logical Rack 3 Device Inhibit Word 11 x x x x x x x x x x x x

0

0

0

1

M0:e.11 e = slot number of the SLC rack containing the scanner x = not used/defined

M0 File - RIO Device Reset Control M0 Words 16 through 19 - you use these words to command a reset (0) of RIO device outputs when the SLC processor is in Run or Test mode. This allows you to selectively reset logical device outputs based on a previous condition(s) that you defined. Bits 0 to 3 correspond to the logical I/O group locations within logical racks 0, 1, 2, and 3. To command an RIO device to a reset (0) condition (from Run or Test mode), set the bit corresponding to the starting logical address of the device to 1. Setting bits that do not correspond to a device starting

Publication 1747-UM013B-EN-P - January 2005