1
0
Fork 0
mirror of https://github.com/opentx/opentx.git synced 2025-07-26 09:45:21 +03:00

Fix timing of Multi and DSM2 protocol

We send an extra stopbit and the logic for driving the transistor was swapped. Thanks Mike for noticing (http://www.rcgroups.com/forums/showpost.php?p=35671709&postcount=5151)
This commit is contained in:
Arne Schwabe 2016-09-08 10:00:07 +02:00
parent 753b12f886
commit de3db6eec0
2 changed files with 4 additions and 4 deletions

View file

@ -87,7 +87,7 @@ static void sendByteMulti(uint8_t b) //max 11 changes 0 10 10 10 10 P 1
if (i==7)
b = b ^ parity; // lowest bit is one from previous line
}
_send_level(len+2*BITLEN_MULTI); // 2Stop bits
_send_level(len+ BITLEN_MULTI); // enlarge the last bit to be two stop bits long
}
#endif
@ -106,7 +106,7 @@ void setupPulsesMultimodule(uint8_t port)
modulePulsesData[EXTERNAL_MODULE].dsm2.serialBitCount = 0 ;
#else
modulePulsesData[EXTERNAL_MODULE].dsm2.rest = 18000; // 9ms refresh
modulePulsesData[EXTERNAL_MODULE].dsm2.index = 1;
modulePulsesData[EXTERNAL_MODULE].dsm2.index = 0;
#endif
modulePulsesData[EXTERNAL_MODULE].dsm2.ptr = modulePulsesData[EXTERNAL_MODULE].dsm2.pulses;