Updated buffer lengths

This commit is contained in:
Mark Qvist 2019-01-08 13:19:58 +01:00
parent 00dcf5a300
commit 42dcd121cc
4 changed files with 21 additions and 22 deletions

View file

@ -53,13 +53,14 @@ void kiss_messageCallback(AX25Ctx *ctx) {
void kiss_csma(AX25Ctx *ctx, uint8_t *buf, size_t len) {
bool sent = false;
if (CONFIG_AFSK_TXWAIT > 0) {
ticks_t wait_start = timer_clock();
long wait_ticks = ms_to_ticks(CONFIG_AFSK_TXWAIT);
while (timer_clock() - wait_start < wait_ticks) {
cpu_relax();
}
}
// TODO: Determine if this is to be removed
// if (CONFIG_AFSK_TXWAIT > 0) {
// ticks_t wait_start = timer_clock();
// long wait_ticks = ms_to_ticks(CONFIG_AFSK_TXWAIT);
// while (timer_clock() - wait_start < wait_ticks) {
// cpu_relax();
// }
// }
while (!sent) {
if(CONFIG_FULL_DUPLEX || !channel->hdlc.dcd) {
uint8_t tp = rand() & 0xFF;