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: doc/SimpleWeatherService.md
+9-5
Original file line number
Diff line number
Diff line change
@@ -17,23 +17,25 @@ The host uses this characteristic to update the current weather information and
17
17
18
18
This characteristics accepts a byte array with the following 2-Bytes header:
19
19
20
-
-[0] Message Type :
20
+
-[0] Message Type :
21
21
-`0` : Current weather
22
22
-`1` : Forecast
23
-
-[1] Message Version : Version `0` is currently supported. Other versions might be added in future releases
23
+
-[1] Message Version :
24
+
-`0` : Currently supported
25
+
-`1` : Adds support for sunrise and sunset
24
26
25
-
### Current Weather
27
+
### Current Weather
26
28
27
29
The byte array must contain the following data:
28
30
29
31
-[0] : Message type = `0`
30
-
-[1] : Message version = `0`
32
+
-[1] : Message version = `1`
31
33
-[2][3][4][5][6][7][8][9] : Timestamp (64 bits UNIX timestamp, number of seconds elapsed since 1 JAN 1970) in local time (the same timezone as the one used to set the time)
32
34
-[10, 11] : Current temperature (°C * 100)
33
35
-[12, 13] : Minimum temperature (°C * 100)
34
36
-[14, 15] : Maximum temperature (°C * 100)
35
37
-[16]..[47] : location (string, unused characters should be set to `0`)
36
-
-[48] : icon ID
38
+
-[48] : icon ID
37
39
- 0 = Sun, clear sky
38
40
- 1 = Few clouds
39
41
- 2 = Clouds
@@ -43,6 +45,8 @@ The byte array must contain the following data:
43
45
- 6 = Thunderstorm
44
46
- 7 = Snow
45
47
- 8 = Mist, smog
48
+
-[49, 50] : Sunrise (16 bits, number of minutes elapsed since midnight)
49
+
-[51, 52] : Sunset (16 bits, number of minutes elapsed since midnight)
0 commit comments