fix nasty bug

This commit is contained in:
Kevin Hester 2021-03-12 15:47:00 +08:00
parent c097852ab0
commit 8cd2a00a25
2 changed files with 9 additions and 6 deletions

View File

@ -4,11 +4,8 @@ You probably don't care about this section - skip to the next one.
## 1.2 cleanup & multichannel support:
nastybug
try again on esp32
emittx thinks it emitted but client sees nothing. works again later
segger logs have errors in formatting that should be impossible (because not going through serial, try stalling on segger)
* cdcacm bug on nrf52: emittx thinks it emitted but client sees nothing. works again later
* nrf52: segger logs have errors in formatting that should be impossible (because not going through serial, try stalling on segger)
* DONE call RouterPlugin for *all* packets - not just Router packets
* DONE generate channel hash from the name of the channel+the psk (not just one or the other)
* DONE send a hint that can be used to select which channel to try and hash against with each message

View File

@ -71,12 +71,18 @@ void StreamAPI::writeStream()
void StreamAPI::emitTxBuffer(size_t len)
{
if (len != 0) {
DEBUG_MSG("emit tx %d\n", len);
txBuf[0] = START1;
txBuf[1] = START2;
txBuf[2] = (len >> 8) & 0xff;
txBuf[3] = len & 0xff;
stream->write(txBuf, len + HEADER_LEN);
auto totalLen = len + HEADER_LEN;
stream->write(txBuf, totalLen);
/* for(size_t i = 0; i < totalLen; i++) {
stream->write(txBuf[i]);
// stream->flush();
} */
}
}