-
Notifications
You must be signed in to change notification settings - Fork 2
/
ais.h
74 lines (53 loc) · 1.73 KB
/
ais.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
/************************************************************************/
/* */
/* P R O J E K T C A S T O R */
/* */
/* ais.h die Windsensor-Klasse */
/* */
/* Last Change 26.Februar 2009; Patrick Schwizer */
/* */
/************************************************************************/
#ifndef AIS_H
#define AIS_H
#include <DDXStore.h>
#include <DDXVariable.h>
DDX_STORE_TYPE(AisStruct,
struct {
unsigned long mmsi;
unsigned int navigational_status; //0= under way; 1=at anchor;2=not under command; 3=restricted manoeuvrability
double rate_of_turn; //degrees per minute
unsigned int speed_over_ground; //in knots
unsigned int position_accuracy; //1= high (<10m), 0=low (>10m)
double longitude; //east=positive, west=negative
double latitude; //nort=positive, south=negative
double course_over_ground;//in °
double heading; //in ° (external sensor); 511 indicates not available
char destination[21];
double time_of_arrival; //mmddhhmm: month, day, hour, minute
double timestamp;
}
);
DDX_STORE_TYPE(AisData,
struct {
int number_of_ships; //how many ships are in sight?
AisStruct Ship[15];
}
);
DDX_STORE_TYPE(Obstacle,
struct {
double angle;
double dist; // distance from current position to obstacle
double t_crit;
double x; // Position of the obstacle in meters
double y;
}
);
DDX_STORE_TYPE(AisDestData,
struct {
double new_dest_long; // new destination in GPS coordinates
double new_dest_lat;
unsigned int ais_dest_index;
int global_skipper_flag;
}
);
#endif //AIS_H