RadioHead help needed

Hi all

I was wondering how often I need my code to check if a message has been received by a 433MHz ASK receiver, because it currently running a program which controls WS2815 LEDs, and has different 'states' which update every 100-400 milliseconds, would that be often enough to check if a message had been received between each state, and also, when a message is received, does the receiver temporarily store it somehow until the code checks if it's been received/ a new message is received, because if not then I understand it as the code can only receive the message if it's checking while it's being sent/received.

Thanks

It would be better if you wrote the code such that there is not such a long period between checking for input

I am guessing that your code uses delay() and/or while or for loops to control the LED sequences. If that is the case then consider using millis() and implement non blocking timing

See Using millis() for timing. A beginners guide, Several things at the same time and the BlinkWithoutDelay example in the IDE

I’ll look into using the millis() function, but how often should to check if a message had been received?

Check available() often as possible. It takes vanishingly little time to determine whether a message is available.

when a message is received, does the receiver temporarily store it somehow until the code checks if it's been received

Yes, but if another message comes in before the stored message is read out, the stored message is overwritten.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.