Datasheet
AR1100 RESISTIVE USB AND RS-232 TOUCH SCREEN CONTROLLER
DS41606B-page 18 2011 Microchip Technology Inc.
4.2.2.1 Construction
GENERAL
The generic framework for all packets (Figure 4-1) is
comprised of a SYNC byte, a SIZE byte and a DATA
section. The DATA section has a maximum size of 255
total bytes.
FIGURE 4-1: PACKET FORMAT –
GENERAL
COMMAND
A COMMAND packet has a minimum of 3 bytes
defined as SYNC, SIZE and CMND. The DATA section
is command-dependant and can include up to 254
associated data bytes (D[1] – D[N]). See Figure 4-2.
FIGURE 4-2: PACKET FORMAT – COMMAND
RESPONSE
A RESPONSE packet has a minimum of 4 bytes
defined as SYNC, SIZE, STATUS and CMND. As with
the COMMAND packet, the RESPONSE packet is
command-dependant and can include up to 253 asso-
ciated data bytes. In cases where the RESPONSE
packet is in direct response to a COMMAND packet,
the CMND byte is the same in both.
FIGURE 4-3: PACKET FORMAT – RESPONSE
4.2.2.2 Mode: UART
In UART communication mode a complete COMMAND
packet must be delivered before the packet ‘time-out’
timer expires (~250 ms). A packet ‘time out’ will cause
any partial packet to be discarded and the packet pars-
ing state controller to reset. Using this mechanism, the
host can always ensure (re-establish) ‘SYNC’ by paus-
ing for 250+ ms before sending another packet.
4.2.2.3 Mode: USB
Typically, a packet arrives (and is delivered) in a single,
64-byte (max.) USB buffer. Theoretically, a COMMAND
packet can span multiple, physical USB buffers but will
be subject to the packet time-out criteria described in
the UART section. A RESPONSE packet will always be
delivered in a single buffer and a buffer will never
contain more than one.
SYNC SIZE
DATA
0x55 N
D[1]
D[N]
SYNC SIZE
DATA
0x55
N+1
CMND
D[1]
D[N]
SYNC SIZE
DATA
0x55
N+2
STATUS
CMND
D[N]D[1]