-
Notifications
You must be signed in to change notification settings - Fork 154
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Problem with setting PA_LEVEL at start of Mesh #242
Comments
I prefer option 2 since it is consistent with using I seem to remember a rejected PR (#210) about this that instigated changing |
Hmm, I had a feeling you'd prefer option 2 😆 I didn't realize this was fixed at the RF24 level. I guess the change isn't really required then? |
At a glance, no. Did you recently have some troubling experience that you attributed to this? |
Heh, the troubling experience was always adjusting my code to set the PALevel AFTER starting the mesh and again if mesh.begin() was called, which I see is not necessary anymore. |
I was suspecting an ebyte module; they don't seem to respect the user-specified PA level. |
So this one has been bugging me for a while, the problem is that
begin()
functionradio.begin()
in that function which resets the PA Level toRF24_PA_MAX
RF24Mesh/RF24Mesh.cpp
Lines 26 to 36 in 7827e87
In the examples for example, the PA Level is set prior to calling
mesh.begin()
, but this will just be undone by the call toradio.begin()
withinmesh.begin()
RF24Mesh/examples/RF24Mesh_Example/RF24Mesh_Example.ino
Lines 49 to 69 in 7827e87
I see one of 3 scenarios:
begin()
function, so it can set the PA Level after callingradio.begin()
radio.begin()
from RF24Mesh. This adds a some more complications, as it essentially changes the API, requiring users to callradio.begin()
prior to everymesh.begin()
call.mesh.begin()
I kind of prefer option 1, but would prefer option 2 if it wasn't breaking existing code.
If we choose option one, should the default be PA_MIN or PA_MAX ?
The text was updated successfully, but these errors were encountered: