fix from frog32 for external adc channel allocation;
fix from mwc forum for frsky telemetry gps output git-svn-id: https://afrodevices.googlecode.com/svn/trunk/baseflight@237 7c89a4a9-59b9-e629-4cfe-3a2d53b20e61
This commit is contained in:
parent
12dfa8915d
commit
af7e135d75
4359
obj/baseflight.hex
4359
obj/baseflight.hex
File diff suppressed because it is too large
Load Diff
|
@ -454,7 +454,7 @@ bool pwmInit(drv_pwm_config_t *init)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
// skip ADC for powerMeter if configured
|
// skip ADC for powerMeter if configured
|
||||||
if (init->adcChannel && (init->adcChannel == PWM2 || init->adcChannel == PWM8))
|
if (init->adcChannel && (init->adcChannel == port))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
// hacks to allow current functionality
|
// hacks to allow current functionality
|
||||||
|
|
|
@ -119,7 +119,7 @@ static void sendGPS(void)
|
||||||
sendDataHead(ID_LATITUDE_BP);
|
sendDataHead(ID_LATITUDE_BP);
|
||||||
serialize16(abs(GPS_coord[LAT]) / 100000);
|
serialize16(abs(GPS_coord[LAT]) / 100000);
|
||||||
sendDataHead(ID_LATITUDE_AP);
|
sendDataHead(ID_LATITUDE_AP);
|
||||||
serialize16((abs(GPS_coord[LAT]) / 100000) % 10000);
|
serialize16((abs(GPS_coord[LAT]) / 10) % 10000);
|
||||||
|
|
||||||
sendDataHead(ID_N_S);
|
sendDataHead(ID_N_S);
|
||||||
serialize16(GPS_coord[LAT] < 0 ? 'S' : 'N');
|
serialize16(GPS_coord[LAT] < 0 ? 'S' : 'N');
|
||||||
|
@ -127,7 +127,7 @@ static void sendGPS(void)
|
||||||
sendDataHead(ID_LONGITUDE_BP);
|
sendDataHead(ID_LONGITUDE_BP);
|
||||||
serialize16(abs(GPS_coord[LON]) / 100000);
|
serialize16(abs(GPS_coord[LON]) / 100000);
|
||||||
sendDataHead(ID_LONGITUDE_AP);
|
sendDataHead(ID_LONGITUDE_AP);
|
||||||
serialize16((abs(GPS_coord[LON]) / 100000) % 10000);
|
serialize16((abs(GPS_coord[LON]) / 10) % 10000);
|
||||||
sendDataHead(ID_E_W);
|
sendDataHead(ID_E_W);
|
||||||
serialize16(GPS_coord[LON] < 0 ? 'W' : 'E');
|
serialize16(GPS_coord[LON] < 0 ? 'W' : 'E');
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue