mirror of
https://github.com/Show-maket/IR-protocol.git
synced 2025-05-04 07:10:16 +00:00
loop1 test
This commit is contained in:
parent
5efa3d3ba5
commit
01e2da6334
@ -22,6 +22,7 @@
|
|||||||
#define dec15_PIN 15
|
#define dec15_PIN 15
|
||||||
|
|
||||||
#define LoopOut 16
|
#define LoopOut 16
|
||||||
|
#define LoopOut1 17
|
||||||
|
|
||||||
#define dec_ISR(n) \
|
#define dec_ISR(n) \
|
||||||
void dec_##n##_ISR() { dec##n.isr(); }
|
void dec_##n##_ISR() { dec##n.isr(); }
|
||||||
@ -204,6 +205,7 @@ bool TimerISRHandler(struct repeating_timer *t){
|
|||||||
|
|
||||||
void setup()
|
void setup()
|
||||||
{
|
{
|
||||||
|
pinMode(LoopOut1, OUTPUT);
|
||||||
add_repeating_timer_us(6, TimerISRHandler, NULL, &timer);
|
add_repeating_timer_us(6, TimerISRHandler, NULL, &timer);
|
||||||
|
|
||||||
// IR_Timer.setOverflow(carrierFrec * 2, HERTZ_FORMAT);
|
// IR_Timer.setOverflow(carrierFrec * 2, HERTZ_FORMAT);
|
||||||
@ -262,8 +264,14 @@ void setup()
|
|||||||
void loop()
|
void loop()
|
||||||
{
|
{
|
||||||
digitalToggle(LoopOut);
|
digitalToggle(LoopOut);
|
||||||
Timer::tick();
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
void loop1()
|
||||||
|
{
|
||||||
|
Timer::tick();
|
||||||
IR_Decoder::tick();
|
IR_Decoder::tick();
|
||||||
|
|
||||||
bool rx_flag;
|
bool rx_flag;
|
||||||
@ -310,7 +318,18 @@ void loop()
|
|||||||
}
|
}
|
||||||
Serial.println(in);
|
Serial.println(in);
|
||||||
}
|
}
|
||||||
|
digitalToggle(LoopOut1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Timer statusSimpleDelay;
|
Timer statusSimpleDelay;
|
||||||
bool statusSimple(IR_Decoder &dec)
|
bool statusSimple(IR_Decoder &dec)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user