Barcodes

The Symbol SPT 1500 has a built-in barcode scanner (see Figure 8.6). The two buttons at the top of the device start the scan, and the barcode scanner runs along the top of the device. As you might imagine, for some vertical applications, this can be quite useful (for example, salespeople could have a catalog with barcoded items; warehouse workers could read barcodes from boxes).

Symbol SPT 1500 with barcode scanner

Figure 8-6. Symbol SPT 1500 with barcode scanner

If you want to implement barcode scanning in an application, there are some special requirements and APIs from Symbol to use. First, let’s look at some of the API calls that barcode reading brings to the Palm 3.0 OS. Then we do a code walkthrough of a sample application that scans barcodes.

For more information on the Symbol APIs or the SDK, contact Symbol Technologies (http://www.symbol.com/palm). Symbol also has a neat utility program that lets you turn the SPT 1500 device into a unit dedicated to your application. The utility allows you to reflash the device ROM to include or dedicate it to your application. For more information on this, contact Symbol.[4]

Handling Scanning in an Application

There are some minor additions to the Palm 3.0 OS. The basic support for scanning barcodes requires these simple steps:

  1. Your code needs to make sure you have a Symbol device by calling the function ScanIsPalmSymbolUnit . If it isn’t a Symbol device, make no ...

Get Palm Programming: The Developer's Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.