You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Whilst debugging an issue with a sketch using JeeLib a couple of questions have cropped up that I wonder if you can clarify.
the first is in the title, in the comments in rf12.cpp it says (in so many words) to use sendStart immediately after canSend returns true. and the sendNow function also does exactly that. But (for example) your RF12demo example uses the following code
is that ok to do so? Can anything change in the time it takes to do that stuff that might block the sendStart, or cause a conflict that might cause a perceived "lock up" that can be overcome by reinitializing the rfm like what is reported in issue #92 ?
The second question is regarding the recommendation or need to call the recvDone function "periodically" even when only using a device to send data. Is that comment still valid with the use of sendNow since that calls recvDone each time canSend returns false until a true is returned. Only if canSend always returns true first time would there be a period where revcDone isn't called when you're sending data regularly.
How often is periodically? is there any advantage to calling it at a particular time?
Is there any advantage to calling recvDone immediately before the send code block or even as part of the test to enter the send block?
And just for curiosity, why does the RF12demo not use sendNow? is it because you are avoiding blocking the main loop or does this code just pre-date that function?
Any clarification would be great, thanks.
The text was updated successfully, but these errors were encountered:
Whilst debugging an issue with a sketch using JeeLib a couple of questions have cropped up that I wonder if you can clarify.
the first is in the title, in the comments in rf12.cpp it says (in so many words) to use sendStart immediately after canSend returns true. and the sendNow function also does exactly that. But (for example) your RF12demo example uses the following code
is that ok to do so? Can anything change in the time it takes to do that stuff that might block the sendStart, or cause a conflict that might cause a perceived "lock up" that can be overcome by reinitializing the rfm like what is reported in issue #92 ?
The second question is regarding the recommendation or need to call the recvDone function "periodically" even when only using a device to send data. Is that comment still valid with the use of sendNow since that calls recvDone each time canSend returns false until a true is returned. Only if canSend always returns true first time would there be a period where revcDone isn't called when you're sending data regularly.
How often is periodically? is there any advantage to calling it at a particular time?
Is there any advantage to calling recvDone immediately before the send code block or even as part of the test to enter the send block?
And just for curiosity, why does the RF12demo not use sendNow? is it because you are avoiding blocking the main loop or does this code just pre-date that function?
Any clarification would be great, thanks.
The text was updated successfully, but these errors were encountered: