1
0
Fork 0
mirror of https://github.com/iNavFlight/inav.git synced 2025-07-24 16:55:29 +03:00

fix problem with smartaudio on softserial

This commit is contained in:
jmajew 2021-09-21 23:59:03 +02:00
parent b51cb7739a
commit 2e74dc3575

View file

@ -492,14 +492,9 @@ static void saReceiveFramer(uint8_t c)
static void saSendFrame(uint8_t *buf, int len)
{
switch (smartAudioSerialPort->identifier) {
case SERIAL_PORT_SOFTSERIAL1:
case SERIAL_PORT_SOFTSERIAL2:
break;
default:
serialWrite(smartAudioSerialPort, 0x00); // Generate 1st start bit
break;
}
// TBS SA definition requires that the line is low before frame is sent
// (for both soft and hard serial). It can be done by sending first 0x00
serialWrite(smartAudioSerialPort, 0x00);
for (int i = 0 ; i < len ; i++) {
serialWrite(smartAudioSerialPort, buf[i]);