Go to the documentation of this file.
21 #include "IRsend_test.h"
71 explicit IRTrumaAc(
const uint16_t pin,
const bool inverted =
false,
72 const bool use_modulation =
true);
89 void setTemp(
const uint8_t celsius);
92 void setFan(
const uint8_t speed);
93 uint8_t
getFan(
void)
const;
96 void setMode(
const uint8_t mode);
102 void setRaw(
const uint64_t state);
126 #endif // IR_TRUMA_H_
void setTemp(const uint8_t celsius)
Set the temperature.
Definition: ir_Truma.cpp:225
const uint8_t kTrumaFanQuiet
Definition: ir_Truma.h:57
const uint8_t kTrumaCool
Definition: ir_Truma.h:54
static stdAc::opmode_t toCommonMode(const uint8_t mode)
Convert a native mode into its stdAc equivalent.
Definition: ir_Truma.cpp:275
void setQuiet(const bool on)
Change the Quiet setting.
Definition: ir_Truma.cpp:238
uint8_t getFan(void) const
Get the current fan speed setting.
Definition: ir_Truma.cpp:200
void checksum(void)
Calculate & set the checksum for the current internal state of the remote.
Definition: ir_Truma.cpp:143
const uint8_t kTrumaMaxTemp
Definition: ir_Truma.h:64
fanspeed_t
Common A/C settings for Fan Speeds.
Definition: IRsend.h:61
uint8_t getMode(void) const
Get the operating mode setting of the A/C.
Definition: ir_Truma.cpp:221
const uint64_t kTrumaDefaultState
Off, Auto, 16C, High.
Definition: ir_Truma.h:50
const uint8_t kTrumaMinTemp
Definition: ir_Truma.h:63
const uint8_t kTrumaAuto
Definition: ir_Truma.h:53
static stdAc::fanspeed_t toCommonFanSpeed(const uint8_t speed)
Convert a native fan speed into its stdAc equivalent.
Definition: ir_Truma.cpp:286
int8_t calibrate(void)
Run the calibration to calculate uSec timing offsets for this platform.
Definition: ir_Truma.h:79
uint8_t Fan
Definition: ir_Truma.h:33
void setMode(const uint8_t mode)
Set the operating mode of the A/C.
Definition: ir_Truma.cpp:204
void stateReset(void)
Reset the state of the remote to a known good state/sequence.
Definition: ir_Truma.cpp:146
const uint8_t kTrumaTempOffset
Definition: ir_Truma.h:62
Class for sending all basic IR protocols.
Definition: IRsend.h:237
uint64_t raw
Remote state in IR code form.
Definition: ir_Truma.h:26
int8_t calibrate(uint16_t hz=38000U)
Calculate & set any offsets to account for execution times during sending.
Definition: IRsend.cpp:207
void begin(void)
Set up hardware to be able to send a message.
Definition: ir_Truma.cpp:110
const uint8_t kTrumaChecksumInit
Definition: ir_Truma.h:51
std::string String
Definition: IRremoteESP8266.h:1521
void off(void)
Set the requested power state of the A/C to off.
Definition: ir_Truma.cpp:167
bool getQuiet(void) const
Get the value of the current quiet setting.
Definition: ir_Truma.cpp:247
void setRaw(const uint64_t state)
Set the internal state from a valid code for this protocol.
Definition: ir_Truma.cpp:157
TrumaProtocol _
Definition: ir_Truma.h:119
static bool validChecksum(const uint64_t state)
Verify the checksum is valid for a given state.
Definition: ir_Truma.cpp:136
void setPower(const bool on)
Change the power setting.
Definition: ir_Truma.cpp:171
IRsend _irsend
Instance of the IR send class.
Definition: ir_Truma.h:113
uint8_t Mode
Definition: ir_Truma.h:31
uint8_t Temp
Temp in DegC minus 10(DEC).
Definition: ir_Truma.h:36
uint8_t getTemp(void) const
Get the current temperature setting.
Definition: ir_Truma.cpp:233
const uint16_t kNoRepeat
Definition: IRremoteESP8266.h:1145
void setFan(const uint8_t speed)
Set the speed of the fan.
Definition: ir_Truma.cpp:182
void send(const uint16_t repeat=kNoRepeat)
Send the current internal state as an IR message.
Definition: ir_Truma.cpp:115
uint8_t _lastfan
Definition: ir_Truma.h:120
IRTrumaAc(const uint16_t pin, const bool inverted=false, const bool use_modulation=true)
Class constructor.
Definition: ir_Truma.cpp:105
String toString(void) const
Convert the current internal state into a human readable string.
Definition: ir_Truma.cpp:327
Native representation of a Truma A/C message.
Definition: ir_Truma.h:25
uint8_t Sum
Checksum value.
Definition: ir_Truma.h:45
stdAc::state_t toCommon(void) const
Convert the current internal state into its stdAc::state_t equivalent.
Definition: ir_Truma.cpp:297
void on(void)
Set the requested power state of the A/C to on.
Definition: ir_Truma.cpp:164
const uint8_t kTrumaFan
Definition: ir_Truma.h:55
static uint8_t convertFan(const stdAc::fanspeed_t speed)
Convert a stdAc::fanspeed_t enum into it's native speed.
Definition: ir_Truma.cpp:263
const uint8_t kTrumaFanMed
Definition: ir_Truma.h:59
uint64_t getRaw(void)
Get a copy of the internal state/code for this protocol.
Definition: ir_Truma.cpp:150
Class for handling detailed Truma A/C messages.
Definition: ir_Truma.h:69
static uint8_t calcChecksum(const uint64_t state)
Calculate the checksum for a given state.
Definition: ir_Truma.cpp:123
uint8_t PowerOff
Definition: ir_Truma.h:32
bool getPower(void) const
Get the value of the current power setting.
Definition: ir_Truma.cpp:178
const uint8_t kTrumaFanHigh
Definition: ir_Truma.h:58
uint8_t _lastmode
Definition: ir_Truma.h:121
const uint8_t kTrumaFanLow
Definition: ir_Truma.h:60
Structure to hold a common A/C state.
Definition: IRsend.h:114
static uint8_t convertMode(const stdAc::opmode_t mode)
Convert a stdAc::opmode_t enum into its native mode.
Definition: ir_Truma.cpp:252
opmode_t
Common A/C settings for A/C operating modes.
Definition: IRsend.h:49