Added some initializations to prevent missunderstandings and errors
This commit is contained in:
parent
31e56f6c2b
commit
185fea987d
@ -28,7 +28,7 @@ private:
|
|||||||
std::vector<std::shared_ptr<InverterAbstract>> _inverters;
|
std::vector<std::shared_ptr<InverterAbstract>> _inverters;
|
||||||
std::unique_ptr<HoymilesRadio> _radio;
|
std::unique_ptr<HoymilesRadio> _radio;
|
||||||
|
|
||||||
uint32_t _pollInterval;
|
uint32_t _pollInterval = 0;
|
||||||
uint32_t _lastPoll = 0;
|
uint32_t _lastPoll = 0;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@ -75,12 +75,12 @@ private:
|
|||||||
std::unique_ptr<SPIClass> _hspi;
|
std::unique_ptr<SPIClass> _hspi;
|
||||||
std::unique_ptr<RF24> _radio;
|
std::unique_ptr<RF24> _radio;
|
||||||
uint8_t _rxChLst[5] = { 3, 23, 40, 61, 75 };
|
uint8_t _rxChLst[5] = { 3, 23, 40, 61, 75 };
|
||||||
uint8_t _rxChIdx;
|
uint8_t _rxChIdx = 0;
|
||||||
|
|
||||||
uint8_t _txChLst[5] = { 3, 23, 40, 61, 75 };
|
uint8_t _txChLst[5] = { 3, 23, 40, 61, 75 };
|
||||||
uint8_t _txChIdx;
|
uint8_t _txChIdx = 0;
|
||||||
|
|
||||||
volatile bool _packetReceived;
|
volatile bool _packetReceived = false;
|
||||||
|
|
||||||
CircularBuffer<fragment_t, FRAGMENT_BUFFER_SIZE> _rxBuffer;
|
CircularBuffer<fragment_t, FRAGMENT_BUFFER_SIZE> _rxBuffer;
|
||||||
TimeoutHelper _rxTimeout;
|
TimeoutHelper _rxTimeout;
|
||||||
|
|||||||
@ -47,7 +47,7 @@ public:
|
|||||||
|
|
||||||
private:
|
private:
|
||||||
serial_u _serial;
|
serial_u _serial;
|
||||||
char _name[MAX_NAME_LENGTH];
|
char _name[MAX_NAME_LENGTH] = "";
|
||||||
fragment_t _rxFragmentBuffer[MAX_RF_FRAGMENT_COUNT];
|
fragment_t _rxFragmentBuffer[MAX_RF_FRAGMENT_COUNT];
|
||||||
uint8_t _rxFragmentMaxPacketId = 0;
|
uint8_t _rxFragmentMaxPacketId = 0;
|
||||||
uint8_t _rxFragmentLastPacketId = 0;
|
uint8_t _rxFragmentLastPacketId = 0;
|
||||||
|
|||||||
@ -30,9 +30,9 @@ private:
|
|||||||
uint32_t _lastUpdateAll = 0;
|
uint32_t _lastUpdateAll = 0;
|
||||||
uint32_t _lastUpdateSample = 0;
|
uint32_t _lastUpdateSample = 0;
|
||||||
|
|
||||||
uint8_t _payloadDevInfoAll[DEV_INFO_SIZE];
|
uint8_t _payloadDevInfoAll[DEV_INFO_SIZE] = {};
|
||||||
uint8_t _devInfoAllLength;
|
uint8_t _devInfoAllLength = 0;
|
||||||
|
|
||||||
uint8_t _payloadDevInfoSample[DEV_INFO_SIZE];
|
uint8_t _payloadDevInfoSample[DEV_INFO_SIZE] = {};
|
||||||
uint8_t _devInfoSampleLength;
|
uint8_t _devInfoSampleLength = 0;
|
||||||
};
|
};
|
||||||
@ -114,8 +114,8 @@ public:
|
|||||||
void setChannelMaxPower(uint8_t channel, uint16_t power);
|
void setChannelMaxPower(uint8_t channel, uint16_t power);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
uint8_t _payloadStatistic[STATISTIC_PACKET_SIZE];
|
uint8_t _payloadStatistic[STATISTIC_PACKET_SIZE] = {};
|
||||||
uint8_t _statisticLength;
|
uint8_t _statisticLength = 0;
|
||||||
uint16_t _chanMaxPower[CH4];
|
uint16_t _chanMaxPower[CH4];
|
||||||
|
|
||||||
const byteAssign_t* _byteAssignment;
|
const byteAssign_t* _byteAssignment;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user