C Language Development Kit/Snippets/Input
From OptiWiki
On handheld terminals user input can be realised by keyboard input as well as by reading bar codes. This section contains several functions that can be used to process keyboard input and scanner input. Below you'll find descriptions on how they can be used in your application.
Sources of all input functions
To be able to use the input functions, include the following header file and source file in your project.
| Header file | input.h (source) |
|---|---|
| Source file | input.c (source) |
Functions to wait for a (specific) key
The following functions can be used to wait for a (specific) key
- WaitForKey() Wait for one key keyboard input.
- WaitForKeys() Wait for one of the specific keys in the list is pressed.
Functions to input a string by keyboard or by scanning a bar code
The following functions can be used for data input either by keyboard or by scanning a barcode.
- KeyboardInput() Input a string by keyboard input.
- KeyboardInput_SMS() SMS-style text input by keyboard.
- KeyboardNumeric() Input a numeric value by keyboard input, alignment is from left to right.
- ScanBarcode() Use the laser to scan a barcode.
- ScanBarcodeSymbol() Use the laser to scan a barcode. The barcode type id is returned.
- ScanOrKeyboardInput() Input a string by scanning a barcode or by typing keyboard.
- ScanOrKeyboardInputSymbol() Input a string by scanning a barcode or by using the keyboard when a barcode is scanned. The scanned barcode symbology ID is returned.
