mirror of
https://github.com/Show-maket/IR-protocol.git
synced 2025-06-28 05:09:40 +00:00
default constructor and operator() for test
This commit is contained in:
@ -11,6 +11,8 @@ std::list<IR_Encoder*>& IR_Encoder::get_enc_list() // определение ф
|
||||
return dec_list; // возвращается ссылка на переменную
|
||||
}
|
||||
|
||||
IR_Encoder::IR_Encoder(){};
|
||||
|
||||
IR_Encoder::IR_Encoder(uint8_t pin, uint16_t addr, IR_DecoderRaw *decPair)
|
||||
{
|
||||
setPin(pin);
|
||||
@ -46,8 +48,6 @@ void IR_Encoder::setBlindDecoders(IR_DecoderRaw *decoders[], uint8_t count)
|
||||
|
||||
IR_Encoder::~IR_Encoder()
|
||||
{
|
||||
delete[] bitLow;
|
||||
delete[] bitHigh;
|
||||
get_enc_list().remove(this);
|
||||
};
|
||||
|
||||
@ -392,10 +392,10 @@ void IR_Encoder::addSync(bool *prev, bool *next)
|
||||
}
|
||||
}
|
||||
|
||||
uint8_t* IR_Encoder::bitHigh = new uint8_t[2]{
|
||||
uint8_t IR_Encoder::bitHigh[2] = {
|
||||
(bitPauseTakts) * 2 - 1,
|
||||
(bitActiveTakts) * 2 - 1};
|
||||
uint8_t* IR_Encoder::bitLow = new uint8_t[2]{
|
||||
uint8_t IR_Encoder::bitLow[2] = {
|
||||
(bitPauseTakts/2 + bitActiveTakts) * 2 - 1,
|
||||
(bitPauseTakts) - 1};
|
||||
|
||||
|
Reference in New Issue
Block a user