[nRF24] Cleanup private/protected members
This commit is contained in:
parent
3a5d9b5c32
commit
1575e37355
2 changed files with 7 additions and 8 deletions
|
@ -6,10 +6,6 @@ nRF24::nRF24(Module* mod) : PhysicalLayer(RADIOLIB_NRF24_FREQUENCY_STEP_SIZE, RA
|
|||
this->mod = mod;
|
||||
}
|
||||
|
||||
Module* nRF24::getMod() {
|
||||
return(this->mod);
|
||||
}
|
||||
|
||||
int16_t nRF24::begin(int16_t freq, int16_t dr, int8_t pwr, uint8_t addrWidth) {
|
||||
// set module properties
|
||||
this->mod->SPIreadCommand = RADIOLIB_NRF24_CMD_READ;
|
||||
|
@ -606,6 +602,10 @@ int16_t nRF24::config() {
|
|||
return(state);
|
||||
}
|
||||
|
||||
Module* nRF24::getMod() {
|
||||
return(this->mod);
|
||||
}
|
||||
|
||||
void nRF24::SPIreadRxPayload(uint8_t* data, uint8_t numBytes) {
|
||||
SPItransfer(RADIOLIB_NRF24_CMD_READ_RX_PAYLOAD, false, NULL, data, numBytes);
|
||||
}
|
||||
|
|
|
@ -195,8 +195,6 @@ class nRF24: public PhysicalLayer {
|
|||
*/
|
||||
nRF24(Module* mod);
|
||||
|
||||
Module* getMod();
|
||||
|
||||
// basic methods
|
||||
|
||||
/*!
|
||||
|
@ -470,15 +468,16 @@ class nRF24: public PhysicalLayer {
|
|||
#if !RADIOLIB_GODMODE && !RADIOLIB_LOW_LEVEL
|
||||
protected:
|
||||
#endif
|
||||
Module* mod;
|
||||
Module* getMod();
|
||||
|
||||
void SPIreadRxPayload(uint8_t* data, uint8_t numBytes);
|
||||
void SPIwriteTxPayload(uint8_t* data, uint8_t numBytes);
|
||||
void SPItransfer(uint8_t cmd, bool write = false, uint8_t* dataOut = NULL, uint8_t* dataIn = NULL, uint8_t numBytes = 0);
|
||||
|
||||
#if !RADIOLIB_GODMODE
|
||||
protected:
|
||||
private:
|
||||
#endif
|
||||
Module* mod;
|
||||
|
||||
int16_t frequency = RADIOLIB_NRF24_DEFAULT_FREQ;
|
||||
int16_t dataRate = RADIOLIB_NRF24_DEFAULT_DR;
|
||||
|
|
Loading…
Add table
Reference in a new issue