-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathprotocol.txt
129 lines (98 loc) · 2.59 KB
/
protocol.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
== Message Structure ==
bytes
0 - elementId
1 - ElementLenHeaderSize = 4
2 - elem length - MSB
3 - elem length
4 - elem length
5 - elem length - LSB
6 ... n - payload
All numbers seem to be big-endian
== Protocol ==
Server LiveView
<- MSG
ACK(44) ->
RESPONSE ->
== Time And Date Request (38) ==
The LiveView device will issue a Time And Date Request if it
doesn't have the current time set.
response Id - 39
payload -
byte 0-3 - time in seconds since the Epoch + zone offset + DST offset
byte 4 - is a 24-hour clock - 1 or 0
== Screen State (7) ==
packet id - 07
payload -
byte 0
0x0 - screen off
0x1 - screen on
0x2 - right button while screen on
== Navigation Request (29) ==
request id - 29
payload -
byte 0 - 0x0
byte 1 - 0x3
byte 2 - navigation
13,14,15 - select, select long, select double
1,2,3 - up, up long, up double
4,5,6 - down, down long, down double
7,8,9 - left, left long, left double
10,11,12 - right, right long, right double
16 - 31 - ignore
32 - open in phone
0 - invalid
byte 3 - position X
byte 4 - position Y
response id - 30
payload
byte 0
0x0 - ok
0x1 - error (actually means Unknown, but assuming as error is also correct)
0x2 - no memory
0x3 - ok exit
0x4 - ok cancel
== LED Request (40) ==
request id - 40
payload
byte 0-1: color in RGB565
byte 2-3: delay time in ms
byte 4-5: "on" time in ms
response id - 41
payload
byte 0 - 0x0
== Vibrate Request (42) ==
request id - 42
payload
byte 0-1: delay time in ms
byte 2-3: "on" time in ms
response id - 43
payload
byte 0 - 0x0
== SW Version Request (68) ==
request id - 68
response id - 69
payload: WILL BE LIKE "0.0.3".getBytes("iso-8859-1")
== Clear Display Request (21) ==
Not sure how this works - doesn't seem to work in the normal mode
request id - 21
no payload
response id - 22
== Display Properties Request (1) ==
request id - 1
payload
byte 0-end - null-terminated version string, e.g., '0.0.3\0'
response id - 2
payload
byte 0 - width
byte 1 - height
byte 2 - status bar width
byte 3 - status bar height
byte 4 - view width
byte 5 - view height
byte 6 - announce width
byte 7 - announce height
byte 8 - text chunk size
byte 9 - idle timer
byte 10 - stop byte?
byte 11-15 - sw version
// vim: set expandtab ts=2 sw=2