Firmware SDK
|
Driver for u-blox SAM-M8Q GPS/Galileo/Glonass navigation module. More...
Data Structures | |
struct | twr_sam_m8q_driver_t |
SAM-M8Q driver. More... | |
struct | twr_sam_m8q_time_t |
Time data structure. More... | |
struct | twr_sam_m8q_position_t |
Position data structure. More... | |
struct | twr_sam_m8q_altitude_t |
Altitude data structure. More... | |
struct | twr_sam_m8q_quality_t |
Quality data structure. More... | |
struct | twr_sam_m8q_accuracy_t |
Accuracy data structure. More... | |
Typedefs | |
typedef struct twr_sam_m8q_t | twr_sam_m8q_t |
SAM-M8Q instance. | |
Enumerations | |
enum | twr_sam_m8q_event_t { TWR_SAM_M8Q_EVENT_ERROR = 0 , TWR_SAM_M8Q_EVENT_START = 1 , TWR_SAM_M8Q_EVENT_UPDATE = 2 , TWR_SAM_M8Q_EVENT_STOP = 3 } |
Callback events. More... | |
Variables | |
bool(* | twr_sam_m8q_driver_t::on )(twr_sam_m8q_t *self) |
Callback for power on. | |
bool(* | twr_sam_m8q_driver_t::off )(twr_sam_m8q_t *self) |
Callback for power off. | |
int | twr_sam_m8q_time_t::year |
Year. | |
int | twr_sam_m8q_time_t::month |
Month. | |
int | twr_sam_m8q_time_t::day |
Day. | |
int | twr_sam_m8q_time_t::hours |
Hours. | |
int | twr_sam_m8q_time_t::minutes |
Minutes. | |
int | twr_sam_m8q_time_t::seconds |
Seconds. | |
float | twr_sam_m8q_position_t::latitude |
Latitude. | |
float | twr_sam_m8q_position_t::longitude |
Longitude. | |
float | twr_sam_m8q_altitude_t::altitude |
Altitude. | |
char | twr_sam_m8q_altitude_t::units |
Units of altitude. | |
int | twr_sam_m8q_quality_t::fix_quality |
Fix quality. | |
int | twr_sam_m8q_quality_t::satellites_tracked |
Number of satellites tracked. | |
float | twr_sam_m8q_accuracy_t::horizontal |
Horizontal accuracy estimate. | |
float | twr_sam_m8q_accuracy_t::vertical |
Vertical accuracy estimate. | |
Driver for u-blox SAM-M8Q GPS/Galileo/Glonass navigation module.
enum twr_sam_m8q_event_t |
Callback events.
Enumerator | |
---|---|
TWR_SAM_M8Q_EVENT_ERROR | Error event. |
TWR_SAM_M8Q_EVENT_START | Start event. |
TWR_SAM_M8Q_EVENT_UPDATE | Update event. |
TWR_SAM_M8Q_EVENT_STOP | Stop event. |
Definition at line 13 of file twr_sam_m8q.h.
bool twr_sam_m8q_get_accuracy | ( | twr_sam_m8q_t * | self, |
twr_sam_m8q_accuracy_t * | accuracy | ||
) |
Get accuracy.
[in] | self | Instance |
[out] | accuracy | Accuracy data structure |
Definition at line 124 of file twr_sam_m8q.c.
Referenced by twr_module_gps_get_accuracy().
bool twr_sam_m8q_get_altitude | ( | twr_sam_m8q_t * | self, |
twr_sam_m8q_altitude_t * | altitude | ||
) |
Get altitude.
[in] | self | Instance |
[out] | altitude | Altitude data structure |
Definition at line 94 of file twr_sam_m8q.c.
Referenced by twr_module_gps_get_altitude().
bool twr_sam_m8q_get_position | ( | twr_sam_m8q_t * | self, |
twr_sam_m8q_position_t * | position | ||
) |
Get position.
[in] | self | Instance |
[out] | position | Position data structure |
Definition at line 79 of file twr_sam_m8q.c.
Referenced by twr_module_gps_get_position().
bool twr_sam_m8q_get_quality | ( | twr_sam_m8q_t * | self, |
twr_sam_m8q_quality_t * | quality | ||
) |
Get quality.
[in] | self | Instance |
[out] | quality | Quality data structure |
Definition at line 109 of file twr_sam_m8q.c.
Referenced by twr_module_gps_get_quality().
bool twr_sam_m8q_get_time | ( | twr_sam_m8q_t * | self, |
twr_sam_m8q_time_t * | time | ||
) |
Get time.
[in] | self | Instance |
[out] | time | Time data structure |
Definition at line 60 of file twr_sam_m8q.c.
Referenced by twr_module_gps_get_time().
void twr_sam_m8q_init | ( | twr_sam_m8q_t * | self, |
twr_i2c_channel_t | channel, | ||
uint8_t | i2c_address, | ||
const twr_sam_m8q_driver_t * | driver | ||
) |
Initialize SAM-M8Q module driver.
[in] | self | Instance |
[in] | i2c_channel | I2C channel |
[in] | i2c_address | I2C device address |
[in] | driver | Optional driver (can be NULL) |
Definition at line 13 of file twr_sam_m8q.c.
void twr_sam_m8q_set_event_handler | ( | twr_sam_m8q_t * | self, |
twr_sam_m8q_event_handler_t | event_handler, | ||
void * | event_param | ||
) |
Set callback function.
[in] | self | Instance |
[in] | event_handler | Function address |
[in] | event_param | Optional event parameter (can be NULL) |
Definition at line 26 of file twr_sam_m8q.c.
void twr_sam_m8q_start | ( | twr_sam_m8q_t * | self | ) |
Start navigation module.
[in] | self | Instance |
Definition at line 32 of file twr_sam_m8q.c.
Referenced by twr_module_gps_start().
void twr_sam_m8q_stop | ( | twr_sam_m8q_t * | self | ) |
Stop navigation module.
[in] | self | Instance |
Definition at line 43 of file twr_sam_m8q.c.
Referenced by twr_module_gps_stop().