Go to the documentation of this file.
13 #define __STDC_LIMIT_MACROS
21 #include "IRsend_test.h"
77 explicit IRAirtonAc(
const uint16_t pin,
const bool inverted =
false,
78 const bool use_modulation =
true);
93 void setTemp(
const uint8_t degrees);
95 void setFan(
const uint8_t speed);
96 uint8_t
getFan(
void)
const;
97 void setMode(
const uint8_t mode);
100 void setRaw(
const uint64_t data);
134 #endif // IR_AIRTON_H_
void setTurbo(const bool on)
Set the Turbo setting of the A/C.
Definition: ir_Airton.cpp:284
void send(const uint16_t repeat=kAirtonDefaultRepeat)
Send the current internal state as an IR message.
Definition: ir_Airton.cpp:92
static uint8_t calcChecksum(const uint64_t data)
Calculate the checksum for the supplied state.
Definition: ir_Airton.cpp:100
Class for handling detailed Airton 56-bit A/C messages.
Definition: ir_Airton.h:75
const uint8_t kAirtonMinTemp
Definition: ir_Airton.h:70
String toString(void) const
Convert the current internal state into a human readable string.
Definition: ir_Airton.cpp:345
swingv_t
Common A/C settings for Vertical Swing.
Definition: IRsend.h:74
const uint16_t kAirtonDefaultRepeat
Definition: IRremoteESP8266.h:1149
void setHealth(const bool on)
Set the Health/Filter setting of the A/C.
Definition: ir_Airton.cpp:311
static uint8_t convertFan(const stdAc::fanspeed_t speed)
Convert a stdAc::fanspeed_t enum into it's native speed.
Definition: ir_Airton.cpp:230
void checksum(void)
Update the checksum value for the internal state.
Definition: ir_Airton.cpp:114
fanspeed_t
Common A/C settings for Fan Speeds.
Definition: IRsend.h:61
uint8_t getMode(void) const
Get the current operation mode setting.
Definition: ir_Airton.cpp:151
static uint8_t convertMode(const stdAc::opmode_t mode)
Convert a stdAc::opmode_t enum into its native mode.
Definition: ir_Airton.cpp:180
const uint8_t kAirtonFanAuto
Definition: ir_Airton.h:63
void setFan(const uint8_t speed)
Set the speed of the fan.
Definition: ir_Airton.cpp:219
const uint8_t kAirtonCool
Definition: ir_Airton.h:58
uint8_t Turbo
Definition: ir_Airton.h:35
uint8_t Sleep
Definition: ir_Airton.h:44
AirtonProtocol _
Definition: ir_Airton.h:131
uint8_t NotAutoOn
Definition: ir_Airton.h:45
uint8_t HeatOn
Definition: ir_Airton.h:47
void setTemp(const uint8_t degrees)
Set the temperature.
Definition: ir_Airton.cpp:205
static stdAc::fanspeed_t toCommonFanSpeed(const uint8_t speed)
Convert a native fan speed into its stdAc equivalent.
Definition: ir_Airton.cpp:244
uint8_t SwingV
Definition: ir_Airton.h:40
const uint8_t kAirtonFanHigh
Definition: ir_Airton.h:67
bool getLight(void) const
Get the Light/LED/Display setting of the A/C.
Definition: ir_Airton.cpp:269
Class for sending all basic IR protocols.
Definition: IRsend.h:237
const uint8_t kAirtonMaxTemp
Definition: ir_Airton.h:71
int8_t calibrate(uint16_t hz=38000U)
Calculate & set any offsets to account for execution times during sending.
Definition: IRsend.cpp:207
const uint8_t kAirtonFanMax
Definition: ir_Airton.h:68
bool getSleep(void) const
Get the Sleep setting of the A/C.
Definition: ir_Airton.cpp:307
std::string String
Definition: IRremoteESP8266.h:1521
stdAc::state_t toCommon(void) const
Convert the current internal state into its stdAc::state_t equivalent.
Definition: ir_Airton.cpp:319
uint8_t Sum
Definition: ir_Airton.h:52
const uint8_t kAirtonFan
Definition: ir_Airton.h:60
void setPower(const bool on)
Set the internal state to have the desired power.
Definition: ir_Airton.cpp:140
Native representation of a Airton 56 A/C message.
Definition: ir_Airton.h:26
uint64_t getRaw(void)
Get the raw state of the object, suitable to be sent with the appropriate IRsend object method.
Definition: ir_Airton.cpp:122
bool getHealth(void) const
Get the Health/Filter setting of the A/C.
Definition: ir_Airton.cpp:315
uint8_t Health
Definition: ir_Airton.h:49
const uint8_t kAirtonFanLow
Definition: ir_Airton.h:65
const uint8_t kAirtonHeat
Definition: ir_Airton.h:61
uint8_t Power
Definition: ir_Airton.h:33
uint8_t Mode
Definition: ir_Airton.h:32
bool getEcono(void) const
Get the Economy setting of the A/C.
Definition: ir_Airton.cpp:280
static bool validChecksum(const uint64_t data)
Verify the checksum is valid for a given state.
Definition: ir_Airton.cpp:107
void setLight(const bool on)
Set the Light/LED/Display setting of the A/C.
Definition: ir_Airton.cpp:265
void on(void)
Set the internal state to have the power on.
Definition: ir_Airton.cpp:133
const uint8_t kAirtonAuto
Definition: ir_Airton.h:57
void setMode(const uint8_t mode)
Set the desired operation mode.
Definition: ir_Airton.cpp:155
uint8_t Fan
Definition: ir_Airton.h:34
void off(void)
Set the internal state to have the power off.
Definition: ir_Airton.cpp:136
const uint8_t kAirtonDry
Definition: ir_Airton.h:59
bool getSwingV(void) const
Get the Vertical Swing setting of the A/C.
Definition: ir_Airton.cpp:261
void setEcono(const bool on)
Set the Economy setting of the A/C.
Definition: ir_Airton.cpp:274
static uint8_t convertSwingV(const stdAc::swingv_t position)
static stdAc::opmode_t toCommonMode(const uint8_t mode)
Convert a native mode into its stdAc equivalent.
Definition: ir_Airton.cpp:193
void stateReset(void)
Reset the internals of the object to a known good state.
Definition: ir_Airton.cpp:117
uint8_t Light
Definition: ir_Airton.h:50
bool getTurbo(void) const
Get the Turbo setting of the A/C.
Definition: ir_Airton.cpp:292
IRsend _irsend
Instance of the IR send class.
Definition: ir_Airton.h:125
const uint8_t kAirtonFanMed
Definition: ir_Airton.h:66
uint8_t getTemp(void) const
Get the current temperature setting.
Definition: ir_Airton.cpp:214
void begin(void)
Set up hardware to be able to send a message.
Definition: ir_Airton.cpp:87
void setRaw(const uint64_t data)
Set the raw state of the object.
Definition: ir_Airton.cpp:129
uint8_t Temp
Definition: ir_Airton.h:37
void setSleep(const bool on)
Set the Sleep setting of the A/C.
Definition: ir_Airton.cpp:297
int8_t calibrate(void)
Run the calibration to calculate uSec timing offsets for this platform.
Definition: ir_Airton.h:86
IRAirtonAc(const uint16_t pin, const bool inverted=false, const bool use_modulation=true)
Class constructor.
Definition: ir_Airton.cpp:82
uint8_t Econo
Definition: ir_Airton.h:43
const uint8_t kAirtonFanMin
Definition: ir_Airton.h:64
bool getPower(void) const
Get the power setting from the internal state.
Definition: ir_Airton.cpp:147
Structure to hold a common A/C state.
Definition: IRsend.h:114
uint64_t raw
The state in code form.
Definition: ir_Airton.h:27
uint16_t Header
Definition: ir_Airton.h:30
uint8_t getFan(void) const
Get the current fan speed setting.
Definition: ir_Airton.cpp:225
void setSwingV(const bool on)
Set the Vertical Swing setting of the A/C.
Definition: ir_Airton.cpp:257
opmode_t
Common A/C settings for A/C operating modes.
Definition: IRsend.h:49