Subversion Repositories NaviCtrl

Rev

Rev 278 | Rev 351 | Go to most recent revision | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 278 Rev 280
1
#ifndef __GPS_H
1
#ifndef __GPS_H
2
#define __GPS_H
2
#define __GPS_H
3
 
3
 
4
#include "ubx.h"
4
#include "ubx.h"
5
#include "waypoints.h"
5
#include "waypoints.h"
6
 
6
 
7
typedef struct
7
typedef struct
8
{
8
{
9
        s16 Nick;
9
        s16 Nick;
10
        s16 Roll;
10
        s16 Roll;
11
        s16 Yaw;
11
        s16 Yaw;
12
}  __attribute__((packed)) GPS_Stick_t;
12
}  __attribute__((packed)) GPS_Stick_t;
-
 
13
 
-
 
14
#define CAM_UPDATE_AZIMUTH              0x01
13
 
15
#define CAM_UPDATE_ELEVATION    0x02
14
typedef struct
16
typedef struct
15
{
17
{
16
        s16 Azimuth;            // angle measured clockwise from north
18
        s16 Azimuth;            // angle measured clockwise from north
17
        s16 Elevation;          // angle measured upwards from horizont
19
        s16 Elevation;          // angle measured upwards from horizont
18
        u8 State;                       // NEWDATA, PROCESSED, INVALID
20
        u8 UpdateMask;
19
} __attribute__((packed)) CAM_Orientation_t;
21
} __attribute__((packed)) CAM_Orientation_t;
20
 
22
 
21
extern CAM_Orientation_t CAM_Orientation;
23
extern CAM_Orientation_t CAM_Orientation;
22
extern Waypoint_t* GPS_pWaypoint;
24
extern Point_t* GPS_pWaypoint;
23
 
25
 
24
void GPS_Init(void);
26
void GPS_Init(void);
25
void GPS_Navigation(gps_data_t *pGPS_Data, GPS_Stick_t* pGPS_Stick);
27
void GPS_Navigation(gps_data_t *pGPS_Data, GPS_Stick_t* pGPS_Stick);
26
void CalcHeadFree(void);
28
void CalcHeadFree(void);
27
 
29
 
28
#define EVENTFLAG_1_WP_CHANNEL    1
30
#define EVENTFLAG_1_WP_CHANNEL    1
29
#define EVENTFLAG_2_WP_CHANNEL    2
31
#define EVENTFLAG_2_WP_CHANNEL    2
30
 
32
 
31
#endif //__GPS_H
33
#endif //__GPS_H
32
 
34
 
33
 
35