Package com.unitech.api.usu
Class USUCtrl
- java.lang.Object
-
- com.unitech.api.usu.USUCtrl
-
- All Implemented Interfaces:
java.util.Observer
public class USUCtrl extends java.lang.Object implements java.util.Observer
-
-
Field Summary
Fields Modifier and Type Field Description java.lang.StringAPI_CHANGE_TO_RAW_FORMAT_REPLYjava.lang.StringAPI_CHANGE_TO_SSI_FORMAT_REPLYjava.lang.StringAPI_DATAjava.lang.StringAPI_DATA_CODETYPEjava.lang.StringAPI_DATAALLjava.lang.StringAPI_DATABYTEjava.lang.StringAPI_DATABYTELENGTHjava.lang.StringAPI_DATALENGTHjava.lang.StringAPI_EXPORT_SETTINGS_REPLYjava.lang.StringAPI_GET_AUTO_CONNECTION_REPLYjava.lang.StringAPI_GET_BATTERY_REPLYjava.lang.StringAPI_GET_BLUETOOTH_SIGNAL_CHECKING_LEVEL_REPLYjava.lang.StringAPI_GET_CONFIG_REPLYjava.lang.StringAPI_GET_DATA_ACK_REPLYjava.lang.StringAPI_GET_DATA_TERMINATOR_REPLYjava.lang.StringAPI_GET_FORMAT_REPLYjava.lang.StringAPI_GET_PAIRING_BARCODE_REPLYjava.lang.StringAPI_GET_SCANNER_BLUETOOTH_MAC_REPLYjava.lang.StringAPI_GET_SCANNER_BLUETOOTH_NAME_REPLYjava.lang.StringAPI_GET_SCANNER_FIRMWARE_VERSION_REPLYjava.lang.StringAPI_GET_SCANNER_SERIAL_NUMBER_REPLYjava.lang.StringAPI_GET_TARGET_SCANNER_STATUS_REPLYjava.lang.StringAPI_GET_TRIG_REPLYjava.lang.StringAPI_IMPORT_SETTINGS_REPLYjava.lang.StringAPI_SET_AUTO_CONNECTION_REPLYjava.lang.StringAPI_SET_BLUETOOTH_SIGNAL_CHECKING_LEVEL_REPLYjava.lang.StringAPI_SET_CONFIG_REPLYjava.lang.StringAPI_SET_DATA_ACK_REPLYjava.lang.StringAPI_SET_DATA_TERMINATOR_REPLYjava.lang.StringAPI_SET_INDICATOR_REPLYjava.lang.StringAPI_SET_TRIG_REPLYjava.lang.StringAPI_START_DECODE_REPLYjava.lang.StringAPI_STOP_DECODE_REPLYjava.lang.StringAPI_TARGET_SCANNERjava.lang.StringAPI_UNPAIR_REPLYjava.lang.StringAPI_UPLOAD_ALL_SETTINGS_REPLYjava.util.concurrent.ConcurrentLinkedQueue<android.os.Bundle>replyQueuethe reply bundle will store in replyQueue check the replyType key of replyQueue for reply type than get others associated key value callback bundle list: public final String API_TARGET_SCANNER="unitech.scanservice.bluetooth.target_scanner_callback"; Name:"serialNo" type:String, Name:"IsConnected" type:Boolean public final String API_DATA_CODETYPE ="com.unitech.bluetooth.dataCodeType"; Name:"codeType" type:byte Note: 1. if code type is Code39, the value is 0x01 2.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidAskScannerToUnpair()Ask scanner to forget the pairing information with current Android device ===================================== Keys in responseBundle Name: "result" Type: Integer(0 for success, others for fail) Name: "message" Type: String Name: "packageName" Type: String replyType:API_UNPAIR_REPLYvoidchangePasscode(java.lang.String passcode)voidEnterIntoRawMode()Enter into RAW mode for getting data only ===================================== Keys in responseBundle Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_CHANGE_TO_RAW_FORMAT_REPLYvoidEnterIntoSsiMode()Enter into SSI mode for getting bar code type with data ===================================== Keys in responseBundle Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_CHANGE_TO_SSI_FORMAT_REPLYvoidExportSettings(java.lang.String filepath)Export Unitech Scanner Utility Settings (Scanner configuration, Application settings) to the encrypted file. ===================================== Keys in responseBundle Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_EXPORT_SETTINGS_REPLYvoidGetAutoConnection()Get Configure Scanner to automatically connect to the host or not.voidGetDataACK()Get Configure Scanner to require ACK or not.static USUCtrlgetInstance(java.lang.String packageName, java.lang.String passcode, android.content.Context context)intgetLastResultCode()java.lang.StringgetLastResultMessage()voidGetPairingBarcode()Get the Barcode for Bluetooth Pairing and generate barcode(apply from USU version 1.1.0, F/W V1.46) ===================================== Keys in responseBundle Name: "PairingBarcodeContent" Type: String Name: "result" Type: Integer(0 for success, others for fail) Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_PAIRING_BARCODE_REPLYvoidGetScannerBatteryLevel()Get scanner battery level ===================================== Keys in responseBundle Name: "battery" Type: Integer (0=charging, 1=very low, 2=low, 3=ok, 4=full) Name: "result" Type: Integer(0 for success, others for fail) Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_BATTERY_REPLYvoidGetScannerBluetoothMacAddress()Get scanner bluetooth MAC address ===================================== Keys in responseBundle Name: "address" Type: String Name: "result" Type: Integer(0 for success, others for fail) Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_SCANNER_BLUETOOTH_MAC_REPLYvoidGetScannerBluetoothName()Get scanner bluetooth name ===================================== Keys in responseBundle Name: "name" Type: String Name: "result" Type: Integer(0 for success, others for fail) Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_SCANNER_BLUETOOTH_NAME_REPLYvoidGetScannerBtSignalCheckingLevel()Get Configure Scanner Bluetooth signal checking level.voidGetScannerDataTerminator()Get Configure Scanner Data Terminator(apply from USU version 1.1.7, F/W V1.47) ===================================== Keys in responseBundle Name: "DataTerminator" Type: Integer (0= None/Null, 1=CR, 2=LF, 3=CRLF, 4=TAB) Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_DATA_TERMINATOR_REPLYvoidGetScannerFirmwareVersion()Get scanner firmware version ===================================== Keys in responseBundle Name: "fw" Type: String Name: "result" Type: Integer(0 for success, others for fail) Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_SCANNER_FIRMWARE_VERSION_REPLYvoidGetScannerSerialNumber()Get scanner serial number ===================================== Keys in responseBundle Name: "sn" Type: String Name: "result" Type: Integer(0 for success, others for fail) Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_SCANNER_SERIAL_NUMBER_REPLYvoidGetScannerSymbologyConfiguration()Get Configure Scanner Symbology via SSI command.voidGetScannerTriggerKey()Get Enable or disable scanner trigger key.voidGetTargetScanner()Get the serial number and connection status of target scanner(apply from USU version 1.1.0, F/W V1.46) ===================================== Keys in responseBundle Name: "serialNo" Type: String Name: "IsConnected" Type: Boolean Name: "result" Type: Integer(0 for success, others for fail) Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_TARGET_SCANNER_STATUS_REPLYvoidImportSettings(java.lang.String filepath)Import Unitech Scanner Utility Settings (Scanner configuration, Application settings) from the file(s) ===================================== Keys in responseBundle Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_IMPORT_SETTINGS_REPLYvoidReceiveCurrentDataMode()Get the current scanned data mode, RAW or SSI ===================================== Keys in responseBundle Name: "format" Type: Integer (0=RAW , 1=SSI) Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_FORMAT_REPLYvoidSendACKIndicator(boolean withACK, int beepTime, boolean vibrate, java.lang.String ledColor)When scanner DATA ACK/NAK is enabled, ACK is required to be sent to the scanner.voidSetAutoConnection(boolean enable)Set Configure Scanner to automatically connect to the host or not.voidSetDataACK(boolean enable)Set Configure Scanner to require ACK or not.voidSetScannerBtSignalCheckingLevel(int level)Set Configure Scanner Bluetooth signal checking level.voidSetScannerDataTerminator(int terminator)Set Configure Scanner Data Terminator(apply from USU version 1.1.7, F/W V1.47) ===================================== Keys in responseBundle Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_SET_DATA_TERMINATOR_REPLYvoidSetScannerSymbologyConfiguration(java.lang.String symbologyName, int value)Set Configure Scanner Symbology via SSI command.voidSetScannerTriggerKey(boolean enable)Set Enable or disable scanner trigger key.voidStartDecode()Ask scanner to start decode which is the same as users press the physical scanner trigger key.voidStopDecode()Ask scanner to stop decode which is the same as users release the physical scanner trigger key.voidupdate(java.util.Observable observable, java.lang.Object o)voidUploadSettings()Upload Unitech Scanner Utility Settings (Scanner configuration) to the connected scanner ===================================== Keys in responseBundle Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_UPLOAD_ALL_SETTINGS_REPLY
-
-
-
Field Detail
-
API_GET_PAIRING_BARCODE_REPLY
public final java.lang.String API_GET_PAIRING_BARCODE_REPLY
- See Also:
- Constant Field Values
-
API_GET_TARGET_SCANNER_STATUS_REPLY
public final java.lang.String API_GET_TARGET_SCANNER_STATUS_REPLY
- See Also:
- Constant Field Values
-
API_TARGET_SCANNER
public final java.lang.String API_TARGET_SCANNER
- See Also:
- Constant Field Values
-
API_UNPAIR_REPLY
public final java.lang.String API_UNPAIR_REPLY
- See Also:
- Constant Field Values
-
API_GET_SCANNER_SERIAL_NUMBER_REPLY
public final java.lang.String API_GET_SCANNER_SERIAL_NUMBER_REPLY
- See Also:
- Constant Field Values
-
API_GET_SCANNER_BLUETOOTH_NAME_REPLY
public final java.lang.String API_GET_SCANNER_BLUETOOTH_NAME_REPLY
- See Also:
- Constant Field Values
-
API_GET_SCANNER_BLUETOOTH_MAC_REPLY
public final java.lang.String API_GET_SCANNER_BLUETOOTH_MAC_REPLY
- See Also:
- Constant Field Values
-
API_GET_SCANNER_FIRMWARE_VERSION_REPLY
public final java.lang.String API_GET_SCANNER_FIRMWARE_VERSION_REPLY
- See Also:
- Constant Field Values
-
API_GET_BATTERY_REPLY
public final java.lang.String API_GET_BATTERY_REPLY
- See Also:
- Constant Field Values
-
API_GET_TRIG_REPLY
public final java.lang.String API_GET_TRIG_REPLY
- See Also:
- Constant Field Values
-
API_SET_TRIG_REPLY
public final java.lang.String API_SET_TRIG_REPLY
- See Also:
- Constant Field Values
-
API_START_DECODE_REPLY
public final java.lang.String API_START_DECODE_REPLY
- See Also:
- Constant Field Values
-
API_STOP_DECODE_REPLY
public final java.lang.String API_STOP_DECODE_REPLY
- See Also:
- Constant Field Values
-
API_GET_DATA_ACK_REPLY
public final java.lang.String API_GET_DATA_ACK_REPLY
- See Also:
- Constant Field Values
-
API_SET_DATA_ACK_REPLY
public final java.lang.String API_SET_DATA_ACK_REPLY
- See Also:
- Constant Field Values
-
API_GET_AUTO_CONNECTION_REPLY
public final java.lang.String API_GET_AUTO_CONNECTION_REPLY
- See Also:
- Constant Field Values
-
API_SET_AUTO_CONNECTION_REPLY
public final java.lang.String API_SET_AUTO_CONNECTION_REPLY
- See Also:
- Constant Field Values
-
API_GET_CONFIG_REPLY
public final java.lang.String API_GET_CONFIG_REPLY
- See Also:
- Constant Field Values
-
API_SET_CONFIG_REPLY
public final java.lang.String API_SET_CONFIG_REPLY
- See Also:
- Constant Field Values
-
API_GET_BLUETOOTH_SIGNAL_CHECKING_LEVEL_REPLY
public final java.lang.String API_GET_BLUETOOTH_SIGNAL_CHECKING_LEVEL_REPLY
- See Also:
- Constant Field Values
-
API_SET_BLUETOOTH_SIGNAL_CHECKING_LEVEL_REPLY
public final java.lang.String API_SET_BLUETOOTH_SIGNAL_CHECKING_LEVEL_REPLY
- See Also:
- Constant Field Values
-
API_GET_DATA_TERMINATOR_REPLY
public final java.lang.String API_GET_DATA_TERMINATOR_REPLY
- See Also:
- Constant Field Values
-
API_SET_DATA_TERMINATOR_REPLY
public final java.lang.String API_SET_DATA_TERMINATOR_REPLY
- See Also:
- Constant Field Values
-
API_CHANGE_TO_SSI_FORMAT_REPLY
public final java.lang.String API_CHANGE_TO_SSI_FORMAT_REPLY
- See Also:
- Constant Field Values
-
API_CHANGE_TO_RAW_FORMAT_REPLY
public final java.lang.String API_CHANGE_TO_RAW_FORMAT_REPLY
- See Also:
- Constant Field Values
-
API_GET_FORMAT_REPLY
public final java.lang.String API_GET_FORMAT_REPLY
- See Also:
- Constant Field Values
-
API_DATA_CODETYPE
public final java.lang.String API_DATA_CODETYPE
- See Also:
- Constant Field Values
-
API_DATA
public final java.lang.String API_DATA
- See Also:
- Constant Field Values
-
API_DATALENGTH
public final java.lang.String API_DATALENGTH
- See Also:
- Constant Field Values
-
API_DATABYTE
public final java.lang.String API_DATABYTE
- See Also:
- Constant Field Values
-
API_DATABYTELENGTH
public final java.lang.String API_DATABYTELENGTH
- See Also:
- Constant Field Values
-
API_DATAALL
public final java.lang.String API_DATAALL
- See Also:
- Constant Field Values
-
API_SET_INDICATOR_REPLY
public final java.lang.String API_SET_INDICATOR_REPLY
- See Also:
- Constant Field Values
-
API_EXPORT_SETTINGS_REPLY
public final java.lang.String API_EXPORT_SETTINGS_REPLY
- See Also:
- Constant Field Values
-
API_IMPORT_SETTINGS_REPLY
public final java.lang.String API_IMPORT_SETTINGS_REPLY
- See Also:
- Constant Field Values
-
API_UPLOAD_ALL_SETTINGS_REPLY
public final java.lang.String API_UPLOAD_ALL_SETTINGS_REPLY
- See Also:
- Constant Field Values
-
replyQueue
public java.util.concurrent.ConcurrentLinkedQueue<android.os.Bundle> replyQueue
the reply bundle will store in replyQueue check the replyType key of replyQueue for reply type than get others associated key value callback bundle list: public final String API_TARGET_SCANNER="unitech.scanservice.bluetooth.target_scanner_callback"; Name:"serialNo" type:String, Name:"IsConnected" type:Boolean public final String API_DATA_CODETYPE ="com.unitech.bluetooth.dataCodeType"; Name:"codeType" type:byte Note: 1. if code type is Code39, the value is 0x01 2. Detail to see Appendix D public final String API_DATA = "unitech.scanservice.data"; Name:"text" type:String public final String API_DATALENGTH = "unitech.scanservice.datalength"; Name:"text" type:Integer public final String API_DATABYTE = "unitech.scanservice.databyte"; Name:"text" type:byte[] Note: "databyte" will return unmodified raw data from the engine, which might be different from the String "data". Thus need to use databytelength to get the correct length. public final String API_DATABYTELENGTH = "unitech.scanservice.databytelength"; Name:"text" type:Integer public final String API_DATAALL = "unitech.scanservice.dataall"; Name:"databyte" type:byte[], Name:"databytelength" type:Integer
-
-
Method Detail
-
getLastResultCode
public int getLastResultCode()
-
getLastResultMessage
public java.lang.String getLastResultMessage()
-
changePasscode
public void changePasscode(java.lang.String passcode)
-
getInstance
public static USUCtrl getInstance(java.lang.String packageName, java.lang.String passcode, android.content.Context context)
-
update
public void update(java.util.Observable observable, java.lang.Object o)- Specified by:
updatein interfacejava.util.Observer
-
GetPairingBarcode
public void GetPairingBarcode()
Get the Barcode for Bluetooth Pairing and generate barcode(apply from USU version 1.1.0, F/W V1.46) ===================================== Keys in responseBundle Name: "PairingBarcodeContent" Type: String Name: "result" Type: Integer(0 for success, others for fail) Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_PAIRING_BARCODE_REPLY
-
GetTargetScanner
public void GetTargetScanner()
Get the serial number and connection status of target scanner(apply from USU version 1.1.0, F/W V1.46) ===================================== Keys in responseBundle Name: "serialNo" Type: String Name: "IsConnected" Type: Boolean Name: "result" Type: Integer(0 for success, others for fail) Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_TARGET_SCANNER_STATUS_REPLY
-
AskScannerToUnpair
public void AskScannerToUnpair()
Ask scanner to forget the pairing information with current Android device ===================================== Keys in responseBundle Name: "result" Type: Integer(0 for success, others for fail) Name: "message" Type: String Name: "packageName" Type: String replyType:API_UNPAIR_REPLY
-
GetScannerSerialNumber
public void GetScannerSerialNumber()
Get scanner serial number ===================================== Keys in responseBundle Name: "sn" Type: String Name: "result" Type: Integer(0 for success, others for fail) Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_SCANNER_SERIAL_NUMBER_REPLY
-
GetScannerBluetoothName
public void GetScannerBluetoothName()
Get scanner bluetooth name ===================================== Keys in responseBundle Name: "name" Type: String Name: "result" Type: Integer(0 for success, others for fail) Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_SCANNER_BLUETOOTH_NAME_REPLY
-
GetScannerBluetoothMacAddress
public void GetScannerBluetoothMacAddress()
Get scanner bluetooth MAC address ===================================== Keys in responseBundle Name: "address" Type: String Name: "result" Type: Integer(0 for success, others for fail) Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_SCANNER_BLUETOOTH_MAC_REPLY
-
GetScannerFirmwareVersion
public void GetScannerFirmwareVersion()
Get scanner firmware version ===================================== Keys in responseBundle Name: "fw" Type: String Name: "result" Type: Integer(0 for success, others for fail) Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_SCANNER_FIRMWARE_VERSION_REPLY
-
GetScannerBatteryLevel
public void GetScannerBatteryLevel()
Get scanner battery level ===================================== Keys in responseBundle Name: "battery" Type: Integer (0=charging, 1=very low, 2=low, 3=ok, 4=full) Name: "result" Type: Integer(0 for success, others for fail) Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_BATTERY_REPLY
-
GetScannerTriggerKey
public void GetScannerTriggerKey()
Get Enable or disable scanner trigger key. When the trigger key is disable, the scanner does not scan when users press trigger key. ===================================== Keys in responseBundle Name: "trig" Type: Boolean (true=ON, false= OFF) Name: "result"(0 for success, others for fail) Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_TRIG_REPLY
-
SetScannerTriggerKey
public void SetScannerTriggerKey(boolean enable)
Set Enable or disable scanner trigger key. When the trigger key is disable, the scanner does not scan when users press trigger key. ===================================== Keys in responseBundle Name: "result"(0 for success, others for fail) Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_SET_TRIG_REPLY- Parameters:
enable- true to enable trigger key,fail to disable trigger key
-
StartDecode
public void StartDecode()
Ask scanner to start decode which is the same as users press the physical scanner trigger key. Together with Stop Decode can achieve remote trigger capability. ===================================== Keys in responseBundle Name: "result"(0 for success, others for fail) Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_START_DECODE_REPLY
-
StopDecode
public void StopDecode()
Ask scanner to stop decode which is the same as users release the physical scanner trigger key. Together with Start Decode can achieve remote trigger ===================================== Keys in responseBundle Name: "result"(0 for success, others for fail) Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_STOP_DECODE_REPLY
-
GetDataACK
public void GetDataACK()
Get Configure Scanner to require ACK or not. When Data ACK/NAK is configured as ON, scanner waits for ACK/NAK while transmitting each data to the host. If scanner does not receive ACK in three seconds, it will retransmit data at most three times. Note: this configuration is valid only when the scanner is in BT SPP mode and Auto Connection is ON. Data ACK must be enabled to get scanned data via API. ===================================== Keys in responseBundle Name: "ack" Type: Boolean (true=ON, false= OFF) Name: "result"(0 for success, others for fail) Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_DATA_ACK_REPLY
-
SetDataACK
public void SetDataACK(boolean enable)
Set Configure Scanner to require ACK or not. When Data ACK/NAK is configured as ON, scanner waits for ACK/NAK while transmitting each data to the host. If scanner does not receive ACK in three seconds, it will retransmit data at most three times. Note: this configuration is valid only when the scanner is in BT SPP mode and Auto Connection is ON. Data ACK must be enabled to get scanned data via API. ===================================== Keys in responseBundle Name: "result"(0 for success, others for fail) Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_SET_DATA_ACK_REPLY- Parameters:
enable- true for enable ack , fail for disable ack
-
GetAutoConnection
public void GetAutoConnection()
Get Configure Scanner to automatically connect to the host or not. When Auto Connection is configured as OFF, scanner will not proactively connect to any device but waiting for other devices to connect. Note: this configuration is valid when the scanner is in BT SPP mode. Auto Connection must be enabled to work with Scanner Utility. ===================================== Keys in responseBundle Name: "autoConn" Type: Boolean (true=ON, false= OFF) Name: "result"(0 for success, others for fail) Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_AUTO_CONNECTION_REPLY
-
SetAutoConnection
public void SetAutoConnection(boolean enable)
Set Configure Scanner to automatically connect to the host or not. When Auto Connection is configured as OFF, scanner will not proactively connect to any device but waiting for other devices to connect. Note: this configuration is valid when the scanner is in BT SPP mode. Auto Connection must be enabled to work with Scanner Utility. ===================================== Keys in responseBundle Name: "result"(0 for success, others for fail) Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_SET_AUTO_CONNECTION_REPLY- Parameters:
enable- true to enable auto-conn, fail to disable auto-conn
-
GetScannerSymbologyConfiguration
public void GetScannerSymbologyConfiguration()
Get Configure Scanner Symbology via SSI command. Detailed configuration items please refer to appendix A. ===================================== Keys in responseBundle Name: (refer to Appendix A) Type: Integer (refer to Appendix A) Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_CONFIG_REPLY
-
SetScannerSymbologyConfiguration
public void SetScannerSymbologyConfiguration(java.lang.String symbologyName, int value)Set Configure Scanner Symbology via SSI command. Detailed configuration items please refer to appendix A. ===================================== Keys in responseBundle Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_SET_CONFIG_REPLY- Parameters:
symbologyName- refer to Appendix Avalue- refer to Appendix A
-
GetScannerBtSignalCheckingLevel
public void GetScannerBtSignalCheckingLevel()
Get Configure Scanner Bluetooth signal checking level. Higher Level requires higher threshold for data sending. ===================================== Keys in responseBundle Name: "btSignalCheckingLevel" Type: Integer (0= Normal Level, 1= Higher Level) Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_BLUETOOTH_SIGNAL_CHECKING_LEVEL_REPLY
-
SetScannerBtSignalCheckingLevel
public void SetScannerBtSignalCheckingLevel(int level)
Set Configure Scanner Bluetooth signal checking level. Higher Level requires higher threshold for data sending. ===================================== Keys in responseBundle Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_SET_BLUETOOTH_SIGNAL_CHECKING_LEVEL_REPLY- Parameters:
level- (0= Normal Level, 1= Higher Level
-
GetScannerDataTerminator
public void GetScannerDataTerminator()
Get Configure Scanner Data Terminator(apply from USU version 1.1.7, F/W V1.47) ===================================== Keys in responseBundle Name: "DataTerminator" Type: Integer (0= None/Null, 1=CR, 2=LF, 3=CRLF, 4=TAB) Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_DATA_TERMINATOR_REPLY
-
SetScannerDataTerminator
public void SetScannerDataTerminator(int terminator)
Set Configure Scanner Data Terminator(apply from USU version 1.1.7, F/W V1.47) ===================================== Keys in responseBundle Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_SET_DATA_TERMINATOR_REPLY- Parameters:
terminator- 0= None/Null, 1=CR, 2=LF, 3=CRLF, 4=TAB
-
EnterIntoSsiMode
public void EnterIntoSsiMode()
Enter into SSI mode for getting bar code type with data ===================================== Keys in responseBundle Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_CHANGE_TO_SSI_FORMAT_REPLY
-
EnterIntoRawMode
public void EnterIntoRawMode()
Enter into RAW mode for getting data only ===================================== Keys in responseBundle Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_CHANGE_TO_RAW_FORMAT_REPLY
-
ReceiveCurrentDataMode
public void ReceiveCurrentDataMode()
Get the current scanned data mode, RAW or SSI ===================================== Keys in responseBundle Name: "format" Type: Integer (0=RAW , 1=SSI) Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_GET_FORMAT_REPLY
-
SendACKIndicator
public void SendACKIndicator(boolean withACK, int beepTime, boolean vibrate, java.lang.String ledColor)When scanner DATA ACK/NAK is enabled, ACK is required to be sent to the scanner. Some indicators can be sent along with the ACK or can be sent to the scanner independently ===================================== Keys in responseBundle Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_SET_INDICATOR_REPLY- Parameters:
withACK- true= with Data ACK, false = indicator only Note: If beepTime, vibrate and ledColor are not specified, and dataAck = true, only ACK is transmittedbeepTime- 0=no beep, 1=beep once, 2=beep twice, 3=beep 3 timesvibrate- false= no vibrate, true=vibrateledColor- "none"=no led, "red"=red led, "green"=green led, "blue"=blue led
-
ExportSettings
public void ExportSettings(java.lang.String filepath)
Export Unitech Scanner Utility Settings (Scanner configuration, Application settings) to the encrypted file. ===================================== Keys in responseBundle Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_EXPORT_SETTINGS_REPLY- Parameters:
filepath- default filepath = /sdcard/Unitech/USU/USU.conf Note: After version 1.2, there is only one output file by default. (If the version is lower than 1.2, two configuration files /sdcard/USUConfig.001 , /sdcard/USUConfig.002 will be exported. )
-
ImportSettings
public void ImportSettings(java.lang.String filepath)
Import Unitech Scanner Utility Settings (Scanner configuration, Application settings) from the file(s) ===================================== Keys in responseBundle Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_IMPORT_SETTINGS_REPLY- Parameters:
filepath- default filepath = /sdcard/Unitech/USU/USU.conf Note: Backward compatible import settings, the default path can import version 1.1 /sdcard/USUConfig.001, /sdcard/USUConfig.002. 1. If the file in the file path is encrypted, no passcode is required. 2. if it is plain text, you need to add a passcode.
-
UploadSettings
public void UploadSettings()
Upload Unitech Scanner Utility Settings (Scanner configuration) to the connected scanner ===================================== Keys in responseBundle Name: "result" Type: Integer Name: "message" Type: String Name: "packageName" Type: String replyType:API_UPLOAD_ALL_SETTINGS_REPLY
-
-