Lines Matching refs:NEC_UNIT
11 #define NEC_UNIT 563 /* us */ macro
12 #define NEC_HEADER_PULSE (16 * NEC_UNIT)
13 #define NECX_HEADER_PULSE (8 * NEC_UNIT) /* Less common NEC variant */
14 #define NEC_HEADER_SPACE (8 * NEC_UNIT)
15 #define NEC_REPEAT_SPACE (4 * NEC_UNIT)
16 #define NEC_BIT_PULSE (1 * NEC_UNIT)
17 #define NEC_BIT_0_SPACE (1 * NEC_UNIT)
18 #define NEC_BIT_1_SPACE (3 * NEC_UNIT)
19 #define NEC_TRAILER_PULSE (1 * NEC_UNIT)
20 #define NEC_TRAILER_SPACE (10 * NEC_UNIT) /* even longer in reality */
61 if (eq_margin(ev.duration, NEC_HEADER_PULSE, NEC_UNIT * 2)) { in ir_nec_decode()
64 } else if (eq_margin(ev.duration, NECX_HEADER_PULSE, NEC_UNIT / 2)) in ir_nec_decode()
77 if (eq_margin(ev.duration, NEC_HEADER_SPACE, NEC_UNIT)) { in ir_nec_decode()
80 } else if (eq_margin(ev.duration, NEC_REPEAT_SPACE, NEC_UNIT / 2)) { in ir_nec_decode()
91 if (!eq_margin(ev.duration, NEC_BIT_PULSE, NEC_UNIT / 2)) in ir_nec_decode()
102 geq_margin(ev.duration, NEC_TRAILER_SPACE, NEC_UNIT / 2)) { in ir_nec_decode()
111 if (eq_margin(ev.duration, NEC_BIT_1_SPACE, NEC_UNIT / 2)) in ir_nec_decode()
113 else if (!eq_margin(ev.duration, NEC_BIT_0_SPACE, NEC_UNIT / 2)) in ir_nec_decode()
128 if (!eq_margin(ev.duration, NEC_TRAILER_PULSE, NEC_UNIT / 2)) in ir_nec_decode()
138 if (!geq_margin(ev.duration, NEC_TRAILER_SPACE, NEC_UNIT / 2)) in ir_nec_decode()