Host Communication Protocol  2.0
doc/md/2_hcpframe.md
Go to the documentation of this file.
1 HCP frame format {#hcpf}
2 ========
3 
4 The Host Communication Protocol (HCP) describes a general way of sending commands and information
5 between devices.
6 
7 \image html hcp.svg "HCP frame format"
8 \image latex hcp.eps "HCP frame format"
9 
10 \section cmd Command
11 
12 The Commands define the general action that is going to be executed. However, each command
13 can have several Arguments each with data attached.
14 
15 | CMD | Num Args | Payload |
16 | ------- | -------- | -------- |
17 | 2 bytes | 2 bytes | xx bytes |
18 
19 All fields are using unsigned data types.
20 
21 \section arg Argument
22 
23 The Argument is used as a complement to the command if it is needed and can contain arbitrary data.
24 
25 | ARG | Size | Data |
26 | ------- | --------| ---------- |
27 | 2 bytes | 2 bytes | size bytes |
28 
29 All fields are using unsigned data types.