The text of a manual · part 5 of 18
Multi-Purpose Bar Code Workstation Series B (Catalog Number 2755-DH1) User Manual: 5 - Programming Via Escape Sequences, pages 26 to 34
Pages 26 to 34 of 132, from Multi-Purpose Bar Code Workstation Series B (Catalog Number 2755-DH1) User Manual
The original document is the PDF (1.2 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 2755-DH1
Page 26
Chapter
A–B
5
Programming Via Escape Sequences Programmable Features
The table below lists the decoder’s configuration commands and indicates the supported programming methods. Function
Enter Configuration Mode Show Configuration Exit Configuration Mode
Bar Code Symbol
Escape Sequence
• • •
•
Disable Decoding
Default Configuration
• •
Store Configuration
Auto
Reset
ROM/RAM Self Test Code Selection Check Characters (Code 39, I 2 of 5, Code 11) Minimum and Maximum Length Checking Interleaved 2 of 5 Length Checking Options UPC/EAN Options Codabar Options Code 39 Full ASCII Conversion Code ID Character Assignment Code ID Character Transmission Serial Port Configuration RTS/CTS Handshaking Intercharacter Delay Time XON/XOFF Pacing Single Read Mode
• • • • • • • • • • • • • •
Enable Next Read Header Trailer No – Read Recognition No – Read Message Reader Address System Serial Number
• • • • • •
• • • • • • • • • • • • • • • • • • • • • • •
Tab
Getting Started
Code Selection
Serial Port Configuration
Message Supplements
5–1
Page 27
Chapter 5 Programming Via Escape Sequences
Function
Good Read Beep Tone Speaker Volume Speaker/LED Control
Bar Code Symbol
Escape Sequence
• • •
• • • • • • • • •
Pulse Speaker
• • • • •
Laser Shutoff Delay Laser Redundancy Check Laser Connection Detection Continuous Read Mode Trigger Latch Mode
Tab
Speaker/LED
Laser Scanning Options
The decoder’s configuration may be changed by either sending an escape sequence to the decoder or by scanning a series of configuration bar code symbols. Programming via bar codes is covered in Chapter 6. Default parameters are indicated by an asterisk (*). Appendix A also lists the decoder’s default settings.
Escape Sequence Programming
The decoder’s configuration may be customized by commands sent from a host system. Using this feature, your host’s application program can reconfigure the decoder by sending the appropriate escape sequences. Note: Use only the escape sequences that we have provided information on. The use of undocumented escape sequences or <n> values could cause unpredictable results. Note: Configurations changed by escape sequences are not stored in nonvolatile memory (EEPROM) until the Store Configuration command Esc – y 5 Z is received by the decoder. Configurations that are changed by using the configuration bar code symbols are automatically stored in EEPROM.
Escape Sequence Syntax
Commands are sent to the decoder as groups of characters beginning with the ASCII escape character Esc, and are therefore referred to as escape sequences. Each escape sequence has the following format: Esc – y <n> <alpha> <optional> where: Esc is the ASCII escape character (hexadecimal 1B or decimal 27) . 5–2
Page 28
Chapter 5 Programming Via Escape Sequences
– is an ASCII ’–’ character (hexadecimal 2D or decimal 45). y is a lower case ASCII ’y’ character (hexadecimal 79 or decimal 121). <n> is a decimal number, one or two ASCII digits. <alpha> is an ASCII letter of the alphabet, usually upper case. The exception is when using it in a concatenated sequence (discussed later). <optional> is supplemental character data or optional data used for concatenating, or stringing, several escape sequences together. The following rules apply to all escape sequences: 1. Escape sequences must have no embedded spaces. 2. For every <alpha> there is a valid <n> range, as listed in the command description. 3. The ASCII “y” must be lower case. 4. The last <alpha> of a command sequence must be upper case.
Determining the <n> Value
In the following escape sequences, the <n> number in the transmitted escape sequence may be specified in two different ways. Method #1 is used when all of the configurable options are mutually exclusive. In this case, find the option of choice in the table and read off the value of <n> directly from the table. The first column of the table will be labeled n. For example, the escape sequence Esc – y 1 Z will immediately reset the decoder. Method #2 is used when several different options may be selected simultaneously. Where the n values are not mutually exclusive, the first column heading will be Binary Value. To determine <n>, choose the wanted functions and add up the corresponding binary values. For example, Esc – y 1 F is the escape sequence used to select Code 39, because its binary value is 1. The binary value of Interleaved 2 of 5 is 2. To select both, add the binary values 1+2 to determine <n>, which is 3. The new sequence is Esc – y 3 F.
Concatenating Escape Sequences
Most of the escape sequences sent to the decoder may be concatenated, or strung together, to reduce the number of escape sequences sent to the decoder. Concatenated escape sequences must have no embedded spaces. Spaces have been added in this manual for clarity. 5–3
Page 29
Chapter 5 Programming Via Escape Sequences
Concetenation Rules
All alpha characters, with exception of the last one in the string, must be lower case. The last alpha character must be upper case. Typically, the last character will be Z because you need to save your new configuration. The following escape sequences may be concatenated in any order. Esc – y <n> B Good Read Beep Tone Esc – y <n> C Speaker/LED Control Esc – y <n> D Intercharacter Delay Time Esc – y <n> F
Code Selection
Esc – y <n> G Check Characters Esc – y <n> H Decoding Options Esc – y <n> J
Single Read Mode
Esc – y <n> K Enable Next Read Esc – y <n> M Interleaved 2 of 5 Message Length Esc – y <n> Q Code ID Character Transmission Esc – y <n> R Laser Scanning Options Esc – y <n> S Show Configuration Esc – y <n> T
Pulse Speaker
Esc – y <n> U Minimum and Maximum Length Checking Esc – y <n> V Laser Shutoff Delay Esc – y <n> W Disable Decoding Esc – y <n> X XON / XOFF Pacing Esc – y <n> Z
Configuration Control
Although the ESC – y <n> Z escape sequence can be anywhere in a concatenated sequence, when <n> = 5, the 5 Z, in most cases, must be the last character in the string. This is because when the decoder receives the 5 Z the current configuration status is saved in the EEPROM. If any configuration changes occur after the 5 Z, they will not be saved. The exception to the above rule is the following escape sequence that may be concatenated, but must be the last escape sequence in the string. This is because the decoder will change the serial port to the new configuration immediately after the receipt of this command. Esc – y <n> P 5–4
Serial Port Configuration
Page 30
Chapter 5 Programming Via Escape Sequences
The following escape sequences cannot be concatenated with any other escape sequences.
Concatenation Examples
Esc – y <n> A
Reader Address
Esc E
Reset
Esc – y <n> I
Code ID Character
Esc – y <n> N
Header
Esc – y <n> O
Trailer
Esc – y <n> Y
No–Read Message Selection
To change your configuration to the following,
• Selected codes are to be UPC and Code 39 – [5f] • Code 39 check characters are to be verified and transmitted – [9 g] • XON/XOFF pacing is to be enabled – [1 x] you could send any one of the following six escape sequences to your decoder: Esc – y 5 f 9 g 1 X
Esc – y 9 g 1 x 5 F
Esc – y 5 f 1 x 9 G
Esc – y 1 x 5 f 9 G
Esc – y 9 g 5 f 1 X
Esc – y 1 x 9 g 5 F
To save the new configuration in EEPROM you could send Esc – y 5 Z as a separate escape sequence, or append it to the end of any one of the above escape sequences. For example, Esc – y 5 f 9 g 1 X would become Esc – y 5 f 9 g 1 x 5 Z. Note that the capital X became lower case to accommodate the 5Z.
5–5
Page 31
Chapter 5 Programming Via Escape Sequences
Getting Started
The table below lists the escape sequences used to configure the decoder in a step–by–step manner. The escape sequences are separated by tabs. For your convenience, the configuration bar code symbols in Chapter 6 are also separated by the same tabs. Appendix B lists the escape sequences in alphabetical order. Also provided are the values, defaults and page numbers.
Tab
Getting Started
Code Selection
Serial Port Configuration
Message Supplements
Speaker/LED
Laser Scanning Options
5–6
Command
Escape Sequence
Page
Show Configuration
Esc – y <n> S
5–7
Disable Decoding Reset Store Configuration ROM/RAM Self Test
Esc – y <n> W
Esc – y <n> Q
5–9 5–10 5–11 5–12
Code Selection
Esc – y <n> F
5–13
Check Characters (Code 39, I 2 of 5, Code 11) Minimum and Maximum Length Checking Interleaved 2 of 5 Length Checking Options UPC/EAN Options Codabar Options Code 39 Full ASCII Conversion Code ID Character Assignment Code ID Character Transmission
Esc – y <n> G Esc – y <n> U Esc – y <n> M
5–14 5–17 5–18
Esc – y <n> H
5–20
Esc – y <n> I Esc – y <n> Q
5–24 5–25
Serial Port Configuration
Esc – y <n> P
5–26
Intercharacter Delay Time XON/XOFF Pacing Single Read Mode Enable Next Read
Esc – y <n> D Esc – y <n> X Esc – y <n> J Esc – y <n> K
5–29 5–30 5–31 5–32
Header
Esc – y <n> N
5–33
Trailer No – Read Recognition No – Read Message Reader Address
Esc – y <n> O Esc – y <n> Q Esc – y <n> Y Esc – y <n> A
5–34 5–35 5–36 5–37
Good Read Beep Tone
Esc – y <n> B
5–38
Speaker /LED Control Pulse Speaker
Esc – y <n> C Esc – y <n> T
5–39 5–40
Laser Scanning Options " Laser Redundancy Check " Laser Connection Detection " Continuous Read Mode " Trigger Latch Mode
Esc – y <n> R
5–41
Laser Shutoff Delay
Esc – y <n> V
5–45
Esc – y <n> Z
Page 32
Chapter 5 Programming Via Escape Sequences
Show Configuration Esc – y 4 S
The Show Configuration command summarizes the decoder’s current configuration by displaying the Configuration Display Screen. To see the Configuration Display Screen, you must connect the decoder to a terminal or host display that can support a minimum of 24 lines by 80 characters. This screen may be requested from the decoder by either an escape sequence or by scanning a configuration bar code symbol.
Reading the Screen All of the items shown in brackets [ ] are configurable. All non–displayable characters of the Message components (such as carriage return) are represented as a control character represented by a caret (^) and an ASCII letter. The Non–displayable ASCII characters are shown in Appendix C. The Configuration Display Screen’s column marked OTHER CONFIG. SETTINGS will only have data if an option is enabled. For example, in the screen shown below, Interleaved 2 of 5 is shown to have length checking to be variable. UPC has an option to enable the decoding of supplemental characters. Since they are not enabled, nothing is printed in the column marked OTHER CONFIG. SETTINGS.
5–7
Page 33
Chapter 5 Programming Via Escape Sequences
Show Configuration Syntax Esc – y <n> S Function n 4 Values of n:
Show Configuration Display Screen 4
Show Configuration Example To display the Configuration Display Screen, on the host computer anddisplay terminal (if enabled) send the following escape sequence: Esc – y 4 S
If a serial printer is connected to the Display Terminal port, the contents of the display screen will be printed.
Disdable Decoding Esc – y ,n. W
When n=0 the decoder is programmed to not decode any scanned bar code symbols, including configuration bar code symbols. By disabling the decoding and transmission of data, the host computer can download escape sequences eliminating the risk of data collisions resulting from the use of the scanning device or keyboard. This option is not stored in EEPROM. Upon reset, decoding is enabled.
Disable Decoding Syntax Esc – y <n> W
Values of n:
n
Function
0 1*
Do Not Decode Bar Code Symbols Decode Bar Code Symbols
0, 1 * Default
Disable Decoding Example 1 To cause the decoder not to decode bar code symbols, send the following escape sequence: Esc – y 0 W
Disable Decoding Example 2 To enable decoding of bar code symbols, send the following escape sequence: Esc – y 1 W 5–8
Page 34
Chapter 5 Programming Via Escape Sequences
Reset Esc – y 1 Z or Esc E
Reset tests and verifies the contents of EEPROM, initiates the ROM/RAM self tests, and configures the decoder according to the contents of EEPROM. Note: When using a hand–held laser scanner or Catalog No. 2755–L2 scan head, do not trigger either device during power up. If you hold the trigger, the decoder will act as if a wand is connected. The decoder will not recognize any laser scanners until it is reset by an escape sequence, or by turning the decoder OFF and then ON.
Reset Syntax Esc – y <n> Z n
Function
1 5
Reset Store Configuration In EEPROM
Values of n:
1,5
Reset Examples To reset the decoder, send either of the following escape sequences: Esc – y 1 Z Esc E
Note: Esc E can also be used to reset the decoder. Make certain that you do not use this escape sequence as part of your application program.
Store Configuration Esc – y 5 Z
The configuration that is stored and recalled from the nonvolatile memory (EEPROM) is controlled with an escape sequence. Important: Whenever the decoder is configured using the bar code menus, new configurations are automatically stored in the EEPROM. Configuration via escape sequences is different. Once an escape sequence is received, the new configuration takes effect, but is not stored. To store the configuration in EEPROM, the Store Configuration escape sequence must be sent.
Store Configuration Syntax Esc – y <n> Z
Values of n:
n
Function
1 5
Reset Store Configuration In EEPROM 1,5
Store Configuration Example To store the current decoder configuration into EEPROM,send the following escape sequence: Esc – y 5 Z 5–9