Baracoda Pencil 2 User Manual

Data Capture for Workforce
Communication Protocol
BaracodaPencil 2
©Baracoda TM – January 2009
in Motion
SUMMARY
SUMMARY
SUMMARYSUMMARY
Data Capture
for Workforce
in Motion
SUMMARY ................................................................... 2
REVISION HISTORY .......................................................... 3
1.
INTRODUCTION ........................................................ 4
1.1. G
1.2. G
2.
2.1. B
2.1.1. C
2.2. S
2.2.1. E
2.2.2. D
2.3. H
2.3.1. C
2.3.2. S
2.3.3. U
2.3.4. M
2.3.5. C
2.4. D
2.4.1.
2.4.2. H
2.4.3. T
2.4.4. S
2.4.5. C
2.4.6. E E
XAMPLE
E
XAMPLE
E
XAMPLE
E
XAMPLE
E
XAMPLE
ENERALITIES ENERIC PACKET
COMMUNICATION PROTOCOL .............................................. 5
IDIRECTIONAL PACKETS
ONTROL MESSAGES
CANNER TO HOST MESSAGES
NCAPSULATION SCHEME ATA STRING FORMAT
OST TO SCANNER MESSAGES
OMMUNICATION MESSAGES CANNER MESSAGES SER INTERFACE MESSAGES ISCELLANEOUS MESSAGES APTURE MESSAGES
ECODER COMMUNICATION PROTOCOL
FRAME FORMAT
EADER YPE IZE OMMAND XAMPLES
1.1 – G
2.1 – S
2.2 – S
3.1 – M
4.1 – S
.......................................................... 4
........................................................ 4
................................................... 5
.............................................. 5
................................................ 6
........................................... 6
............................................ 6
................................................ 7
......................................... 7
.............................................. 9
....................................... 11
........................................ 14
............................................. 18
.......................................... 21
................................................ 21
..................................................... 21
....................................................... 22
....................................................... 22
.................................................... 22
................................................... 30
ETTING CONFIGURATION OF CODE 39 SYMBOLOGY ETTING A CONFIGURATION OF CODABAR SYMBOLOGY ETTING A CONFIGURATION OF ALL SYMBOLOGIES ODIFYING A CONFIGURATION OF ALL SYMBOLOGIES ENDING A SPECIAL COMMAND TO CODE39 SYMBOLOGY
. ................. 30
. ................ 31
. .................. 32
. ................ 32
. ............... 33
APPENDIX 1: BLUETOOTH PROTOCOL ........................................... 34
BaracodaPencil 2 – Communication Protocol v1.3 - 2 -
Revision History
Revision History
Revision HistoryRevision History
Changes to the original manual are listed below.
Document Date Description
Data Capture
for Workforce
in Motion
1.1 26 Jan. 07
1.2 29 Sept. 08
1.3 02 Jan. 09
Initial release
Added new commands : 0x5A-0x5B : Get/Set master mode Changed "barcode prefix/suffix" into "capture prefix/suffix" Changed §2.3.5 "barcode messages" into "capture messages" Changed command 0xE0-0xE1 name to "get capture version"
Add “Decoder Communication Protocol” section Add “Appendix 1 – Bluetooth Protocol” section
BaracodaPencil 2 – Communication Protocol v1.3 - 3 -
Data Capture
Code ID
Length
Payload
1 Byte
2 Bytes
N Bytes
for Workforce
1.
1.
Introduction
Introduction
1.1.
IntroductionIntroduction
1.1.
1.1. Generalities
1.1.1.1.
BaracodaPencil 2 is a wireless data capture product. This document is detailing the protocol of communication between the Baracoda scanner Pencil2 and its foreign environment through Radio Frequency link (ie: Bluetooth). The protocol of communication does not depend on the type of link.
Wireless communication is based on the Bluetooth protocol, thanks to the embedded Baracoda Equinox Bluetooth Stack.
The messages described in this document can be: Host to scanner messages: the packet is sent only by the host to the scanner Scanner to host messages: the packet is sent only by the scanner to the host Bidirectional messages: the packet format is the same whether it is sent by the host or the scanner
Generalities
GeneralitiesGeneralities
in Motion
http://www.baracoda.com
1.2.
1.2. Generic packet
1.2.1.2.
All the frames described in this document are formatted as shown:
- 1 byte for code ID
Bits 7:5 is the logical device
Bits 4:1 is the command
Bit 0: when set, the message must be acknowledged
- 2 bytes for the size of the payload (big-endian), including the sequence number byte which is considered as part of the payload
- Payload (including 1 byte for sequence number when applicable). The response will have the same code ID as the command.
Generic packet
Generic packetGeneric packet
BaracodaPencil 2 – Communication Protocol v1.3 - 4 -
Data Capture
Code ID
Description
Frame
0x01
Legacy
0x01 0x01 0
x01
Code ID
Description
Frame
0x06
ACK 0x06 0x01 0xYY
0x15
NACK
0x15 0x01 0xYY
Code ID
Description
Frame
0x16
SYN 0x16 0x01 0xYY
for Workforce
2.
2.
Communication protocol
Communication protocol
2.2.
Communication protocolCommunication protocol
2.1.
2.1. Bidirectional packets
2.1.2.1.
2.1.1.
2.1.1. Control messages
2.1.1.2.1.1.
Bidirectional packets
Bidirectional packetsBidirectional packets
Control messages
Control messagesControl messages
2.1.1.1. Specific packets
Or
0x01 0x02 0x01 These two (2) sequences will be recognized and purged for backward compatibility with older Baracoda products.
2.1.1.2. Acknowledgment packets
in Motion
These messages acknowledge the reception of a valid message with the expected sequence number 0xYY, before processing it. For captured data from the scanner, ACK and NAK have the same meaning but will trigger a different event on the scanner.
2.1.1.3. Synchronization packet
This message acknowledges the reception of a message to acknowledge with an unexpected sequence number. 0xYY is the expected sequence number. The device will resynchronize its remote sequence number when receiving this message.
BaracodaPencil 2 – Communication Protocol v1.3 - 5 -
Data Capture
Code ID
Description
Payload
0x32
0x33
Barcode data
DATA
string
Data
0-32
0-32
0-32
for Workforce
2.2.
2.2. Scanner to host
2.2.2.2.
2.2.1.
2.2.1. Encapsulation scheme
2.2.1.2.2.1.
Scanner to host messages
Scanner to hostScanner to host
Encapsulation scheme
Encapsulation schemeEncapsulation scheme
messages
messagesmessages
2.2.2.
2.2.2. Data
2.2.2.2.2.2.
Data string format
DataData
string format
string formatstring format
in Motion
Timestamp
12 bytes
Data Prefix
bytes
Capture Prefix
0-32 bytes 0-4 bytes 0, 2 or 3 bytes - 0-4 bytes
Symbology Prefix
AIM Identifier
Barcode / RFID data
Symbology suffix
Capture suffix
bytes
suffix
bytes
BaracodaPencil 2 – Communication Protocol v1.3 - 6 -
Data Capture
Code ID
0x40
-
0x41
Description
Get Comm unicati o n Descri p t or
Payload
None
Response
2 bytes:
Code ID
0x42
-
0x43
Description
Get Retr a nsmissi o n Paramet ers
Payload
None
Response
2 bytes:
Code ID
0x44
-
0x45
Description
Set Ret r a nsmissi o n Paramet ers
Payload
2 bytes:
Response
1 b
yte:
Code ID
0x46
-
0x47
Description
Get Ca p t u re Fram e Format
Payload
None
Response
1 byte
Code ID
0x48
-
0x49
Description
Set Capt u re Frame Format
Payload
1 byte
Response
1 byte:
for Workforce
2.3.
2.3. Host to scanner
2.3.2.3.
2.3.1.
2.3.1. Communication messages
2.3.1.2.3.1.
{Wireless link: (Bit 0: Bluetooth)} {Wired link: (Bit 0: Serial Dock)}
{Max number of retransmission, 1 to 0xFE, 0xFF = infinity} {Delay between transmission, 1 to 0xFF, in tenth of seconds}
Host to scanner messages
Host to scannerHost to scanner
Communication messages
Communication messagesCommunication messages
messages
messagesmessages
in Motion
{Max number of retransmissions, 1 to 0xFE, 0xFF = infinity} {Delay between transmissions, 1 to 0xFF, in tenth of seconds}
{(Bit 0: Success)}
{0 = Baracoda, 1 = Baracoda + ACK, 2 = Raw}
{0 = Baracoda, 1 = Baracoda + ACK, 2 = Raw}
{Bit0: Success}
BaracodaPencil 2 – Communication Protocol v1.3 - 7 -
Data Capture
Code ID
0x50
-
0x51
Description
Lock/Unl o c k Sca n e ngine
Payload
1 byte :
Response
1 byte : {Bit 0 : Success}
Code ID
0x52
-
0x53
Description
Disable B a rcode P rogramm i ng F
unc tional i t y
Payload
1 byte :
Response
1 byte : {Bit 0 : Success}
Code ID
0x56
-
0x57
Description
Get/Set I n charge behavior
Payload
Get : None
Response
Get : 1 byte :
Remarks
When scanner in charge, the shutdown timers can be modified
Code I
D 0x5A
-
0x5B
Description
Get/Set m aster m o de
Payload
Get : None
Response
Get : 1 byte :
Cod
e ID 0x5E
-
0x5F
Description
Bluetoot h Comma n ds
Payload
{Code ID} “Parameters”
Response
If the device responds: {Code ID} “Response”
for Workforce
{0 = Unlock, 1 = Lock}
{1 = Disable barcode programming functionality, 0 = Enable}
in Motion
Set : 1 byte :
{shutdown timeout (0 = leave current timeouts (default), 255 = infinity)}
{shutdown timeout (0 = leave current timeouts (default), 255 = infinity)}
Set : 1 byte :
{Bit 0 : Success}
Set : 1-2 byte(s) :
{1 : enable, 0 : disable} [OPTIONAL]{1 : disconnect the scanner if connected}
{1 : enabled 0 : disabled}
Set : 1 byte :
{Bit 0 : Success}
Else: {0} Bluetooth specific commands from the Platform2 Bluetooth communication protocol are to be framed within the payload of this message.
BaracodaPencil 2 – Communication Protocol v1.3 - 8 -
Data Capture
Code ID
0x60
-
0x61
Description
Get Sca n n er Stat u s
Payload
None
Response
2 bytes:
Code ID
0x62
-
0x63
Description
Get Ope r a t ing Mo d e
Payload
None
Response
1 byte:
Remarks
“limited” means barcode buffer = 0 when in real time, no data loss mode and
Code ID
0x64
-
0x65
Description
Set Oper a ting Mo d e
Payload
1 byt
e:
Response
1 byte:
Remarks
Batch mode is not available for D
-
Fly scanner
Code ID
0x66
-
0x67
Description
Get Shut d own Tim e rs
Payload
None
Response
2 bytes:
Code ID
0x68
-
0x69
Description
Set Shut d own Tim e rs
Payload
2 bytes:
for Workforce
2.3.2.
2.3.2. Scanner messages
2.3.2.2.3.2.
Scanner messages
Scanner messagesScanner messages
{(Bit 7: Upgrading) (Bit 1: Docked) (Bit 0: Charging)}
{Battery level, 0 to 100}
{Bit 0 = 0:real time, Bit 0 = 1: batch}
{(Bit 7: limited)}
in Motion
disconnected
{Bit 0 = 0: real time, Bit 0 = 1: batch}
If real time mode is set :
{(Bit 7: limited)(Bit 6: ACK beep) (Bit 5: no ACK beep)}
NOTE : the ACK beep enable / disable is only effective when Capture Frame Format is
“Baracoda + ACK”
{Bit 0: Success}
{Number of minutes before shutdown when connected, 1 to 0xFE,
0xFF = infinity}
{Number of minutes before shutdown when disconnected, 1 to 0xFE,
0xFF = infinity}
{Number of minutes before shutdown when connected, 1 to 0xFE,
0xFF = infinity}
BaracodaPencil 2 – Communication Protocol v1.3 - 9 -
Data Capture
{Number of minutes before shutdown when disconnect
ed, 1 to 0xFE,
Response
1 byte:
Code ID
0x6A
-
0x6B
Description
Get RTC t ime
Payload
None
Response
6 bytes:
Code ID
0x6C
-
0x6D
Description
Set RTC t i me
Payload
6 bytes:
Response
1 byte:
Code ID
0x74
-
0x75
Description
Restore de faults se ttings
Payload
None
Response
1 byte:
Remarks
External Flash memory is also erased
Code ID
0x76
-
0x77
Description
Get Pro d uct Ver si on
Payload
None
Response
x bytes :
Code ID
0x78
-
0x79
Description
Get Swit c hing O n D e lay
Payload
None
Response
1 byte :
Code ID
0x7A
-
0x7B
Description
Set Switc hing On D elay
Payload
1 byte :
Response
1 byte :
for Workforce
0xFF = infinity}
{Bit 0: Success}
{YY}{MM}{DD}{HH}{MM}{SS}
{YY}{MM}{DD}{HH}{MM}{SS}
in Motion
{Bit 0: Success}
{Bit 0: Success}
«BaracodaPencil2…»
{1 = 0 second, 2 = 1 second, 3 = 2 seconds}
{1 = 0 second, 2 = 1 second, 3 = 2 seconds}
{Bit 0 :Success}
BaracodaPencil 2 – Communication Protocol v1.3 - 10 -
Data Capture
Code ID
0x80
-
0x81
Description
Get MMI D e script o r
Payload
None
Response
2 bytes:
Code ID
0x82
-
0x83
Description
Get MMI M ode
Payload
None
Response
1 byte:
Code ID
0x84
-
0x85
Description
Set MMI Mode
Payload
1 by
te:
Response
1 byte: {(Bit 0: Success)}
Code ID
0x86
-
0x87
Description
Get MMI S ignal ( U
ser int e rface)
Payload
1 byte:
Response
(1 + 3n) bytes:
Code ID
0x88
-
0x89
Description
Set MMI S i gnal
Payload
(2 + 3n) bytes
for Workforce
2.3.3.
2.3.3. User Interface messages
2.3.3.2.3.3.
User Interface messages
User Interface messagesUser Interface messages
{(Bit 6: Blue LED 1)
(Bit 5: Red LED 1)
(Bit 4: Green LED 1)
(Bit 2: Blue LED 0)
(Bit 1: Red LED 0)
(Bit 0: Green LED 0)}
{(Bit 0: Buzzer)}
in Motion
{(Bit 1: Buzzer Enabled) (Bit 0: LEDs enabled)}
{(Bit 1: Buzzer Enabled) (Bit 0: LEDs enabled)
(Bit 7 = 0:Buzzer config select, =1: Buzzer config deselect)(Bit 6 = 0:leds config select, =1:
leds config deselect)}
{Signal number, 0 - 3}
{Number of steps, 0 - 4}
For each step:
{(Bit 6: Blue LED 1) (Bit 5: Red LED 1) (Bit 4: Green LED 1) (Bit 2: Blue LED 0) (Bit 1: Red
LED 0) (Bit 0: Green LED 0)}
{Buzzer frequency, 0 – 0xFF * 50Hz = 0 – 12750Hz}
{Delay until next step, in tenth of seconds}
BaracodaPencil 2 – Communication Protocol v1.3 - 11 -
{Signal number, 0 - 3}
{Number of steps, 0 - 4}
Data Capture
For each step:
Response
1 byte: {(Bit 0: Success)}
Code ID
0x8A
-
0x8B
Description
Play
Signal
Payload
2 bytes:
Response
1 byte: {(Bit 0: Success)}
Code ID
0x8C
-
0x8D
Description
Stop Si g n al
Payload
1 byte:
Response
1 byte:
Code ID
0x92
-
0x93
Description
Get Beep s mode
Payload
Response
1 byte:
Code ID
0x94
-
0x95
Description
Set Bee p s m ode
Payload
1 byte:
for Workforce
{(Bit 6: Blue LED 1) (Bit 5: Red LED 1) (Bit 4: Green LED 1) (Bit 2: Blue LED 0) (Bit 1: Red
LED 0) (Bit 0: Green LED 0)}
{Buzzer frequency, 0 – 0xFF * 50Hz = 0 – 12750Hz}
{Delay until next step, in tenth of seconds}
{Signal number, 0 - 3}
{Number of loops, 0 – 0xFE, 0xFF = infinity}
in Motion
{Signal number, 0 – 3}
{(Bit 0: Success)}
The list of MMI signals is: IHM_SIGNAL_CAPTURE_READ : 0 IHM_SIGNAL_CAPTURE_ACK : 1 IHM_SIGNAL_CAPTURE_NAK : 2 IHM_SIGNAL_CAPTURE_LOST : 3
{(Bit 0: Beep level 0=low, 1=high)
(Bit 1: Read beep)
(Bit 2: ACK beep)}
BaracodaPencil 2 – Communication Protocol v1.3 - 12 -
{(Bit 0: Beep level; 0=low, 1=high)
(Bit 1: Read beep)
(Bit 2: ACK beep)
(Bit 7 = 0: ACK beep config select, =1: ACK beep config deselect)
(Bit 6 = 0: Read beep config select, =1: Read beep config deselect)
(Bit 5 = 0: Beep level config select, =1: Beep level config deselect)}}
Response
1 byte:
{(Bit 0: Success)}
Data Capture
for Workforce
in Motion
BaracodaPencil 2 – Communication Protocol v1.3 - 13 -
Loading...
+ 29 hidden pages