Framing Packet - NXP Semiconductors freescale KV4 Series Reference Manual

Table of Contents

Advertisement

Functional Description

14.2.5.3 Framing Packet

The framing packet is used for flow control and error detection, and it (the framing
packet) wraps command and data packets as well.
Byte #
Value
0
0x5A
1
2
3
4
5
6 . . .n
A special framing packet that contains only a start byte and a packet type is used for
synchronization between the host and target.
Byte #
0
1
The Packet Type field specifies the type of the packet from one of the defined types
(below):
packetType
Name
0xA1
kFramingPacketType_Ack
0xA2
kFramingPacketType_Nak
0xA3
kFramingPacketType_AckAbort
0xA4
kFramingPacketType_Command
0xA5
kFramingPacketType_Data
0xA6
kFramingPacketType_Ping
0xA7
kFramingPacketType_PingResponse
CRC16 algorithm:
224
Table 14-4. Framing Packet Format
Parameter
start byte
packetType
length_low
length_high
crc16_low
crc16_high
Command or Data packet
payload
Table 14-5. Special Framing Packet Format
Value
0x5A
0xAn
Table 14-6. packetType Field
KV4x Reference Manual, Rev. 2, 02/2015
Preliminary
Length is a 16-bit field that specifies the entire
command or data packet size in bytes.
This is a 16-bit field. The CRC16 value covers entire
framing packet, including the start byte and command
or data packets, but does not include the CRC bytes.
See the CRC16 algorithm after this table.
Parameter
start byte
packetType
Description
The previous packet was received successfully; the sending
of more packets is allowed.
The previous packet was corrupted and must be re-sent.
Data phase is being aborted.
The framing packet contains a command packet payload.
The framing packet contains a data packet payload.
Sent to verify the other side is alive. Also used for UART
autobaud.
A response to Ping; contains the framing protocol version
number and options.
Freescale Semiconductor, Inc.

Advertisement

Table of Contents
loading

Table of Contents