diff options
author | Omar Tarabai <tarabai@devegypt.com> | 2014-08-07 18:24:04 +0000 |
---|---|---|
committer | Omar Tarabai <tarabai@devegypt.com> | 2014-08-07 18:24:04 +0000 |
commit | 605b0e88f6e64ac71a5afb08ce90c909a2807438 (patch) | |
tree | 9b713ebd15b1d3fa68f05ae6d62bebc899448f9a /src/include | |
parent | d6e728b2b869ee521216deae75a767165d3e1001 (diff) | |
download | gnunet-605b0e88f6e64ac71a5afb08ce90c909a2807438.tar.gz gnunet-605b0e88f6e64ac71a5afb08ce90c909a2807438.zip |
sensor: merged reporting module
Diffstat (limited to 'src/include')
-rw-r--r-- | src/include/gnunet_sensor_util_lib.h | 81 |
1 files changed, 40 insertions, 41 deletions
diff --git a/src/include/gnunet_sensor_util_lib.h b/src/include/gnunet_sensor_util_lib.h index 0d205877c..c5d4e6697 100644 --- a/src/include/gnunet_sensor_util_lib.h +++ b/src/include/gnunet_sensor_util_lib.h | |||
@@ -190,46 +190,6 @@ struct GNUNET_SENSOR_SensorInfo | |||
190 | }; | 190 | }; |
191 | 191 | ||
192 | GNUNET_NETWORK_STRUCT_BEGIN | 192 | GNUNET_NETWORK_STRUCT_BEGIN |
193 | /** | ||
194 | * Used to communicate sensor readings to | ||
195 | * collection points (SENSORDASHBAORD service) | ||
196 | */ | ||
197 | struct GNUNET_SENSOR_ReadingMessage | ||
198 | { | ||
199 | |||
200 | /** | ||
201 | * GNUNET general message header | ||
202 | */ | ||
203 | struct GNUNET_MessageHeader header; | ||
204 | |||
205 | /** | ||
206 | * Size of the sensor name value, allocated | ||
207 | * at position 0 after this struct | ||
208 | */ | ||
209 | uint16_t sensorname_size; | ||
210 | |||
211 | /** | ||
212 | * First part of sensor version number | ||
213 | */ | ||
214 | uint16_t sensorversion_major; | ||
215 | |||
216 | /** | ||
217 | * Second part of sensor version number | ||
218 | */ | ||
219 | uint16_t sensorversion_minor; | ||
220 | |||
221 | /** | ||
222 | * Timestamp of recorded reading | ||
223 | */ | ||
224 | uint64_t timestamp; | ||
225 | |||
226 | /** | ||
227 | * Size of reading value, allocation | ||
228 | * at poistion 1 after this struct | ||
229 | */ | ||
230 | uint16_t value_size; | ||
231 | |||
232 | }; | ||
233 | 193 | ||
234 | /** | 194 | /** |
235 | * Used to communicate brief information about a sensor. | 195 | * Used to communicate brief information about a sensor. |
@@ -298,9 +258,48 @@ struct GNUNET_SENSOR_SensorFullMessage | |||
298 | }; | 258 | }; |
299 | 259 | ||
300 | /** | 260 | /** |
261 | * Used to communicate sensor values to | ||
262 | * collection points (SENSORDASHBAORD service) | ||
263 | */ | ||
264 | struct GNUNET_SENSOR_ValueMessage | ||
265 | { | ||
266 | |||
267 | /** | ||
268 | * GNUNET general message header | ||
269 | */ | ||
270 | struct GNUNET_MessageHeader header; | ||
271 | |||
272 | /** | ||
273 | * Hash of sensor name | ||
274 | */ | ||
275 | struct GNUNET_HashCode sensorname_hash; | ||
276 | |||
277 | /** | ||
278 | * First part of sensor version number | ||
279 | */ | ||
280 | uint16_t sensorversion_major; | ||
281 | |||
282 | /** | ||
283 | * Second part of sensor version number | ||
284 | */ | ||
285 | uint16_t sensorversion_minor; | ||
286 | |||
287 | /** | ||
288 | * Timestamp of recorded reading | ||
289 | */ | ||
290 | struct GNUNET_TIME_Absolute timestamp; | ||
291 | |||
292 | /** | ||
293 | * Size of sensor value, allocated at poistion 0 after this struct | ||
294 | */ | ||
295 | uint16_t value_size; | ||
296 | |||
297 | }; | ||
298 | |||
299 | /** | ||
301 | * Message carrying an anomaly status change report | 300 | * Message carrying an anomaly status change report |
302 | */ | 301 | */ |
303 | struct AnomalyReportMessage | 302 | struct GNUNET_SENSOR_AnomalyReportMessage |
304 | { | 303 | { |
305 | 304 | ||
306 | /** | 305 | /** |