Preventing Character Loss When Using Barcode Scanners

  • 7021430
  • 12-Nov-2014
  • 02-Oct-2018

Environment

Reflection Desktop 16.0 and higher
Reflection 2014 R1 SP1
Reflection Pro 2014 R1 SP1
Reflection X 2014 R1 SP1
Reflection for UNIX and OpenVMS 2014 R1 SP1
Reflection for IBM 2014 R1 SP1

Situation

When using a barcode scanner, card reader, or other input device with Reflection 2014 or Reflection Desktop, character loss may be experienced. This technical note describes how to resolve this problem.

Resolution

Background

Microsoft Windows sends input gathered from a barcode scanner as individual keystrokes. These keystrokes are sent at a much faster rate than a human can produce. Subsequently, when Reflection 2014 attempts to handle the rapid arrival of keystrokes, the extra processing required can result in character loss because Windows blocks keyboard input when an application is busy.

Automatic Device Recognition

Reflection 2014 R1 SP1 (and later) automatically recognizes certain USB barcode scanners and card readers, and captures their input directly to avoid any character loss. To view the list of supported scanners, open the InputDeviceCapture.settings file located in Reflection’s AppData directory: %AppData%\Attachmate\Reflection\Workspace\R2014_R1. When a device is successfully detected, a log entry is written to the event log. Please see KB 7021466 for details on controlling Reflection Event Logging.

Manually Configuring Reflection to Recognize Your Device

If your input device is not automatically recognized, you can add its hardware device identifier as a Custom Workspace Setting:

  1. Open the Windows Device Manager and find the Human Interface Device section as illustrated below. (Make sure you are viewing devices in the Human Interface Device section and not the Keyboards section.)
 
Figure 1. Device Manager with Human Interface Devices selected
  1. Find your scanning device by examining the properties listed in the Details tab of each USB device.

It can be difficult to distinguish the scanner from other devices (such as your keyboard), but the “Bus reported device description” (if present) often displays the device information. You may need to unplug the input device, refresh, and then plug the device back in to reveal which entry corresponds to the device in question.

  1. After you have identified the scanner, open the USB Input Device Properties dialog box and copy the listed value of the Hardware Id to the clipboard:

Figure 2. Copy of Hardware Id in USB Input Device Properties
  1. On the Reflection menu, choose Workspace Settings. Then on the Reflection Workspace Settings breadcrumb, select Custom settings.

Figure 3. Reflection Workspace Settings with Custom Settings selected
  1. Manually add a Custom Workspace Setting named InputDevices and paste the Hardware Id as its value. (If you have more than one device, you can enter a list of the Hardware Ids separated by commas as the InputDevices value.)

Figure 4. Paste of Hardware Id as InputDevices value in Custom Workspace Setting
  1. Restart the Workspace to apply the new settings.
  2. Start a session, and then check the Reflection event log to make sure your device has been recognized properly.

Disabling Input Device Capture

If you experience any problems with how the Input Device Capture feature captures the input, you can disable this feature to send the input key-by-key instead of as one block.

To disable Reflection’s Input Device Capture feature:

  1. Add the InputDeviceCapture value to the Reflection Workspace Custom Settings table.
  2. Set it to False.

Handling Unrecognized (non-USB) Input Devices

If you are using a non-USB scanner (one connected to the PC via a serial RS232 COM port, keyboard wedge, or some other method), Reflection 2014 cannot capture the input directly. For these types of devices, use the following approaches to eliminate character loss.

Disable Productivity Features

When Reflection Productivity features are enabled, the extra processing required to handle the keystrokes can result in character loss because Windows blocks keyboard input when an application is busy. Therefore, Productivity features such as Recent Typing, Auto Complete, Auto Expand, and Spell Check should be disabled when using an unrecognized input device.


Figure 5. Configure Productivity Defaults menu with features deselected

Adjust Intercharacter Delay

If disabling the Productivity Features does not address character loss, a possible solution is to adjust the intercharacter delay. Most scanners include an option to add (or increase) delay between each character sent. A delay of 20 to 40 milliseconds is often enough to eliminate character loss.

Scanners are often controlled by barcodes that are scanned to change the settings, though some require a configuration program to be executed to change the delay settings. Consult your scanner’s hardware manual or vendor’s website for instructions on how to set the intercharacter delay for your specific device.

Additional Information

Legacy KB ID

This document was originally published as Attachmate Technical Note 2756.

Feedback service temporarily unavailable. For content questions or problems, please contact Support.