Merge branch '2.2' into 2.3
This commit is contained in:
@@ -942,7 +942,7 @@ QString TelemetrySimulator::LogPlaybackController::convertGPS(QString input)
|
|||||||
lon = convertDegMin(lonLat[0]);
|
lon = convertDegMin(lonLat[0]);
|
||||||
lat = convertDegMin(lonLat[1]);
|
lat = convertDegMin(lonLat[1]);
|
||||||
}
|
}
|
||||||
return QString::number(lat) + ", " + QString::number(lon);
|
return QString::number(lat, 'f', 6) + ", " + QString::number(lon, 'f', 6);
|
||||||
}
|
}
|
||||||
|
|
||||||
void TelemetrySimulator::LogPlaybackController::updatePositionLabel(int32_t percentage)
|
void TelemetrySimulator::LogPlaybackController::updatePositionLabel(int32_t percentage)
|
||||||
|
|||||||
@@ -44,7 +44,7 @@ enum BluetoothStates {
|
|||||||
|
|
||||||
#define LEN_BLUETOOTH_ADDR 16
|
#define LEN_BLUETOOTH_ADDR 16
|
||||||
|
|
||||||
#if defined(PCBX7)
|
#if (defined(PCBX7) || defined(PCBXLITE)) && !defined(SIMU)
|
||||||
extern uint8_t btChipPresent;
|
extern uint8_t btChipPresent;
|
||||||
#define IS_BLUETOOTH_CHIP_PRESENT() (btChipPresent)
|
#define IS_BLUETOOTH_CHIP_PRESENT() (btChipPresent)
|
||||||
#else
|
#else
|
||||||
|
|||||||
@@ -296,7 +296,8 @@ uint8_t BitmapBuffer::drawCharWithoutCache(coord_t x, coord_t y, const uint8_t *
|
|||||||
{
|
{
|
||||||
coord_t offset = spec[index];
|
coord_t offset = spec[index];
|
||||||
coord_t width = spec[index+1] - offset;
|
coord_t width = spec[index+1] - offset;
|
||||||
if (width > 0) drawBitmapPattern(x, y, font, flags, offset, width);
|
if (width > 0)
|
||||||
|
drawBitmapPattern(x, y, font, flags, offset, width);
|
||||||
return width;
|
return width;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -304,7 +305,8 @@ uint8_t BitmapBuffer::drawCharWithCache(coord_t x, coord_t y, const BitmapBuffer
|
|||||||
{
|
{
|
||||||
coord_t offset = spec[index];
|
coord_t offset = spec[index];
|
||||||
coord_t width = spec[index+1] - offset;
|
coord_t width = spec[index+1] - offset;
|
||||||
drawBitmap(x, y, font, offset, 0, width);
|
if (width > 0)
|
||||||
|
drawBitmap(x, y, font, offset, 0, width);
|
||||||
return width;
|
return width;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -105,7 +105,7 @@ PACK(struct PxxUartPulsesData {
|
|||||||
#define MULTIMODULE_BAUDRATE 100000
|
#define MULTIMODULE_BAUDRATE 100000
|
||||||
#define MULTIMODULE_PERIOD 7 /*ms*/
|
#define MULTIMODULE_PERIOD 7 /*ms*/
|
||||||
|
|
||||||
#if !defined(EXTMODULE_USART) || !defined(EXTMODULE_USART)
|
#if !defined(INTMODULE_USART) || !defined(EXTMODULE_USART)
|
||||||
/* PXX uses 20 bytes (as of Rev 1.1 document) with 8 changes per byte + stop bit ~= 162 max pulses */
|
/* PXX uses 20 bytes (as of Rev 1.1 document) with 8 changes per byte + stop bit ~= 162 max pulses */
|
||||||
/* DSM2 uses 2 header + 12 channel bytes, with max 10 changes (8n2) per byte + 16 bits trailer ~= 156 max pulses */
|
/* DSM2 uses 2 header + 12 channel bytes, with max 10 changes (8n2) per byte + 16 bits trailer ~= 156 max pulses */
|
||||||
/* Multimodule uses 3 bytes header + 22 channel bytes with max 11 changes per byte (8e2) + 16 bits trailer ~= 291 max pulses */
|
/* Multimodule uses 3 bytes header + 22 channel bytes with max 11 changes per byte (8e2) + 16 bits trailer ~= 291 max pulses */
|
||||||
|
|||||||
@@ -23,7 +23,7 @@
|
|||||||
Fifo<uint8_t, 64> btTxFifo;
|
Fifo<uint8_t, 64> btTxFifo;
|
||||||
Fifo<uint8_t, 64> btRxFifo;
|
Fifo<uint8_t, 64> btRxFifo;
|
||||||
|
|
||||||
#if defined(PCBX7)
|
#if defined(PCBX7) || defined(PCBXLITE)
|
||||||
uint8_t btChipPresent = 0;
|
uint8_t btChipPresent = 0;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -109,9 +109,9 @@ extern "C" void BT_USART_IRQHandler(void)
|
|||||||
USART_ClearITPendingBit(BT_USART, USART_IT_RXNE);
|
USART_ClearITPendingBit(BT_USART, USART_IT_RXNE);
|
||||||
uint8_t byte = USART_ReceiveData(BT_USART);
|
uint8_t byte = USART_ReceiveData(BT_USART);
|
||||||
btRxFifo.push(byte);
|
btRxFifo.push(byte);
|
||||||
#if defined(PCBX7)
|
#if defined(PCBX7) || defined(PCBXLITE)
|
||||||
if (!btChipPresent) {
|
if (!btChipPresent) {
|
||||||
// This is to differentiate X7 and X7S
|
// This is to differentiate X7 and X7S and X-Lite with/without BT
|
||||||
btChipPresent = 1;
|
btChipPresent = 1;
|
||||||
bluetoothDone();
|
bluetoothDone();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user