#1 2015-07-31 22:01:01

Henry
Member
Registered: 2015-07-22
Posts: 6

CSMA on Serial Protocol

Is implemeting CSMA on Simple Serial simply a matter of adding

void kiss_csma(AX25Ctx *ctx, uint8_t *buf, size_t len);

to the SimpleSerial.h file?

I havent been able to find any other locations where CSMA is configured?

Thanks

Offline

#2 2015-07-31 22:41:35

Henry
Member
Registered: 2015-07-22
Posts: 6

Re: CSMA on Serial Protocol

I guess in the  MicroModemGP protocol (which is teh one I will likely use for a serial data application) one would add

void kiss_csma(LLPCtx *ctx, uint8_t *buf, size_t len);

to the LLP.h file ?

Thanks for your help.

Henry

Offline

#3 2015-08-01 14:22:41

IW3IJQ
Member
Registered: 2015-07-27
Posts: 13

Re: CSMA on Serial Protocol

I think that you have only to enable SERIAL_FRAMIMG_DIRECT in confing.h in MicroModemGP

Try in this way. I didn't studied sources enought to be sure.

Offline

#4 2015-08-03 02:11:53

Henry
Member
Registered: 2015-07-22
Posts: 6

Re: CSMA on Serial Protocol

The MicroModemGP is default Serial Direst and wo CSMA. (As I understand it). So there is no need to enable Serial. So Im stuck as to how to enable CSMA still. Any help would be appreciated.

Thanks
Henry

Offline

#5 2015-08-05 20:25:01

markqvist
Administrator
Registered: 2014-12-01
Posts: 112

Re: CSMA on Serial Protocol

Hi Henry!
Sorry for the slow reply on this! In the newest MicroModemGP (commit 207898041ca6e4a0f989110568a5180e693f9e75), CSMA is already enabled, no matter if you use KISS or direct serial framing. I know it's a little confusing, but take a look at line 92 of "KISS.c":

void kiss_checkTimeout(bool force) {
    if (force || (IN_FRAME && timer_clock() - timeout_ticks > ms_to_ticks(TX_MAXWAIT))) {
        kiss_csma(llpCtx, serialBuffer, frame_len);
        IN_FRAME = false;
        frame_len = 0;
    }
    
}

Here the CSMA procedure is called when using direct serial framing smile

Offline

Board footer

Powered by FluxBB