1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-19 14:25:20 +03:00

Merge pull request #3028 from cleanflight/improve-osd-slave-comms (#5405)

Improve OSD slave timeout/disconnect/reconnect handling.
This commit is contained in:
Michael Keller 2018-03-15 02:30:46 +13:00 committed by GitHub
parent 85b922383b
commit dd25358a63
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
12 changed files with 144 additions and 63 deletions

View file

@ -134,10 +134,17 @@ static bool isTransferInProgress(const displayPort_t *displayPort)
return false;
}
static bool isSynced(const displayPort_t *displayPort)
{
UNUSED(displayPort);
return true;
}
static void resync(displayPort_t *displayPort)
{
displayPort->rows = 13 + displayPortProfileMsp()->rowAdjust; // XXX Will reflect NTSC/PAL in the future
displayPort->cols = 30 + displayPortProfileMsp()->colAdjust;
drawScreen(displayPort);
}
static uint32_t txBytesFree(const displayPort_t *displayPort)
@ -157,6 +164,7 @@ static const displayPortVTable_t mspDisplayPortVTable = {
.isTransferInProgress = isTransferInProgress,
.heartbeat = heartbeat,
.resync = resync,
.isSynced = isSynced,
.txBytesFree = txBytesFree
};