forked from Archive/PX4-Autopilot
Merge branch 'master' of github.com:PX4/Firmware into attitude_filter_improvement
This commit is contained in:
commit
e6bc395291
|
@ -880,6 +880,7 @@ void *ubx_watchdog_loop(void *args)
|
||||||
int *fd = arguments->fd_ptr;
|
int *fd = arguments->fd_ptr;
|
||||||
bool *thread_should_exit = arguments->thread_should_exit_ptr;
|
bool *thread_should_exit = arguments->thread_should_exit_ptr;
|
||||||
|
|
||||||
|
ubx_config_state = UBX_CONFIG_STATE_PRT;
|
||||||
/* first try to configure the GPS anyway */
|
/* first try to configure the GPS anyway */
|
||||||
configure_gps_ubx(fd);
|
configure_gps_ubx(fd);
|
||||||
|
|
||||||
|
@ -892,7 +893,7 @@ void *ubx_watchdog_loop(void *args)
|
||||||
bool once_ok = false;
|
bool once_ok = false;
|
||||||
|
|
||||||
int mavlink_fd = open(MAVLINK_LOG_DEVICE, 0);
|
int mavlink_fd = open(MAVLINK_LOG_DEVICE, 0);
|
||||||
ubx_config_state = UBX_CONFIG_STATE_PRT;
|
|
||||||
//int err_skip_counter = 0;
|
//int err_skip_counter = 0;
|
||||||
|
|
||||||
while (!(*thread_should_exit)) {
|
while (!(*thread_should_exit)) {
|
||||||
|
@ -940,7 +941,9 @@ void *ubx_watchdog_loop(void *args)
|
||||||
ubx_healthy = false;
|
ubx_healthy = false;
|
||||||
ubx_success_count = 0;
|
ubx_success_count = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* trying to reconfigure the gps configuration */
|
/* trying to reconfigure the gps configuration */
|
||||||
|
ubx_config_state = UBX_CONFIG_STATE_PRT;
|
||||||
configure_gps_ubx(fd);
|
configure_gps_ubx(fd);
|
||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
sleep(1);
|
sleep(1);
|
||||||
|
|
|
@ -51,9 +51,9 @@
|
||||||
//internal definitions (not depending on the ubx protocol
|
//internal definitions (not depending on the ubx protocol
|
||||||
#define UBX_NO_OF_MESSAGES 7 /**< Read 7 UBX GPS messages */
|
#define UBX_NO_OF_MESSAGES 7 /**< Read 7 UBX GPS messages */
|
||||||
#define UBX_WATCHDOG_CRITICAL_TIME_MICROSECONDS 3000000 /**< Allow 3 seconds maximum inter-message time */
|
#define UBX_WATCHDOG_CRITICAL_TIME_MICROSECONDS 3000000 /**< Allow 3 seconds maximum inter-message time */
|
||||||
#define UBX_WATCHDOG_WAIT_TIME_MICROSECONDS 1000000 /**< Check for current state every second */
|
#define UBX_WATCHDOG_WAIT_TIME_MICROSECONDS 2000000 /**< Check for current state every two seconds */
|
||||||
|
|
||||||
#define UBX_CONFIG_TIMEOUT 500000
|
#define UBX_CONFIG_TIMEOUT 1000000
|
||||||
|
|
||||||
#define APPNAME "gps: ubx"
|
#define APPNAME "gps: ubx"
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue