Navio: Delete (wrong) unnecessary ifdef and modify for new GPSDriverUBX constructor

This commit is contained in:
Hidenori
2016-10-06 09:00:09 +02:00
committed by Lorenz Meier
parent e7b582502a
commit 9bd3f6c9bf
+6 -2
View File
@@ -374,7 +374,7 @@ int GPS::pollOrRead(uint8_t *buf, size_t buf_length, int timeout)
{
handleInjectDataTopic();
#if !defined(__PX4_QURT) || !defined(__PX4_POSIX_RPI)
#if !defined(__PX4_QURT)
/* For non QURT, use the usual polling. */
@@ -701,7 +701,11 @@ GPS::task_main()
switch (_mode) {
case GPS_DRIVER_MODE_UBX:
_helper = new GPSDriverUBX(&GPS::callback, this, &_report_gps_pos, _p_report_sat_info);
#ifndef __PX4_POSIX_RPI
_helper = new GPSDriverUBX(GPSHelper::Interface::UART, &GPS::callback, this, &_report_gps_pos, _p_report_sat_info);
#else
_helper = new GPSDriverUBX(GPSHelper::Interface::SPI, &GPS::callback, this, &_report_gps_pos, _p_report_sat_info);
#endif
break;
case GPS_DRIVER_MODE_MTK: