# IRremoteESP8266: src/ir_NEC.h Source File

ir_NEC.h
Go to the documentation of this file.
// Copyright 2009 Ken Shirriff
// Copyright 2017, 2018 David Conran
// Supports:
// Brand: Yamaha, Model: RAV561 remote
// Brand: Yamaha, Model: RXV585B A/V Receiver
// Brand: Aloka, Model: SleepyLights LED Lamp
// Brand: Toshiba, Model: 42TL838 LCD TV
// Brand: Duux, Model: Blizzard Smart 10K / DXMA04 A/C
// Brand: Duux, Model: YJ-A081 TR Remote
// Brand: Silan Microelectronics, Model: SC6121-001 IC
#ifndef IR_NEC_H_
#define IR_NEC_H_
#include <stdint.h>
#include "IRremoteESP8266.h"
// Constants
const uint16_t kNecTick = 560;
const uint16_t kNecHdrMarkTicks = 16;
const uint16_t kNecHdrMark = kNecHdrMarkTicks * kNecTick;
const uint16_t kNecHdrSpaceTicks = 8;
const uint16_t kNecHdrSpace = kNecHdrSpaceTicks * kNecTick;
const uint16_t kNecBitMarkTicks = 1;
const uint16_t kNecBitMark = kNecBitMarkTicks * kNecTick;
const uint16_t kNecOneSpaceTicks = 3;
const uint16_t kNecOneSpace = kNecOneSpaceTicks * kNecTick;
const uint16_t kNecZeroSpaceTicks = 1;
const uint16_t kNecZeroSpace = kNecZeroSpaceTicks * kNecTick;
const uint16_t kNecRptSpaceTicks = 4;
const uint16_t kNecRptSpace = kNecRptSpaceTicks * kNecTick;
const uint16_t kNecRptLength = 4;
const uint16_t kNecMinCommandLengthTicks = 193;
const uint32_t kNecMinCommandLength = kNecMinCommandLengthTicks * kNecTick;
const uint32_t kNecMinGap =
kNecMinCommandLength -
(kNecHdrMark + kNecHdrSpace + kNECBits * (kNecBitMark + kNecOneSpace) +
kNecBitMark);
const uint16_t kNecMinGapTicks =
kNecMinCommandLengthTicks -
(kNecHdrMarkTicks + kNecHdrSpaceTicks +
kNECBits * (kNecBitMarkTicks + kNecOneSpaceTicks) + kNecBitMarkTicks);
// IR codes and structure for kids ALOKA SleepyLights LED Lamp.
// https://aloka-designs.com/
// Ref: https://github.com/crankyoldgit/IRremoteESP8266/issues/1004
//
// May be useful for someone wanting to control the lamp.
//
// The lamp is toggled On and Off with the same power button.
// The colour, when selected, is the brightest and there are 4 levels of
// brightness that decrease on each send of the colour. A fifth send of the
// colour resets to brightest again.
//
// Remote buttons defined left to right, top line to bottom line on the remote.
const uint32_t kAlokaPower = 0xFF609F;
const uint32_t kAlokaLedWhite = 0xFF906F;
const uint32_t kAlokaLedGreen = 0xFF9867;
const uint32_t kAlokaLedBlue = 0xFFD827;
const uint32_t kAlokaLedPinkRed = 0xFF8877;
const uint32_t kAlokaLedRed = 0xFFA857;
const uint32_t kAlokaLedLightGreen = 0xFFE817;
const uint32_t kAlokaLedMidBlue = 0xFF48B7;
const uint32_t kAlokaLedPink = 0xFF6897;
const uint32_t kAlokaLedOrange = 0xFFB24D;
const uint32_t kAlokaLedYellow = 0xFF00FF;
const uint32_t kAlokaNightFade = 0xFF50AF;
const uint32_t kAlokaNightTimer = 0xFF7887;
const uint32_t kAlokaLedRainbow = 0xFF708F;
// Didn't have a better description for it...
const uint32_t kAlokaLedTreeGrow = 0xFF58A7;
#endif // IR_NEC_H_
kAlokaLedWhite
const uint32_t kAlokaLedWhite
Definition: ir_NEC.h:63
kNecBitMarkTicks
const uint16_t kNecBitMarkTicks
Definition: ir_NEC.h:30
kNecHdrSpace
const uint16_t kNecHdrSpace
Definition: ir_NEC.h:29
kNecBitMark
const uint16_t kNecBitMark
Definition: ir_NEC.h:31
kNecMinCommandLength
const uint32_t kNecMinCommandLength
Definition: ir_NEC.h:40
kNecZeroSpaceTicks
const uint16_t kNecZeroSpaceTicks
Definition: ir_NEC.h:34
kAlokaLedBlue
const uint32_t kAlokaLedBlue
Definition: ir_NEC.h:65
kAlokaLedLightGreen
const uint32_t kAlokaLedLightGreen
Definition: ir_NEC.h:68
kNecOneSpace
const uint16_t kNecOneSpace
Definition: ir_NEC.h:33
kAlokaNightTimer
const uint32_t kAlokaNightTimer
Definition: ir_NEC.h:74
kNecMinCommandLengthTicks
const uint16_t kNecMinCommandLengthTicks
Definition: ir_NEC.h:39
kNecZeroSpace
const uint16_t kNecZeroSpace
Definition: ir_NEC.h:35
kNecOneSpaceTicks
const uint16_t kNecOneSpaceTicks
Definition: ir_NEC.h:32
kNecRptSpace
const uint16_t kNecRptSpace
Definition: ir_NEC.h:37
kNecHdrMarkTicks
const uint16_t kNecHdrMarkTicks
Definition: ir_NEC.h:26
kAlokaNightFade
const uint32_t kAlokaNightFade
Definition: ir_NEC.h:73
IRremoteESP8266.h
kNecRptLength
const uint16_t kNecRptLength
Definition: ir_NEC.h:38
kAlokaLedPink
const uint32_t kAlokaLedPink
Definition: ir_NEC.h:70
kNecMinGapTicks
const uint16_t kNecMinGapTicks
Definition: ir_NEC.h:45
kAlokaLedPinkRed
const uint32_t kAlokaLedPinkRed
Definition: ir_NEC.h:66
kNECBits
const uint16_t kNECBits
Definition: IRremoteESP8266.h:1022
kAlokaLedRed
const uint32_t kAlokaLedRed
Definition: ir_NEC.h:67
kAlokaLedTreeGrow
const uint32_t kAlokaLedTreeGrow
Definition: ir_NEC.h:77
kNecHdrMark
const uint16_t kNecHdrMark
Definition: ir_NEC.h:27
kNecRptSpaceTicks
const uint16_t kNecRptSpaceTicks
Definition: ir_NEC.h:36
kAlokaLedOrange
const uint32_t kAlokaLedOrange
Definition: ir_NEC.h:71
kNecMinGap
const uint32_t kNecMinGap
Definition: ir_NEC.h:41
kAlokaPower
const uint32_t kAlokaPower
Definition: ir_NEC.h:62
kAlokaLedMidBlue
const uint32_t kAlokaLedMidBlue
Definition: ir_NEC.h:69
kAlokaLedRainbow
const uint32_t kAlokaLedRainbow
Definition: ir_NEC.h:75
kAlokaLedYellow
const uint32_t kAlokaLedYellow
Definition: ir_NEC.h:72
kNecHdrSpaceTicks
const uint16_t kNecHdrSpaceTicks
Definition: ir_NEC.h:28
kNecTick
const uint16_t kNecTick
Definition: ir_NEC.h:25
kAlokaLedGreen
const uint32_t kAlokaLedGreen
Definition: ir_NEC.h:64