Skip to content

Commit

Permalink
Unused constants warning fixes.
Browse files Browse the repository at this point in the history
  • Loading branch information
danielwallner committed Feb 25, 2024
1 parent 3778191 commit 48d7433
Show file tree
Hide file tree
Showing 11 changed files with 23 additions and 19 deletions.
2 changes: 1 addition & 1 deletion src/ir_Airwell.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const uint8_t kAirwellOverhead = 4;
const uint16_t kAirwellHalfClockPeriod = 950; // uSeconds
const uint16_t kAirwellHdrMark = 3 * kAirwellHalfClockPeriod; // uSeconds
const uint16_t kAirwellHdrSpace = 3 * kAirwellHalfClockPeriod; // uSeconds
const uint16_t kAirwellFooterMark = 5 * kAirwellHalfClockPeriod; // uSeconds
//const uint16_t kAirwellFooterMark = 5 * kAirwellHalfClockPeriod; // uSeconds

using irutils::addBoolToString;
using irutils::addModeToString;
Expand Down
4 changes: 2 additions & 2 deletions src/ir_Carrier.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ const uint16_t kCarrierAc84HdrMark = 5850;
const uint16_t kCarrierAc84Zero = 1175;
const uint16_t kCarrierAc84One = 430;
const uint16_t kCarrierAc84HdrSpace = kCarrierAc84Zero;
const uint32_t kCarrierAc84Gap = kDefaultMessageGap; // A guess.
//const uint32_t kCarrierAc84Gap = kDefaultMessageGap; // A guess.
const uint8_t kCarrierAc84ExtraBits = 4;
const uint8_t kCarrierAc84ExtraTolerance = 5;

Expand All @@ -64,7 +64,7 @@ const uint16_t kCarrierAc128OneSpace = 1000;
const uint16_t kCarrierAc128ZeroSpace = 400;
const uint16_t kCarrierAc128SectionGap = 20600;
const uint16_t kCarrierAc128InterSpace = 6700;
const uint16_t kCarrierAc128SectionBits = kCarrierAc128Bits / 2;
//const uint16_t kCarrierAc128SectionBits = kCarrierAc128Bits / 2;

#if SEND_CARRIER_AC
/// Send a Carrier HVAC formatted message.
Expand Down
8 changes: 4 additions & 4 deletions src/ir_Denon.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,13 @@ const uint16_t kDenonOneSpaceTicks = 7;
const uint16_t kDenonOneSpace = kDenonOneSpaceTicks * kDenonTick;
const uint16_t kDenonZeroSpaceTicks = 3;
const uint16_t kDenonZeroSpace = kDenonZeroSpaceTicks * kDenonTick;
const uint16_t kDenonMinCommandLengthTicks = 510;
const uint16_t kDenonMinGapTicks =
//const uint16_t kDenonMinCommandLengthTicks = 510;
/*const uint16_t kDenonMinGapTicks =
kDenonMinCommandLengthTicks -
(kDenonHdrMarkTicks + kDenonHdrSpaceTicks +
kDenonBits * (kDenonBitMarkTicks + kDenonOneSpaceTicks) +
kDenonBitMarkTicks);
const uint32_t kDenonMinGap = kDenonMinGapTicks * kDenonTick;
kDenonBitMarkTicks);*/
//const uint32_t kDenonMinGap = kDenonMinGapTicks * kDenonTick;
const uint64_t kDenonManufacturer = 0x2A4CULL;

#if SEND_DENON
Expand Down
2 changes: 2 additions & 0 deletions src/ir_Doshisha.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ const uint64_t kRcz01Signature = 0x800B304800;
const uint8_t kRcz01CommandMask = 0xFE;
const uint8_t kRcz01ChannelMask = 0x01;

#ifndef UNIT_TEST
// Known commands - Here for documentation rather than actual usage
const uint8_t kRcz01CommandSwitchChannel = 0xD2;
const uint8_t kRcz01CommandTimmer60 = 0x52;
Expand All @@ -43,6 +44,7 @@ const uint8_t kRcz01CommandLevel4 = 0xD0;
const uint8_t kRcz01CommandOn = 0xC0;
const uint8_t kRcz01CommandNightLight = 0xC8;
// end Known commands
#endif

#if SEND_DOSHISHA
/// Send a Doshisha formatted message.
Expand Down
2 changes: 1 addition & 1 deletion src/ir_Inax.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
#include "IRutils.h"

// Constants
const uint16_t kInaxTick = 500;
//const uint16_t kInaxTick = 500;
const uint16_t kInaxHdrMark = 9000;
const uint16_t kInaxHdrSpace = 4500;
const uint16_t kInaxBitMark = 560;
Expand Down
2 changes: 1 addition & 1 deletion src/ir_Pioneer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@

// Constants
// Ref: https://github.com/crankyoldgit/IRremoteESP8266/issues/1220
const uint16_t kPioneerTick = 534; ///< uSeconds.
//const uint16_t kPioneerTick = 534; ///< uSeconds.
const uint16_t kPioneerHdrMark = 8506; ///< uSeconds.
const uint16_t kPioneerHdrSpace = 4191; ///< uSeconds.
const uint16_t kPioneerBitMark = 568; ///< uSeconds.
Expand Down
4 changes: 2 additions & 2 deletions src/ir_RCMM.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
#include "IRutils.h"

// Constants
const uint16_t kRcmmTick = 28; // Technically it would be 27.777*
//const uint16_t kRcmmTick = 28; // Technically it would be 27.777*
const uint16_t kRcmmHdrMarkTicks = 15;
const uint16_t kRcmmHdrMark = 416;
const uint16_t kRcmmHdrSpaceTicks = 10;
Expand All @@ -29,7 +29,7 @@ const uint16_t kRcmmBitSpace2Ticks = 22;
const uint16_t kRcmmBitSpace2 = 611;
const uint16_t kRcmmBitSpace3Ticks = 28;
const uint16_t kRcmmBitSpace3 = 777;
const uint16_t kRcmmRptLengthTicks = 992;
//const uint16_t kRcmmRptLengthTicks = 992;
const uint32_t kRcmmRptLength = 27778;
const uint16_t kRcmmMinGapTicks = 120;
const uint32_t kRcmmMinGap = 3360;
Expand Down
6 changes: 3 additions & 3 deletions src/ir_Samsung.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ const uint16_t kSamsungOneSpaceTicks = 3;
const uint16_t kSamsungOneSpace = kSamsungOneSpaceTicks * kSamsungTick;
const uint16_t kSamsungZeroSpaceTicks = 1;
const uint16_t kSamsungZeroSpace = kSamsungZeroSpaceTicks * kSamsungTick;
const uint16_t kSamsungRptSpaceTicks = 4;
const uint16_t kSamsungRptSpace = kSamsungRptSpaceTicks * kSamsungTick;
//const uint16_t kSamsungRptSpaceTicks = 4;
//const uint16_t kSamsungRptSpace = kSamsungRptSpaceTicks * kSamsungTick;
const uint16_t kSamsungMinMessageLengthTicks = 193;
const uint32_t kSamsungMinMessageLength =
kSamsungMinMessageLengthTicks * kSamsungTick;
Expand All @@ -46,7 +46,7 @@ const uint32_t kSamsungMinGap = kSamsungMinGapTicks * kSamsungTick;

const uint16_t kSamsungAcHdrMark = 690;
const uint16_t kSamsungAcHdrSpace = 17844;
const uint8_t kSamsungAcSections = 2;
//const uint8_t kSamsungAcSections = 2;
const uint16_t kSamsungAcSectionMark = 3086;
const uint16_t kSamsungAcSectionSpace = 8864;
const uint16_t kSamsungAcSectionGap = 2886;
Expand Down
8 changes: 4 additions & 4 deletions src/ir_Sanyo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,18 +35,18 @@ using irutils::sumNibbles;

// Constants
// Sanyo SA 8650B
const uint16_t kSanyoSa8650bHdrMark = 3500; // seen range 3500
/*const uint16_t kSanyoSa8650bHdrMark = 3500; // seen range 3500
const uint16_t kSanyoSa8650bHdrSpace = 950; // seen 950
const uint16_t kSanyoSa8650bOneMark = 2400; // seen 2400
const uint16_t kSanyoSa8650bZeroMark = 700; // seen 700
// usually see 713 - not using ticks as get number wrapround
const uint16_t kSanyoSa8650bDoubleSpaceUsecs = 800;
const uint16_t kSanyoSa8650bRptLength = 45000;
const uint16_t kSanyoSa8650bRptLength = 45000;*/

// Sanyo LC7461
const uint16_t kSanyoLc7461AddressMask = (1 << kSanyoLC7461AddressBits) - 1;
const uint16_t kSanyoLc7461CommandMask = (1 << kSanyoLC7461CommandBits) - 1;
const uint16_t kSanyoLc7461HdrMark = 9000;
/*const uint16_t kSanyoLc7461HdrMark = 9000;
const uint16_t kSanyoLc7461HdrSpace = 4500;
const uint16_t kSanyoLc7461BitMark = 560; // 1T
const uint16_t kSanyoLc7461OneSpace = 1690; // 3T
Expand All @@ -58,7 +58,7 @@ const uint16_t kSanyoLc7461MinGap =
(kSanyoLc7461HdrMark + kSanyoLc7461HdrSpace +
kSanyoLC7461Bits * (kSanyoLc7461BitMark +
(kSanyoLc7461OneSpace + kSanyoLc7461ZeroSpace) / 2) +
kSanyoLc7461BitMark);
kSanyoLc7461BitMark);*/

const uint16_t kSanyoAcHdrMark = 8500; ///< uSeconds
const uint16_t kSanyoAcHdrSpace = 4200; ///< uSeconds
Expand Down
2 changes: 1 addition & 1 deletion src/ir_Toto.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ const uint16_t kTotoBitMark = 600;
const uint16_t kTotoOneSpace = 1634;
const uint16_t kTotoZeroSpace = 516;
const uint16_t kTotoGap = 38000;
const uint16_t kTotoSpecialGap = 42482;
//const uint16_t kTotoSpecialGap = 42482;
const uint64_t kTotoPrefix = 0x0802;
const uint16_t kTotoPrefixBits = 15;

Expand Down
2 changes: 2 additions & 0 deletions src/ir_Zepeal.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,14 @@ const uint8_t kZepealTolerance = 40;
// but might need change (removal) if more devices are detected
const uint8_t kZepealSignature = 0x6C;

#ifndef UNIT_TEST
// Known Zepeal DRT-A3311(BG) Buttons - documentation rather than actual usage
const uint16_t kZepealCommandSpeed = 0x6C82;
const uint16_t kZepealCommandOffOn = 0x6C81;
const uint16_t kZepealCommandRhythm = 0x6C84;
const uint16_t kZepealCommandOffTimer = 0x6C88;
const uint16_t kZepealCommandOnTimer = 0x6CC3;
#endif

#if SEND_ZEPEAL
/// Send a Zepeal formatted message.
Expand Down

0 comments on commit 48d7433

Please sign in to comment.