Menu Commands

Revision as of 05 August 2014 13:27 by JGoss (Comments | Contribs) | (Details:)

Menu Commands are used to configure Opticon's barcode scanners. They can be issued to barcode scanners in two ways, depending on the type of interface the device has. All of Opticon's devices except for our Windows CE and Windows Mobile devices accept Menu Commands as barcodes. It is also possible to issue Menu Commands through the Serial port for certain devices.

Listings of specific Menu Commands can be found on Opticonfigure or in the Universal Menu Book. The basic barcodes available from either of these sources are a variant of the Code 39 symbology using the <space> symbol as their start and stop character.

Opticonfigure provides useful searching features, as well as the ability to generate Menu Command barcodes in Code-128 and PDF-417 form. These last two forms can be useful, as they allow concatenation of Menu Commands into a single barcode.

Issuing Menu Commands using Barcodes

ZZ, C02, and ZZ barcode with the proper start/stop characters indicated in the human-readable text.
The ZZ, C02, and an additional ZZ barcode with the commonly-used character for <Space> shown in the human-readable text.

To issue a menu command as a barcode, first, scan the proper Start barcode for the device. Most devices use a Code-39 Menu barcode encoding 'ZZ' as the Start and End barcodes. Scanning this barcode will put the device into "Menu mode." Any Menu Command barcode will be processed and the relevant setting will be changed while the device is in Menu mode(provided the scanner supports that setting.)

The scanner will give a standard "good read" beep when it has successfully processed a Menu Code, or an "Error Beep" when it has decoded a Menu barcode but cannot change the corresponding setting.

Suppose a customer wanted to set an OPN-2002 to act as a Bluetooth keyboard(Bluetooth HID profile). To do this, they would scan a 'ZZ' menu barcode, followed by a 'C02' menu barcode, and then finally another 'ZZ' menu barcode.

The first 'ZZ' menu barcode would set the device into Menu mode. The 'C02' menu barcode would reconfigure the scanner to function as a Bluetooth HID device and reset all settings to the bolded defaults in the Universal Menu Book. The final 'ZZ' menu barcode would cause the device to exit Menu mode.

Note that you can find these barcodes on page U6 of the Universal Menu Book.

Creating Menu Code Barcodes

Encoding Menu Commands into Code-39 Barcodes

Code-39 is the simplest way to encode a Menu barcode. There are many freely-available fonts to make Code-39 barcodes. To make a single Code-39 Menu barcode for the ZZ(start/end) command in a text editor, simply type <space>ZZ<space>, where the <space>'s denote the character used by the font to represent the space symbol present in Code 39. In many fonts <space> is simply the underscore ( "_" ) character.

Code 128

If you have professional barcode making software you can also make Code 128 menu code barcodes. To make a Code 128 menu code: make a Code 128 barcode and start the data with the function 3 character then follow with the menu commands. Note 3 and 4 digit codes should be transmitted with the same escape characters as if they were RS232 commands.

Issuing Menu Commands over a COM port

Many of Opticon's scanners will process Menu Commands that have been issued as text over a COM port. This can be done through the "RS232 Monitor" in Opticon's Appload tool. In Appload, select 'Utilities'->'RS232 Monitor'. From here, configure the proper COM port settings using the 'Settings' menu. In most cases the proper settings are 9600-baud with default parity, databits, and stop bits. Under 'Settings' change 'Format' to 'ASCII'.

When this configuration is done, we can try issuing a Menu Command. Good test commands are 'Z1' or 'Z3', both of which can be found in the Universal Menu Book on page U127 under the diagnostics heading. To issue a command, simply type <Esc><command><Enter>. This will output the ASCII character for <Escape>, the characters for your command, and finally the <Carriage Return> ASCII character.

For example, to issue the 'Z1' command, simply type <Esc>Z1<Enter>. Note the lack of start/stop characters, which are not neccessary when you pass Menu Commands over a COM port as opposed to scanning them. Our devices are case sensitive, so make sure the case of the command matches exactly what is in the Universal Menu Book. Opticon's scanners usually only respond to a subset of the Menu Commands present in the Universal Menu Book, so this may not work for all of our scanners.

If you would like to output settings using software other than Appload, then observe the proper RS232 settings for the scanner you are trying to communicate with. For each Menu Command you want to output, start with the ASCII <Escape> character, followed by the ASCII <Carriage Return> character.

Details:

Settings can be configured by sending commands via the serial interface. The default command format is shown below:

Command Header Command ID Command Terminator
ESC (1BH) or STX (02H) 1 ~ 2 characters (ASCII) CR (ODH) or ETX (03H)
ESC (1BH) or STX (02H) [ (5BH) if 3 characters (ASCII) CR (ODH) or ETX (03H)
ESC (1BH) or STX (02H) ] (5DH) if 4 characters (ASCII) CR (ODH) or ETX (03H)
  • 1: It is possible to send multiple command IDs between a single header and terminator, except for a single command (1-digit) IDs.
    • Input examples:
      • 1-digit command : <Esc>?<CR>?
      • 2-digit command : <Esc>??<CR>?
      • 3-digit command : <Esc>[???<CR>?
      • 4-digit command : <Esc>]????<CR>
      • 2 and 3 digits command : <Esc>??[???<CR>
  • (2) Command Usage Precautions
    • When sending multiple commands in a sequence, the subsequent command is not received while the previous command is still being executed. Since the RTS output will be in busy state while a command is executed when the Handshake is set to BUSY/READY or MODEM, it is recommended to refer to this signal for the right timing.
    • Any settings configured by commands are not retained in the nonvolatile memory. Therefore, these will be lost when the scan engine power is turned off. When the power comes back on, the scan engine will be in the configuration state saved in the nonvolatile memory. In order to save the settings with commands, send “Z2” to save all the parameters in nonvolatile memory.
    • Command changes to the following communication port settings only become active after they are saved by the Z2 command.

- Baud rate, Data length, Parity and Stop bit

NOTE: Settings made by reading 1D or 2D menu labels will be saved in non-volatile memory. Any settings made prior via commands will be saved as well.


Download Fonts


File Description Version Download
Code39Fonts.zip This zip file contains 3 true type fonts that when selected in a document will type out each character as a Code 39 character. n/a Download