IRremoteESP8266
ir_Sharp.h
Go to the documentation of this file.
1 // Copyright 2019 crankyoldgit
2 
12 
13 // Supports:
14 // Brand: Sharp, Model: LC-52D62U TV
15 // Brand: Sharp, Model: AY-ZP40KR A/C (A907)
16 // Brand: Sharp, Model: AH-AxSAY A/C (A907)
17 // Brand: Sharp, Model: CRMC-A907 JBEZ remote (A907)
18 // Brand: Sharp, Model: AH-XP10NRY A/C (A907)
19 // Brand: Sharp, Model: CRMC-820 JBEZ remote (A907)
20 // Brand: Sharp, Model: CRMC-A705 JBEZ remote (A705)
21 
22 #ifndef IR_SHARP_H_
23 #define IR_SHARP_H_
24 
25 #ifndef UNIT_TEST
26 #include <Arduino.h>
27 #endif
28 #include "IRrecv.h"
29 #include "IRremoteESP8266.h"
30 #include "IRsend.h"
31 #ifdef UNIT_TEST
32 #include "IRsend_test.h"
33 #endif
34 #include "IRutils.h"
35 
36 // Constants
37 const uint16_t kSharpAcHdrMark = 3800;
38 const uint16_t kSharpAcHdrSpace = 1900;
39 const uint16_t kSharpAcBitMark = 470;
40 const uint16_t kSharpAcZeroSpace = 500;
41 const uint16_t kSharpAcOneSpace = 1400;
43 
44 // Byte[4]
45 const uint8_t kSharpAcModelBit = 4; // Mask 0b000x0000
46 const uint8_t kSharpAcByteTemp = 4;
47 const uint8_t kSharpAcMinTemp = 15; // Celsius
48 const uint8_t kSharpAcMaxTemp = 30; // Celsius
49 // Byte[5]
50 const uint8_t kSharpAcBytePowerSpecial = 5;
51 const uint8_t kSharpAcPowerSetSpecialOffset = kHighNibble; // 0bxxxx0000
52 const uint8_t kSharpAcPowerSpecialSize = kNibbleSize; // 0bxxxx0000
53 const uint8_t kSharpAcPowerUnknown = 0; // 0b0000
54 const uint8_t kSharpAcPowerOnFromOff = 1; // 0b0001
55 const uint8_t kSharpAcPowerOff = 2; // 0b0010
56 const uint8_t kSharpAcPowerOn = 3; // 0b0011 (Normal)
57 const uint8_t kSharpAcPowerSetSpecialOn = 6; // 0b0110
58 const uint8_t kSharpAcPowerSetSpecialOff = 7; // 0b0111
59 const uint8_t kSharpAcPowerTimerSetting = 8; // 0b1000
60 // Byte[6]
61 const uint8_t kSharpAcByteMode = 6;
62 const uint8_t kSharpAcModeSize = 2; // Mask 0b000000xx;
63 const uint8_t kSharpAcAuto = 0b00; // A907 only
64 const uint8_t kSharpAcFan = 0b00; // A705 only
65 const uint8_t kSharpAcDry = 0b11;
66 const uint8_t kSharpAcCool = 0b10;
67 const uint8_t kSharpAcHeat = 0b01; // A907 only
69 const uint8_t kSharpAcBitCleanOffset = 3; // Mask 0b0000x000
71 const uint8_t kSharpAcFanOffset = 4; // Mask 0b0xxx0000
72 const uint8_t kSharpAcFanSize = 3; // Nr. of Bits
73 const uint8_t kSharpAcFanAuto = 0b010; // 2
74 const uint8_t kSharpAcFanMin = 0b100; // 4 (FAN1)
75 const uint8_t kSharpAcFanMed = 0b011; // 3 (FAN2)
76 const uint8_t kSharpAcFanA705Low = 0b011; // 3
77 const uint8_t kSharpAcFanHigh = 0b101; // 5 (FAN3)
78 const uint8_t kSharpAcFanA705Med = 0b101; // 5
79 const uint8_t kSharpAcFanMax = 0b111; // 7 (FAN4)
80 // Byte[7]
81 const uint8_t kSharpAcByteTimer = 7;
82 const uint8_t kSharpAcTimerIncrement = 30; // Mins
84 const uint8_t kSharpAcTimerHoursSize = kNibbleSize; // Mask 0b0000xxxx
85 const uint8_t kSharpAcTimerHoursOff = 0b0000;
86 const uint8_t kSharpAcTimerHoursMax = 0b1100; // 12
87 const uint8_t kSharpAcBitTimerType = 6; // Mask 0b0x000000
88 const uint8_t kSharpAcOffTimerType = 0b0;
89 const uint8_t kSharpAcOnTimerType = 0b1;
90 const uint8_t kSharpAcBitTimerEnabled = 7; // Mask 0bx0000000
91 // Byte[8]
92 const uint8_t kSharpAcByteSwing = 8;
93 const uint8_t kSharpAcSwingOffset = 0;
94 const uint8_t kSharpAcSwingSize = 3; // Mask 0b00000xxx
95 const uint8_t kSharpAcSwingToggle = 0b111;
96 const uint8_t kSharpAcSwingNoToggle = 0b000;
97 // Byte[10]
98 const uint8_t kSharpAcByteSpecial = 10; // Mask 0bxxxxxxxx
99 const uint8_t kSharpAcSpecialPower = 0x00;
100 const uint8_t kSharpAcSpecialTurbo = 0x01;
101 const uint8_t kSharpAcSpecialTempEcono = 0x04;
102 const uint8_t kSharpAcSpecialFan = 0x05;
103 const uint8_t kSharpAcSpecialSwing = 0x06;
104 const uint8_t kSharpAcSpecialTimer = 0xC0;
105 const uint8_t kSharpAcSpecialTimerHalfHour = 0xDE;
106 // Byte[11]
107 const uint8_t kSharpAcByteIon = 11;
108 const uint8_t kSharpAcBitIonOffset = 2; // Mask 0b00000x00
109 // Byte[12] (Checksum)
110 
111 // Classes
113 class IRSharpAc {
114  public:
115  explicit IRSharpAc(const uint16_t pin, const bool inverted = false,
116  const bool use_modulation = true);
117 #if SEND_SHARP_AC
118  void send(const uint16_t repeat = kSharpAcDefaultRepeat);
123  int8_t calibrate(void) { return _irsend.calibrate(); }
124 #endif // SEND_SHARP_AC
125  void begin(void);
126  void setModel(const sharp_ac_remote_model_t model);
127  sharp_ac_remote_model_t getModel(const bool raw = false);
128  void on(void);
129  void off(void);
130  void setPower(const bool on, const bool prev_on = true);
131  bool getPower(void);
132  bool isPowerSpecial(void);
133  void setTemp(const uint8_t temp, const bool save = true);
134  uint8_t getTemp(void);
135  void setFan(const uint8_t fan, const bool save = true);
136  uint8_t getFan(void);
137  void setMode(const uint8_t mode, const bool save = true);
138  uint8_t getMode(void);
139  void setSpecial(const uint8_t mode);
140  uint8_t getSpecial(void);
141  bool getTurbo(void);
142  void setTurbo(const bool on);
143  bool getSwingToggle(void);
144  void setSwingToggle(const bool on);
145  bool getIon(void);
146  void setIon(const bool on);
147  bool getEconoToggle(void);
148  void setEconoToggle(const bool on);
149  bool getLightToggle(void);
150  void setLightToggle(const bool on);
151  uint16_t getTimerTime(void);
152  bool getTimerEnabled(void);
153  bool getTimerType(void);
154  void setTimer(bool enable, bool timer_type, uint16_t mins);
155  bool getClean(void);
156  void setClean(const bool on);
157  uint8_t* getRaw(void);
158  void setRaw(const uint8_t new_code[],
159  const uint16_t length = kSharpAcStateLength);
160  static bool validChecksum(uint8_t state[],
161  const uint16_t length = kSharpAcStateLength);
162  static uint8_t convertMode(const stdAc::opmode_t mode);
163  static uint8_t convertFan(const stdAc::fanspeed_t speed);
164  stdAc::opmode_t toCommonMode(const uint8_t mode);
165  stdAc::fanspeed_t toCommonFanSpeed(const uint8_t speed);
166  stdAc::state_t toCommon(void);
167  String toString(void);
168 #ifndef UNIT_TEST
169 
170  private:
172 #else // UNIT_TEST
173  IRsendTest _irsend;
175 #endif // UNIT_TEST
178  uint8_t _temp;
179  uint8_t _mode;
180  uint8_t _fan;
182  void stateReset(void);
183  void checksum(void);
184  static uint8_t calcChecksum(uint8_t state[],
185  const uint16_t length = kSharpAcStateLength);
186  void setPowerSpecial(const uint8_t value);
187  uint8_t getPowerSpecial(void);
188  void clearPowerSpecial(void);
189  bool _getEconoToggle(void);
190  void _setEconoToggle(const bool on);
191 };
192 
193 #endif // IR_SHARP_H_
IRSharpAc::getPowerSpecial
uint8_t getPowerSpecial(void)
Get the value of the Power Special setting.
Definition: ir_Sharp.cpp:351
kSharpAcTimerHoursSize
const uint8_t kSharpAcTimerHoursSize
Definition: ir_Sharp.h:84
kSharpAcByteFan
const uint8_t kSharpAcByteFan
Definition: ir_Sharp.h:70
kSharpAcFanSize
const uint8_t kSharpAcFanSize
Definition: ir_Sharp.h:72
kSharpAcHeat
const uint8_t kSharpAcHeat
Definition: ir_Sharp.h:67
kSharpAcSpecialTempEcono
const uint8_t kSharpAcSpecialTempEcono
Definition: ir_Sharp.h:101
IRSharpAc::getMode
uint8_t getMode(void)
Get the operating mode setting of the A/C.
Definition: ir_Sharp.cpp:459
IRSharpAc::calibrate
int8_t calibrate(void)
Run the calibration to calculate uSec timing offsets for this platform.
Definition: ir_Sharp.h:123
IRSharpAc::setTimer
void setTimer(bool enable, bool timer_type, uint16_t mins)
Set or cancel the timer function.
Definition: ir_Sharp.cpp:644
IRSharpAc::isPowerSpecial
bool isPowerSpecial(void)
Is one of the special power states in use?
Definition: ir_Sharp.cpp:364
IRSharpAc::setTemp
void setTemp(const uint8_t temp, const bool save=true)
Set the temperature.
Definition: ir_Sharp.cpp:425
kSharpAcPowerOnFromOff
const uint8_t kSharpAcPowerOnFromOff
Definition: ir_Sharp.h:54
kSharpAcPowerSpecialSize
const uint8_t kSharpAcPowerSpecialSize
Definition: ir_Sharp.h:52
IRSharpAc::off
void off(void)
Set the requested power state of the A/C to off.
Definition: ir_Sharp.cpp:377
kSharpAcOneSpace
const uint16_t kSharpAcOneSpace
Definition: ir_Sharp.h:41
stdAc::fanspeed_t
fanspeed_t
Common A/C settings for Fan Speeds.
Definition: IRsend.h:58
IRSharpAc::_temp
uint8_t _temp
Saved copy of the desired temp.
Definition: ir_Sharp.h:178
kDefaultMessageGap
const uint32_t kDefaultMessageGap
Definition: IRsend.h:41
IRSharpAc::calcChecksum
static uint8_t calcChecksum(uint8_t state[], const uint16_t length=kSharpAcStateLength)
Calculate the checksum for a given state.
Definition: ir_Sharp.cpp:264
IRSharpAc::toCommon
stdAc::state_t toCommon(void)
Convert the current internal state into its stdAc::state_t equivalent.
Definition: ir_Sharp.cpp:754
kSharpAcFanA705Low
const uint8_t kSharpAcFanA705Low
Definition: ir_Sharp.h:76
IRSharpAc::getIon
bool getIon(void)
Get the Ion (Filter) setting of the A/C.
Definition: ir_Sharp.cpp:559
kSharpAcSpecialTimer
const uint8_t kSharpAcSpecialTimer
Definition: ir_Sharp.h:104
kSharpAcOnTimerType
const uint8_t kSharpAcOnTimerType
Definition: ir_Sharp.h:89
IRSharpAc::getFan
uint8_t getFan(void)
Get the current fan speed setting.
Definition: ir_Sharp.cpp:520
kSharpAcCool
const uint8_t kSharpAcCool
Definition: ir_Sharp.h:66
IRsend.h
IRSharpAc::getPower
bool getPower(void)
Get the value of the current power setting.
Definition: ir_Sharp.cpp:392
kSharpAcSpecialFan
const uint8_t kSharpAcSpecialFan
Definition: ir_Sharp.h:102
kSharpAcSpecialSwing
const uint8_t kSharpAcSpecialSwing
Definition: ir_Sharp.h:103
kSharpAcOffTimerType
const uint8_t kSharpAcOffTimerType
Definition: ir_Sharp.h:88
IRsend
Class for sending all basic IR protocols.
Definition: IRsend.h:182
kSharpAcMaxTemp
const uint8_t kSharpAcMaxTemp
Definition: ir_Sharp.h:48
IRSharpAc::_getEconoToggle
bool _getEconoToggle(void)
Get the Economical mode toggle setting of the A/C.
Definition: ir_Sharp.cpp:574
IRSharpAc::setFan
void setFan(const uint8_t fan, const bool save=true)
Set the speed of the fan.
Definition: ir_Sharp.cpp:499
IRsend::calibrate
int8_t calibrate(uint16_t hz=38000U)
Calculate & set any offsets to account for execution times during sending.
Definition: IRsend.cpp:207
IRSharpAc::_model
sharp_ac_remote_model_t _model
Saved copy of the model.
Definition: ir_Sharp.h:181
IRSharpAc::IRSharpAc
IRSharpAc(const uint16_t pin, const bool inverted=false, const bool use_modulation=true)
Class constructor.
Definition: ir_Sharp.cpp:245
kSharpAcSwingOffset
const uint8_t kSharpAcSwingOffset
Definition: ir_Sharp.h:93
kSharpAcZeroSpace
const uint16_t kSharpAcZeroSpace
Definition: ir_Sharp.h:40
IRSharpAc::setPower
void setPower(const bool on, const bool prev_on=true)
Change the power setting, including the previous power state.
Definition: ir_Sharp.cpp:382
kSharpAcDry
const uint8_t kSharpAcDry
Definition: ir_Sharp.h:65
String
std::string String
Definition: IRremoteESP8266.h:1178
kNibbleSize
const uint8_t kNibbleSize
Definition: IRutils.h:17
kSharpAcTimerHoursMax
const uint8_t kSharpAcTimerHoursMax
Definition: ir_Sharp.h:86
kSharpAcPowerOff
const uint8_t kSharpAcPowerOff
Definition: ir_Sharp.h:55
IRSharpAc::getTimerTime
uint16_t getTimerTime(void)
Get how long the timer is set for, in minutes.
Definition: ir_Sharp.cpp:620
kLowNibble
const uint8_t kLowNibble
Definition: IRutils.h:18
IRSharpAc::getLightToggle
bool getLightToggle(void)
Get the Light toggle setting of the A/C.
Definition: ir_Sharp.cpp:614
kSharpAcSwingNoToggle
const uint8_t kSharpAcSwingNoToggle
Definition: ir_Sharp.h:96
kSharpAcTimerIncrement
const uint8_t kSharpAcTimerIncrement
Definition: ir_Sharp.h:82
IRremoteESP8266.h
kSharpAcPowerSetSpecialOn
const uint8_t kSharpAcPowerSetSpecialOn
Definition: ir_Sharp.h:57
IRSharpAc::convertMode
static uint8_t convertMode(const stdAc::opmode_t mode)
Convert a stdAc::opmode_t enum into its native mode.
Definition: ir_Sharp.cpp:688
IRSharpAc::setTurbo
void setTurbo(const bool on)
Set the Turbo setting of the A/C.
Definition: ir_Sharp.cpp:536
IRSharpAc::setModel
void setModel(const sharp_ac_remote_model_t model)
Set the model of the A/C to emulate.
Definition: ir_Sharp.cpp:315
IRSharpAc::validChecksum
static bool validChecksum(uint8_t state[], const uint16_t length=kSharpAcStateLength)
Verify the checksum is valid for a given state.
Definition: ir_Sharp.cpp:275
IRSharpAc::getSpecial
uint8_t getSpecial(void)
Get the value of the Special (button/command?) setting.
Definition: ir_Sharp.cpp:420
kSharpAcSpecialTimerHalfHour
const uint8_t kSharpAcSpecialTimerHalfHour
Definition: ir_Sharp.h:105
kSharpAcTimerHoursOff
const uint8_t kSharpAcTimerHoursOff
Definition: ir_Sharp.h:85
kSharpAcBitTimerEnabled
const uint8_t kSharpAcBitTimerEnabled
Definition: ir_Sharp.h:90
kSharpAcByteTimer
const uint8_t kSharpAcByteTimer
Definition: ir_Sharp.h:81
IRSharpAc::getModel
sharp_ac_remote_model_t getModel(const bool raw=false)
Get/Detect the model of the A/C.
Definition: ir_Sharp.cpp:332
IRSharpAc::getTemp
uint8_t getTemp(void)
Get the current temperature setting.
Definition: ir_Sharp.cpp:452
kHighNibble
const uint8_t kHighNibble
Definition: IRutils.h:19
kSharpAcByteSpecial
const uint8_t kSharpAcByteSpecial
Definition: ir_Sharp.h:98
kSharpAcSwingToggle
const uint8_t kSharpAcSwingToggle
Definition: ir_Sharp.h:95
IRSharpAc::setPowerSpecial
void setPowerSpecial(const uint8_t value)
Set the value of the Power Special setting without any checks.
Definition: ir_Sharp.cpp:344
kSharpAcFanAuto
const uint8_t kSharpAcFanAuto
Definition: ir_Sharp.h:73
IRSharpAc::send
void send(const uint16_t repeat=kSharpAcDefaultRepeat)
Send the current internal state as an IR message.
Definition: ir_Sharp.cpp:255
IRSharpAc::_irsend
IRsend _irsend
Instance of the IR send class.
Definition: ir_Sharp.h:171
IRSharpAc::checksum
void checksum(void)
Calculate and set the checksum values for the internal state.
Definition: ir_Sharp.cpp:281
kSharpAcGap
const uint32_t kSharpAcGap
Definition: ir_Sharp.h:42
kSharpAcBitTimerType
const uint8_t kSharpAcBitTimerType
Definition: ir_Sharp.h:87
IRSharpAc::getRaw
uint8_t * getRaw(void)
Get a PTR to the internal state/code for this protocol.
Definition: ir_Sharp.cpp:300
kSharpAcSwingSize
const uint8_t kSharpAcSwingSize
Definition: ir_Sharp.h:94
kSharpAcByteMode
const uint8_t kSharpAcByteMode
Definition: ir_Sharp.h:61
IRSharpAc::getTimerType
bool getTimerType(void)
Get the current timer type.
Definition: ir_Sharp.cpp:635
kSharpAcPowerUnknown
const uint8_t kSharpAcPowerUnknown
Definition: ir_Sharp.h:53
IRrecv.h
kSharpAcPowerOn
const uint8_t kSharpAcPowerOn
Definition: ir_Sharp.h:56
IRSharpAc::_setEconoToggle
void _setEconoToggle(const bool on)
Set the Economical mode toggle setting of the A/C.
Definition: ir_Sharp.cpp:583
IRSharpAc::setSpecial
void setSpecial(const uint8_t mode)
Set the value of the Special (button/command?) setting.
Definition: ir_Sharp.cpp:402
IRSharpAc::begin
void begin(void)
Set up hardware to be able to send a message.
Definition: ir_Sharp.cpp:250
kSharpAcByteClean
const uint8_t kSharpAcByteClean
Definition: ir_Sharp.h:68
kSharpAcStateLength
const uint16_t kSharpAcStateLength
Definition: IRremoteESP8266.h:1059
kSharpAcModeSize
const uint8_t kSharpAcModeSize
Definition: ir_Sharp.h:62
kSharpAcFanMax
const uint8_t kSharpAcFanMax
Definition: ir_Sharp.h:79
IRutils.h
IRSharpAc::_mode
uint8_t _mode
Saved copy of the desired mode.
Definition: ir_Sharp.h:179
kSharpAcBytePowerSpecial
const uint8_t kSharpAcBytePowerSpecial
Definition: ir_Sharp.h:50
IRSharpAc
Class for handling detailed Sharp A/C messages.
Definition: ir_Sharp.h:113
IRSharpAc::toCommonMode
stdAc::opmode_t toCommonMode(const uint8_t mode)
Convert a native mode into its stdAc equivalent.
Definition: ir_Sharp.cpp:715
IRSharpAc::getEconoToggle
bool getEconoToggle(void)
Get the Economical mode toggle setting of the A/C.
Definition: ir_Sharp.cpp:599
kSharpAcPowerTimerSetting
const uint8_t kSharpAcPowerTimerSetting
Definition: ir_Sharp.h:59
kSharpAcBitIonOffset
const uint8_t kSharpAcBitIonOffset
Definition: ir_Sharp.h:108
kSharpAcFanHigh
const uint8_t kSharpAcFanHigh
Definition: ir_Sharp.h:77
IRSharpAc::getSwingToggle
bool getSwingToggle(void)
Get the (vertical) Swing Toggle setting of the A/C.
Definition: ir_Sharp.cpp:544
kSharpAcFanMin
const uint8_t kSharpAcFanMin
Definition: ir_Sharp.h:74
kSharpAcByteSwing
const uint8_t kSharpAcByteSwing
Definition: ir_Sharp.h:92
IRSharpAc::setClean
void setClean(const bool on)
Set the Economical mode toggle setting of the A/C.
Definition: ir_Sharp.cpp:671
IRSharpAc::remote
uint8_t remote[kSharpAcStateLength]
State of the remote in IR code form.
Definition: ir_Sharp.h:177
kSharpAcFan
const uint8_t kSharpAcFan
Definition: ir_Sharp.h:64
kSharpAcFanMed
const uint8_t kSharpAcFanMed
Definition: ir_Sharp.h:75
kSharpAcDefaultRepeat
const uint16_t kSharpAcDefaultRepeat
Definition: IRremoteESP8266.h:1061
kSharpAcTimerHoursOffset
const uint8_t kSharpAcTimerHoursOffset
Definition: ir_Sharp.h:83
kSharpAcFanA705Med
const uint8_t kSharpAcFanA705Med
Definition: ir_Sharp.h:78
IRSharpAc::_fan
uint8_t _fan
Saved copy of the desired fan speed.
Definition: ir_Sharp.h:180
kSharpAcByteIon
const uint8_t kSharpAcByteIon
Definition: ir_Sharp.h:107
IRSharpAc::setEconoToggle
void setEconoToggle(const bool on)
Set the Economical mode toggle setting of the A/C.
Definition: ir_Sharp.cpp:592
kSharpAcModelBit
const uint8_t kSharpAcModelBit
Definition: ir_Sharp.h:45
kSharpAcFanOffset
const uint8_t kSharpAcFanOffset
Definition: ir_Sharp.h:71
IRSharpAc::getClean
bool getClean(void)
Get the Clean setting of the A/C.
Definition: ir_Sharp.cpp:664
kSharpAcHdrSpace
const uint16_t kSharpAcHdrSpace
Definition: ir_Sharp.h:38
IRSharpAc::getTurbo
bool getTurbo(void)
Get the Turbo setting of the A/C.
Definition: ir_Sharp.cpp:526
kSharpAcAuto
const uint8_t kSharpAcAuto
Definition: ir_Sharp.h:63
IRSharpAc::setLightToggle
void setLightToggle(const bool on)
Set the Light mode toggle setting of the A/C.
Definition: ir_Sharp.cpp:607
IRSharpAc::toCommonFanSpeed
stdAc::fanspeed_t toCommonFanSpeed(const uint8_t speed)
Convert a native fan speed into its stdAc equivalent.
Definition: ir_Sharp.cpp:733
IRSharpAc::setSwingToggle
void setSwingToggle(const bool on)
Set the (vertical) Swing Toggle setting of the A/C.
Definition: ir_Sharp.cpp:551
IRSharpAc::getTimerEnabled
bool getTimerEnabled(void)
Is the Timer enabled?
Definition: ir_Sharp.cpp:629
kSharpAcPowerSetSpecialOffset
const uint8_t kSharpAcPowerSetSpecialOffset
Definition: ir_Sharp.h:51
kSharpAcPowerSetSpecialOff
const uint8_t kSharpAcPowerSetSpecialOff
Definition: ir_Sharp.h:58
IRSharpAc::on
void on(void)
Set the requested power state of the A/C to on.
Definition: ir_Sharp.cpp:374
IRSharpAc::setMode
void setMode(const uint8_t mode, const bool save=true)
Set the operating mode of the A/C.
Definition: ir_Sharp.cpp:466
kSharpAcBitMark
const uint16_t kSharpAcBitMark
Definition: ir_Sharp.h:39
kSharpAcMinTemp
const uint8_t kSharpAcMinTemp
Definition: ir_Sharp.h:47
kSharpAcSpecialTurbo
const uint8_t kSharpAcSpecialTurbo
Definition: ir_Sharp.h:100
IRSharpAc::toString
String toString(void)
Convert the current internal state into a human readable string.
Definition: ir_Sharp.cpp:781
IRSharpAc::stateReset
void stateReset(void)
Reset the state of the remote to a known good state/sequence.
Definition: ir_Sharp.cpp:287
kSharpAcByteTemp
const uint8_t kSharpAcByteTemp
Definition: ir_Sharp.h:46
IRSharpAc::setIon
void setIon(const bool on)
Set the Ion (Filter) setting of the A/C.
Definition: ir_Sharp.cpp:565
stdAc::state_t
Structure to hold a common A/C state.
Definition: IRsend.h:97
IRSharpAc::clearPowerSpecial
void clearPowerSpecial(void)
Clear the "special"/non-normal bits in the power section. e.g. for normal/common command modes.
Definition: ir_Sharp.cpp:358
kSharpAcHdrMark
const uint16_t kSharpAcHdrMark
Definition: ir_Sharp.h:37
IRSharpAc::setRaw
void setRaw(const uint8_t new_code[], const uint16_t length=kSharpAcStateLength)
Set the internal state from a valid code for this protocol.
Definition: ir_Sharp.cpp:308
kSharpAcSpecialPower
const uint8_t kSharpAcSpecialPower
Definition: ir_Sharp.h:99
kSharpAcBitCleanOffset
const uint8_t kSharpAcBitCleanOffset
Definition: ir_Sharp.h:69
sharp_ac_remote_model_t
sharp_ac_remote_model_t
Sharp A/C model numbers.
Definition: IRsend.h:152
stdAc::opmode_t
opmode_t
Common A/C settings for A/C operating modes.
Definition: IRsend.h:46
IRSharpAc::convertFan
static uint8_t convertFan(const stdAc::fanspeed_t speed)
Convert a stdAc::fanspeed_t enum into it's native speed.
Definition: ir_Sharp.cpp:701