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
I am using the gettingstarted.cpp to test the library. I use the following declaration:
RF24 radio(10, 10, 1000000).
So chip enable on GPIO10, Spi on 1.0 as 0.0 is used by flash. And speed for testing, I could probably ramp it up.
For a few days struggling to find out why the gettingstarted program failed with a "hardware fault". With a logic analyzer I saw the SPI is transmitting OK, but the CE pin never got high.
It seems the following code is prohibiting the CE pin to go high:
RF24.cpp from line 103 void RF24::ce(bool level) { //Allow for 3-pin use on ATTiny if (ce_pin != csn_pin) { digitalWrite(ce_pin, level); } }
Because I use the 10,10 declaration it read as if both pins are the same. Except the Orange Pi Zero CS pin is GPIO13. See pinout: https://linux-sunxi.org/Xunlong_Orange_Pi_Zero#Expansion_Port
I got it to work by just commenting the if statement and only leaving the digitalWrite there.
It might be a possible bug, but depends on the platform and gpio used
The text was updated successfully, but these errors were encountered:
@fertinator If you could test this fix to make sure it works on your OrangePi, we can move forward with this fix (a PR would be welcome if the fix works).
I am using the gettingstarted.cpp to test the library. I use the following declaration:
RF24 radio(10, 10, 1000000).
So chip enable on GPIO10, Spi on 1.0 as 0.0 is used by flash. And speed for testing, I could probably ramp it up.
For a few days struggling to find out why the gettingstarted program failed with a "hardware fault". With a logic analyzer I saw the SPI is transmitting OK, but the CE pin never got high.
It seems the following code is prohibiting the CE pin to go high:
RF24.cpp from line 103
void RF24::ce(bool level) { //Allow for 3-pin use on ATTiny if (ce_pin != csn_pin) { digitalWrite(ce_pin, level); } }
Because I use the 10,10 declaration it read as if both pins are the same. Except the Orange Pi Zero CS pin is GPIO13. See pinout: https://linux-sunxi.org/Xunlong_Orange_Pi_Zero#Expansion_Port
I got it to work by just commenting the if statement and only leaving the digitalWrite there.
It might be a possible bug, but depends on the platform and gpio used
The text was updated successfully, but these errors were encountered: