You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: protocol.md
+85-3Lines changed: 85 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,6 +5,7 @@
5
5
Global firmware+CLI versions are following the [semantic versioning](https://semver.org/) logic mostly regarding the protocol version, so third party clients (GUIs, mobile apps, SDKs) can rely on firmware version to know their level of compatibility.
6
6
7
7
Given a version number MAJOR.MINOR.PATCH, we will increment the:
8
+
8
9
* MAJOR version when we are breaking the existing protocol format
9
10
* MINOR version when we are extending the protocol format in a backward compatible manner (new commands,...)
10
11
* PATCH version when we are releasing bugfixes not affecting the protocol description
@@ -18,15 +19,29 @@ For the development channel, a client compatible with versions X.y.z can accept
18
19
Cf [GET_APP_VERSION](#1000-get_app_version) and [GET_GIT_VERSION](#1017-get_git_version).
19
20
20
21
When `GET_GIT_VERSION` returns only a tag and no commit hash info (on a release tag), one can query the corresponding hash with the GitHub API, e.g.
22
+
21
23
```
22
24
"4747d3884d21e0df8549e3029a920ea390e0b00a"
23
25
```
26
+
24
27
## Frame format
25
28
26
29
The communication between the firmware and the client is made of frames structured as follows:
27
30
28
31

29
32
33
+
```mermaid
34
+
packet
35
+
+8: "SOF"
36
+
+8: "LRC1"
37
+
+16: "CMD"
38
+
+16: "STATUS"
39
+
+16: "LEN"
40
+
+8: "LRC2"
41
+
+48: "DATA (variable length)"
42
+
+8: "LRC3"
43
+
```
44
+
30
45
-**SOF**: `1 byte`, "**S**tart-**O**f-**F**rame byte" represents the start of a packet, and must be equal to `0x11`.
31
46
-**LRC1**: `1 byte`, LRC over `SOF` byte, therefore must be equal to `0xEF`.
32
47
-**CMD**: `2 bytes`, each command have been assigned a unique number (e.g. `DATA_CMD_SET_SLOT_TAG_NICK` = `1007`).
@@ -58,13 +73,80 @@ Beware, slots in protocol count from 0 to 7 (and from 1 to 8 in the CLI...).
58
73
In the following list, "CLI" refers to one typical CLI command using the described protocol command. But it's not a 1:1 match, there can be other protocol commands used by the CLI command and there can be other CLI commands using the same protocol command...
0 commit comments