-
Notifications
You must be signed in to change notification settings - Fork 25
/
readsb.pb-c.h
881 lines (844 loc) · 25.2 KB
/
readsb.pb-c.h
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
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
/* Generated by the protocol buffer compiler. DO NOT EDIT! */
/* Generated from: readsb.proto */
#ifndef PROTOBUF_C_readsb_2eproto__INCLUDED
#define PROTOBUF_C_readsb_2eproto__INCLUDED
#include <protobuf-c/protobuf-c.h>
PROTOBUF_C__BEGIN_DECLS
#if PROTOBUF_C_VERSION_NUMBER < 1003000
# error This file was generated by a newer version of protoc-c which is incompatible with your libprotobuf-c headers. Please update your headers.
#elif 1003003 < PROTOBUF_C_MIN_COMPILER_VERSION
# error This file was generated by an older version of protoc-c which is incompatible with your libprotobuf-c headers. Please regenerate this file with a newer version of protoc-c.
#endif
typedef struct _AircraftMeta AircraftMeta;
typedef struct _AircraftMeta__NavModes AircraftMeta__NavModes;
typedef struct _AircraftMeta__ValidSource AircraftMeta__ValidSource;
typedef struct _AircraftHistory AircraftHistory;
typedef struct _AircraftsUpdate AircraftsUpdate;
typedef struct _Receiver Receiver;
typedef struct _StatisticEntry StatisticEntry;
typedef struct _Statistics Statistics;
typedef struct _Statistics__PolarRangeEntry Statistics__PolarRangeEntry;
/* --- enums --- */
typedef enum _AircraftMeta__AirGround {
AIRCRAFT_META__AIR_GROUND__AG_INVALID = 0,
AIRCRAFT_META__AIR_GROUND__AG_GROUND = 1,
AIRCRAFT_META__AIR_GROUND__AG_AIRBORNE = 2,
AIRCRAFT_META__AIR_GROUND__AG_UNCERTAIN = 3
PROTOBUF_C__FORCE_ENUM_TO_BE_INT_SIZE(AIRCRAFT_META__AIR_GROUND)
} AircraftMeta__AirGround;
/*
* Type of underlying message, one of:
*/
typedef enum _AircraftMeta__AddrType {
/*
* Mode S or ADS-B, ICAO address, transponder sourced.
*/
AIRCRAFT_META__ADDR_TYPE__ADDR_ADSB_ICAO = 0,
/*
* ADS-B, ICAO address, non-transponder.
*/
AIRCRAFT_META__ADDR_TYPE__ADDR_ADSB_ICAO_NT = 1,
/*
* ADS-R, ICAO address.
*/
AIRCRAFT_META__ADDR_TYPE__ADDR_ADSR_ICAO = 2,
/*
* TIS-B, ICAO address.
*/
AIRCRAFT_META__ADDR_TYPE__ADDR_TISB_ICAO = 3,
/*
* ADS-B, other address format.
*/
AIRCRAFT_META__ADDR_TYPE__ADDR_ADSB_OTHER = 4,
/*
* ADS-R, other address format.
*/
AIRCRAFT_META__ADDR_TYPE__ADDR_ADSR_OTHER = 5,
/*
* TIS-B, Mode A code + track file number.
*/
AIRCRAFT_META__ADDR_TYPE__ADDR_TISB_TRACKFILE = 6,
/*
* TIS-B, other address format.
*/
AIRCRAFT_META__ADDR_TYPE__ADDR_TISB_OTHER = 7,
/*
* Mode A.
*/
AIRCRAFT_META__ADDR_TYPE__ADDR_MODE_A = 8,
/*
* Unknown address format.
*/
AIRCRAFT_META__ADDR_TYPE__ADDR_UNKNOWN = 9
PROTOBUF_C__FORCE_ENUM_TO_BE_INT_SIZE(AIRCRAFT_META__ADDR_TYPE)
} AircraftMeta__AddrType;
/*
* ADS-B emergency/priority status, a superset of the 7x00 squawks
*/
typedef enum _AircraftMeta__Emergency {
AIRCRAFT_META__EMERGENCY__EMERGENCY_NONE = 0,
AIRCRAFT_META__EMERGENCY__EMERGENCY_GENERAL = 1,
AIRCRAFT_META__EMERGENCY__EMERGENCY_LIFEGUARD = 2,
AIRCRAFT_META__EMERGENCY__EMERGENCY_MINFUEL = 3,
AIRCRAFT_META__EMERGENCY__EMERGENCY_NORDO = 4,
AIRCRAFT_META__EMERGENCY__EMERGENCY_UNLAWFUL = 5,
AIRCRAFT_META__EMERGENCY__EMERGENCY_DOWNED = 6,
AIRCRAFT_META__EMERGENCY__EMERGENCY_RESERVED = 7
PROTOBUF_C__FORCE_ENUM_TO_BE_INT_SIZE(AIRCRAFT_META__EMERGENCY)
} AircraftMeta__Emergency;
/*
* Interpretation of SIL: unknown, perhour, persample.
*/
typedef enum _AircraftMeta__SilType {
AIRCRAFT_META__SIL_TYPE__SIL_INVALID = 0,
AIRCRAFT_META__SIL_TYPE__SIL_UNKNOWN = 1,
AIRCRAFT_META__SIL_TYPE__SIL_PER_SAMPLE = 2,
AIRCRAFT_META__SIL_TYPE__SIL_PER_HOUR = 3
PROTOBUF_C__FORCE_ENUM_TO_BE_INT_SIZE(AIRCRAFT_META__SIL_TYPE)
} AircraftMeta__SilType;
/* --- messages --- */
/*
* Set of engaged automation modes.
*/
struct _AircraftMeta__NavModes
{
ProtobufCMessage base;
protobuf_c_boolean autopilot;
protobuf_c_boolean vnav;
protobuf_c_boolean althold;
protobuf_c_boolean approach;
protobuf_c_boolean lnav;
protobuf_c_boolean tcas;
};
#define AIRCRAFT_META__NAV_MODES__INIT \
{ PROTOBUF_C_MESSAGE_INIT (&aircraft_meta__nav_modes__descriptor) \
, 0, 0, 0, 0, 0, 0 }
/*
* List of valid source fields for each parameter.
*/
struct _AircraftMeta__ValidSource
{
ProtobufCMessage base;
uint32_t callsign;
uint32_t altitude;
uint32_t alt_geom;
uint32_t gs;
uint32_t ias;
uint32_t tas;
uint32_t mach;
uint32_t track;
uint32_t track_rate;
uint32_t roll;
uint32_t mag_heading;
uint32_t true_heading;
uint32_t baro_rate;
uint32_t geom_rate;
uint32_t squawk;
uint32_t emergency;
uint32_t nav_qnh;
uint32_t nav_altitude_mcp;
uint32_t nav_altitude_fms;
uint32_t nav_heading;
uint32_t nav_modes;
uint32_t lat;
uint32_t lon;
uint32_t nic;
uint32_t rc;
uint32_t nic_baro;
uint32_t nac_p;
uint32_t nac_v;
uint32_t sil;
uint32_t sil_type;
uint32_t gva;
uint32_t sda;
uint32_t wind;
};
#define AIRCRAFT_META__VALID_SOURCE__INIT \
{ PROTOBUF_C_MESSAGE_INIT (&aircraft_meta__valid_source__descriptor) \
, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }
/*
**
* Readsb single tracked aircraft meta data.
*/
struct _AircraftMeta
{
ProtobufCMessage base;
/*
* The 24-bit ICAO identifier of the aircraft, as 6 hex digits. The identifier may start with '~', this means that the address is a non-ICAO address (e.g. from TIS-B).
*/
uint32_t addr;
/*
* Callsign, the flight name or aircraft registration as 8 chars.
*/
char *flight;
/*
* Mode A code (Squawk), encoded as 4 octal digits.
*/
uint32_t squawk;
/*
* Emitter category to identify particular aircraft or vehicle classes (values A0 - D7).
*/
uint32_t category;
/*
* The aircraft barometric altitude in feet.
*/
int32_t alt_baro;
/*
* Heading, degrees clockwise from magnetic north.
*/
int32_t mag_heading;
/*
* Indicated air speed in knots.
*/
uint32_t ias;
/*
* Aircraft position latitude in decimal degrees.
*/
double lat;
/*
* Aircraft position longitude in decimal degrees.
*/
double lon;
/*
* Total number of Mode S messages received from this aircraft.
*/
uint64_t messages;
/*
* When a message was last received from this aircraft. (in milliseconds!!!)
*/
uint64_t seen;
/*
* Recent average RSSI (signal power), in dbFS; this will always be negative.
*/
float rssi;
/*
* Distance to site in meter.
*/
uint32_t distance;
AircraftMeta__AirGround air_ground;
/*
* Geometric (GNSS / INS) altitude in feet referenced to the WGS84 ellipsoid.
*/
int32_t alt_geom;
/*
* Rate of change of barometric altitude, feet/minute.
*/
int32_t baro_rate;
/*
* Rate of change of geometric (GNSS / INS) altitude. feet/minute
*/
int32_t geom_rate;
/*
* Ground speed in knots.
*/
uint32_t gs;
/*
* True air speed in knots.
*/
uint32_t tas;
/*
* Mach number.
*/
float mach;
/*
* Heading, degrees clockwise from true north.
*/
int32_t true_heading;
/*
* True track over ground in degrees (0-359).
*/
int32_t track;
/*
* Rate of change of track, degrees/second.
*/
float track_rate;
/*
* Roll, degrees, negative is left roll.
*/
float roll;
/*
* Navigation Accuracy for Velocity.
*/
float nav_qnh;
/*
* Selected altitude from the Mode Control Panel / Flight Control Unit (MCP/FCU) or equivalent equipment.
*/
int32_t nav_altitude_mcp;
/*
* Selected altitude from the Flight Management System (FMS).
*/
int32_t nav_altitude_fms;
/*
* Selected heading (True or Magnetic is not defined in DO-260B, mostly Magnetic as that is the de facto standard).
*/
int32_t nav_heading;
/*
* Navigation Integrity Category.
*/
uint32_t nic;
/*
* Radius of Containment, meters; a measure of position integrity derived from NIC & supplementary bits.
*/
uint32_t rc;
/*
* ADS-B Version Number 0, 1, 2 (3-7 are reserved)
*/
int32_t version;
/*
* Navigation Integrity Category for Barometric Altitude
*/
uint32_t nic_baro;
/*
* Navigation Accuracy for Position
*/
uint32_t nac_p;
/*
* Navigation Accuracy for Velocity
*/
uint32_t nac_v;
/*
* Source Integity Level
*/
uint32_t sil;
/*
* How long ago (in seconds before "now") the position was last updated.
*/
uint32_t seen_pos;
/*
* Flight status alert bit.
*/
protobuf_c_boolean alert;
/*
* Flight status special position identification bit.
*/
protobuf_c_boolean spi;
/*
* Geometric Vertical Accuracy
*/
uint32_t gva;
/*
* System Design Assurance
*/
uint32_t sda;
/*
* Geomagnetic declination depending on position
*/
double declination;
/*
* Calculated wind speed
*/
uint32_t wind_speed;
/*
* Calculated wind direction
*/
uint32_t wind_direction;
AircraftMeta__AddrType addr_type;
AircraftMeta__Emergency emergency;
AircraftMeta__SilType sil_type;
AircraftMeta__NavModes *nav_modes;
AircraftMeta__ValidSource *valid_source;
};
#define AIRCRAFT_META__INIT \
{ PROTOBUF_C_MESSAGE_INIT (&aircraft_meta__descriptor) \
, 0, (char *)protobuf_c_empty_string, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, AIRCRAFT_META__AIR_GROUND__AG_INVALID, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, AIRCRAFT_META__ADDR_TYPE__ADDR_ADSB_ICAO, AIRCRAFT_META__EMERGENCY__EMERGENCY_NONE, AIRCRAFT_META__SIL_TYPE__SIL_INVALID, NULL, NULL }
struct _AircraftHistory
{
ProtobufCMessage base;
/*
* The 24-bit ICAO identifier of the aircraft, as 6 hex digits.
*/
uint32_t addr;
/*
* The aircraft barometric altitude in feet.
*/
int32_t alt_baro;
/*
* Aircraft position latitude in decimal degrees.
*/
double lat;
/*
* Aircraft position longitude in decimal degrees.
*/
double lon;
};
#define AIRCRAFT_HISTORY__INIT \
{ PROTOBUF_C_MESSAGE_INIT (&aircraft_history__descriptor) \
, 0, 0, 0, 0 }
/*
**
* Collection of tracked aircrafts.
*/
struct _AircraftsUpdate
{
ProtobufCMessage base;
/*
* The time this file was generated, in seconds since Unix epoch.
*/
uint64_t now;
/*
* The total number of Mode S messages processed since readsb started.
*/
uint64_t messages;
/*
* Aircraft position history collection.
*/
size_t n_history;
AircraftHistory **history;
/*
* The aircraft collection.
*/
size_t n_aircraft;
AircraftMeta **aircraft;
};
#define AIRCRAFTS_UPDATE__INIT \
{ PROTOBUF_C_MESSAGE_INIT (&aircrafts_update__descriptor) \
, 0, 0, 0,NULL, 0,NULL }
/*
**
* Readsb receiver details.
*/
struct _Receiver
{
ProtobufCMessage base;
/*
* Readsb version
*/
char *version;
/*
* Data refresh period.
*/
float refresh;
/*
* Receiver location latitude.
*/
double latitude;
/*
* Receiver location longitude.
*/
double longitude;
/*
* Receiver altitude.
*/
uint32_t altitude;
/*
* Antenna serial number.
*/
uint32_t antenna_serial;
/*
* Antenna status flags.
*/
uint32_t antenna_flags;
/*
* Antenna GPS satellites used in fix.
*/
uint32_t antenna_gps_sats;
/*
* Antenna GPS HDOP*10, thus 12 is HDOP 1.2.
*/
uint32_t antenna_gps_hdop;
/*
* Antenna internal use.
*/
uint32_t antenna_reserved;
/*
* Aircraft history size.
*/
uint32_t history;
};
#define RECEIVER__INIT \
{ PROTOBUF_C_MESSAGE_INIT (&receiver__descriptor) \
, (char *)protobuf_c_empty_string, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }
/*
**
* Single statistcs entry.
*/
struct _StatisticEntry
{
ProtobufCMessage base;
/*
* the start time (in seconds-since-1-Jan-1970) of this statistics collection period.
*/
uint64_t start;
/*
* the end time (in seconds-since-1-Jan-1970) of this statistics collection period.
*/
uint64_t stop;
/*
* total number of messages accepted by readsb from any source
*/
uint64_t messages;
uint32_t max_distance_in_metres;
uint32_t max_distance_in_nautical_miles;
uint64_t altitude_suppressed;
/*
* total tracks (aircrafts) created. Each track represents a unique aircraft and persists for up to 5 minutes.
*/
uint64_t tracks_new;
/*
* tracks consisting of only a single message. These are usually due to message decoding errors that produce a bad aircraft address.
*/
uint64_t tracks_single_message;
uint64_t tracks_with_position;
uint64_t tracks_mlat_position;
uint64_t tracks_tisb_position;
/*
* statistics about CPU use
*/
/*
* milliseconds spent doing demodulation and decoding in response to data from a SDR dongle
*/
uint64_t cpu_demod;
/*
* milliseconds spent reading sample data over USB from a SDR dongle
*/
uint64_t cpu_reader;
/*
* milliseconds spent doing network I/O, processing received network messages, and periodic tasks.
*/
uint64_t cpu_background;
/*
* statistics about Compact Position Report message decoding.
*/
/*
* total number of surface CPR messages received
*/
uint64_t cpr_surface;
/*
* total number of airborne CPR messages received
*/
uint64_t cpr_airborne;
/*
* global positions successfuly derived
*/
uint64_t cpr_global_ok;
/*
* global positions that were rejected because they were inconsistent
*/
uint64_t cpr_global_bad;
/*
* global positions that were rejected because they exceeded the receiver max range
*/
uint64_t cpr_global_range;
/*
* global positions that were rejected because they failed the inter-position speed check
*/
uint64_t cpr_global_speed;
/*
* global position attempts skipped because we did not have the right data (e.g. even/odd messages crossed a zone boundary)
*/
uint64_t cpr_global_skipped;
/*
* local (relative) positions successfully found
*/
uint64_t cpr_local_ok;
/*
* local positions found relative to a previous aircraft position
*/
uint64_t cpr_local_aircraft_relative;
/*
* local positions found relative to the receiver position
*/
uint64_t cpr_local_receiver_relative;
/*
* local (relative) positions not used because we did not have the right data
*/
uint64_t cpr_local_skipped;
/*
* local positions not used because they exceeded the receiver max range or fell into the ambiguous part of the receiver range
*/
uint64_t cpr_local_range;
/*
* local positions not used because they failed the inter-position speed check
*/
uint64_t cpr_local_speed;
/*
* number of CPR messages ignored because they matched one of the heuristics for faulty transponder output
*/
uint64_t cpr_filtered;
/*
* statistics about messages received from remote clients. Only present in --net or --net-only mode.
*/
/*
* number of Mode A / C messages received.
*/
uint64_t remote_modeac;
/*
* number of Mode S messages received.
*/
uint64_t remote_modes;
/*
* number of Mode S messages that had bad CRC or were otherwise invalid.
*/
uint64_t remote_bad;
/*
* number of Mode S messages which looked like they might be valid but we didn't recognize the ICAO address and it was one of the message types where we can't be sure it's valid in this case.
*/
uint64_t remote_unknown_icao;
/*
* number of valid Mode S messages accepted with N-bit errors corrected.
*/
uint64_t remote_accepted;
/*
* statistics about messages received from a local SDR dongle. Not present in --net-only mode.
*/
/*
* number of sample blocks processed
*/
uint64_t local_samples_processed;
/*
* number of sample blocks dropped before processing. A nonzero value means CPU overload.
*/
uint64_t local_samples_dropped;
/*
* number of Mode A / C messages decoded
*/
uint64_t local_modeac;
/*
* number of Mode S preambles received. This is *not* the number of valid messages!
*/
uint64_t local_modes;
/*
* number of Mode S preambles that didn't result in a valid message
*/
uint64_t local_bad;
/*
* number of Mode S preambles which looked like they might be valid but we didn't recognize the ICAO address and it was one of the message types where we can't be sure it's valid in this case.
*/
uint64_t local_unknown_icao;
/*
* number of messages received that had a signal power above -3dBFS.
*/
uint64_t local_strong_signals;
/*
* mean signal power of successfully received messages, in dbFS; always negative.
*/
float local_signal;
/*
* calculated receiver noise floor level.
*/
float local_noise;
/*
* peak signal power of a successfully received message, in dbFS; always negative.
*/
float local_peak_signal;
/*
* the number of valid Mode S messages accepted with N-bit errors corrected.
*/
uint64_t local_accepted;
};
#define STATISTIC_ENTRY__INIT \
{ PROTOBUF_C_MESSAGE_INIT (&statistic_entry__descriptor) \
, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }
struct _Statistics__PolarRangeEntry
{
ProtobufCMessage base;
uint32_t key;
uint32_t value;
};
#define STATISTICS__POLAR_RANGE_ENTRY__INIT \
{ PROTOBUF_C_MESSAGE_INIT (&statistics__polar_range_entry__descriptor) \
, 0, 0 }
/*
**
* Readsb receiver statistics.
*/
struct _Statistics
{
ProtobufCMessage base;
/*
* covers the time between the end of the "last1min" period and the current time.
*/
StatisticEntry *latest;
/*
* covers a recent 15-minute period. As above, this may be up to 1 minute out of date.
*/
StatisticEntry *last_1min;
/*
* covers a recent 5-minute period. As above, this may be up to 1 minute out of date.
*/
StatisticEntry *last_5min;
/*
* covers a recent 1-minute period. This may be up to 1 minute out of date (i.e. "end" may be up to 1 minute old).
*/
StatisticEntry *last_15min;
/*
* covers the entire period from when readsb was started up to the current time
*/
StatisticEntry *total;
/*
* maximum range per bearing, 0 to 359 degree, default resolution 5 degree.
*/
size_t n_polar_range;
Statistics__PolarRangeEntry **polar_range;
};
#define STATISTICS__INIT \
{ PROTOBUF_C_MESSAGE_INIT (&statistics__descriptor) \
, NULL, NULL, NULL, NULL, NULL, 0,NULL }
/* AircraftMeta__NavModes methods */
void aircraft_meta__nav_modes__init
(AircraftMeta__NavModes *message);
/* AircraftMeta__ValidSource methods */
void aircraft_meta__valid_source__init
(AircraftMeta__ValidSource *message);
/* AircraftMeta methods */
void aircraft_meta__init
(AircraftMeta *message);
size_t aircraft_meta__get_packed_size
(const AircraftMeta *message);
size_t aircraft_meta__pack
(const AircraftMeta *message,
uint8_t *out);
size_t aircraft_meta__pack_to_buffer
(const AircraftMeta *message,
ProtobufCBuffer *buffer);
AircraftMeta *
aircraft_meta__unpack
(ProtobufCAllocator *allocator,
size_t len,
const uint8_t *data);
void aircraft_meta__free_unpacked
(AircraftMeta *message,
ProtobufCAllocator *allocator);
/* AircraftHistory methods */
void aircraft_history__init
(AircraftHistory *message);
size_t aircraft_history__get_packed_size
(const AircraftHistory *message);
size_t aircraft_history__pack
(const AircraftHistory *message,
uint8_t *out);
size_t aircraft_history__pack_to_buffer
(const AircraftHistory *message,
ProtobufCBuffer *buffer);
AircraftHistory *
aircraft_history__unpack
(ProtobufCAllocator *allocator,
size_t len,
const uint8_t *data);
void aircraft_history__free_unpacked
(AircraftHistory *message,
ProtobufCAllocator *allocator);
/* AircraftsUpdate methods */
void aircrafts_update__init
(AircraftsUpdate *message);
size_t aircrafts_update__get_packed_size
(const AircraftsUpdate *message);
size_t aircrafts_update__pack
(const AircraftsUpdate *message,
uint8_t *out);
size_t aircrafts_update__pack_to_buffer
(const AircraftsUpdate *message,
ProtobufCBuffer *buffer);
AircraftsUpdate *
aircrafts_update__unpack
(ProtobufCAllocator *allocator,
size_t len,
const uint8_t *data);
void aircrafts_update__free_unpacked
(AircraftsUpdate *message,
ProtobufCAllocator *allocator);
/* Receiver methods */
void receiver__init
(Receiver *message);
size_t receiver__get_packed_size
(const Receiver *message);
size_t receiver__pack
(const Receiver *message,
uint8_t *out);
size_t receiver__pack_to_buffer
(const Receiver *message,
ProtobufCBuffer *buffer);
Receiver *
receiver__unpack
(ProtobufCAllocator *allocator,
size_t len,
const uint8_t *data);
void receiver__free_unpacked
(Receiver *message,
ProtobufCAllocator *allocator);
/* StatisticEntry methods */
void statistic_entry__init
(StatisticEntry *message);
size_t statistic_entry__get_packed_size
(const StatisticEntry *message);
size_t statistic_entry__pack
(const StatisticEntry *message,
uint8_t *out);
size_t statistic_entry__pack_to_buffer
(const StatisticEntry *message,
ProtobufCBuffer *buffer);
StatisticEntry *
statistic_entry__unpack
(ProtobufCAllocator *allocator,
size_t len,
const uint8_t *data);
void statistic_entry__free_unpacked
(StatisticEntry *message,
ProtobufCAllocator *allocator);
/* Statistics__PolarRangeEntry methods */
void statistics__polar_range_entry__init
(Statistics__PolarRangeEntry *message);
/* Statistics methods */
void statistics__init
(Statistics *message);
size_t statistics__get_packed_size
(const Statistics *message);
size_t statistics__pack
(const Statistics *message,
uint8_t *out);
size_t statistics__pack_to_buffer
(const Statistics *message,
ProtobufCBuffer *buffer);
Statistics *
statistics__unpack
(ProtobufCAllocator *allocator,
size_t len,
const uint8_t *data);
void statistics__free_unpacked
(Statistics *message,
ProtobufCAllocator *allocator);
/* --- per-message closures --- */
typedef void (*AircraftMeta__NavModes_Closure)
(const AircraftMeta__NavModes *message,
void *closure_data);
typedef void (*AircraftMeta__ValidSource_Closure)
(const AircraftMeta__ValidSource *message,
void *closure_data);
typedef void (*AircraftMeta_Closure)
(const AircraftMeta *message,
void *closure_data);
typedef void (*AircraftHistory_Closure)
(const AircraftHistory *message,
void *closure_data);
typedef void (*AircraftsUpdate_Closure)
(const AircraftsUpdate *message,
void *closure_data);
typedef void (*Receiver_Closure)
(const Receiver *message,
void *closure_data);
typedef void (*StatisticEntry_Closure)
(const StatisticEntry *message,
void *closure_data);
typedef void (*Statistics__PolarRangeEntry_Closure)
(const Statistics__PolarRangeEntry *message,
void *closure_data);
typedef void (*Statistics_Closure)
(const Statistics *message,
void *closure_data);
/* --- services --- */
/* --- descriptors --- */
extern const ProtobufCMessageDescriptor aircraft_meta__descriptor;
extern const ProtobufCMessageDescriptor aircraft_meta__nav_modes__descriptor;
extern const ProtobufCMessageDescriptor aircraft_meta__valid_source__descriptor;
extern const ProtobufCEnumDescriptor aircraft_meta__air_ground__descriptor;
extern const ProtobufCEnumDescriptor aircraft_meta__addr_type__descriptor;
extern const ProtobufCEnumDescriptor aircraft_meta__emergency__descriptor;
extern const ProtobufCEnumDescriptor aircraft_meta__sil_type__descriptor;
extern const ProtobufCMessageDescriptor aircraft_history__descriptor;
extern const ProtobufCMessageDescriptor aircrafts_update__descriptor;
extern const ProtobufCMessageDescriptor receiver__descriptor;
extern const ProtobufCMessageDescriptor statistic_entry__descriptor;
extern const ProtobufCMessageDescriptor statistics__descriptor;
extern const ProtobufCMessageDescriptor statistics__polar_range_entry__descriptor;
PROTOBUF_C__END_DECLS
#endif /* PROTOBUF_C_readsb_2eproto__INCLUDED */