shelly-script-examples
shelly-script-examples copied to clipboard
Channel Activity Detection (CAD) / CSMA-CA
I need to solve the problem when many Shelly LoRa devices send message the same time, how can I avoid collision to ensure the package successfully delivered.
Is there a 'cad' parameter or someway that can check the channel status and tell me the status, so I can react accordingly.
function sendMessage(msg) { Shelly.call( 'Lora.SendBytes', { id: 100, data: btoa(msg), cad: true, }, function (data, err, errmsg) { if (err) { console.log('Error:', err, errmsg); return; } } ); }