cancel
Showing results for 
Search instead for 
Did you mean: 

I-CUBE-LRWAN Channel Activity Detection (CAD)

OCumm.1
Associate II

Hi,

I'm hoping that someone can help me implement a Channel Activity Detection (CAD) check on a TX channel before transmitting a message, as to implement a kind of CSMA version of LoRa. Basically I would like to know where CAD is carried out in the LoRa stack so that I can use it in my own bespoke case. Thank you,

Odhran

2 REPLIES 2

You might want to broaden your search of Semtech's CAD implementation/stack more generally. As I understand the CAD implementation it is a brief check to see if someone else is sending out preamble signal

https://github.com/sandeepmistry/arduino-LoRa/issues/221

https://github.com/Lora-net/LoRaMac-node/discussions/1026

https://forum.lora-developers.semtech.com/

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
OCumm.1
Associate II

Thanks for your response. I think your understanding is correct - and it is used as a lower-power alternative to sense for an RX packet than the traditional "continuously stay in RX mode" method.

However, for my application I am not too worried about power draw, and I am simply trying to avoid collisions between my LoRa nodes. The LoRa protocol is ALOHA and devices transmit at will without any channel assessment before hand. So I have managed to implement a clear-channel-assessment before sending any packets. The "ScheduleTx" function within LoRaMac.c is the function that calls "SendFrameOnChannel" ultimately "Radio.Send" which writes the commands to the SX1276 radio. Basically, before calling the "SendFrameOnChannel" function, I perform a clear channel assessment using "Radio.IsChannelFree". It seems to work a charm, and I hope this hopes others hoping to do this in the future. Cheers!