[FL-1684] IRDA Add SIRC protocol (#693)

* IRDA HAL: Fill buffer refactoring
* IRDA: Add SIRC protocol
* IRDA: correct adr/cmd bit length
* Disable Unit tests

Co-authored-by: あく <alleteam@gmail.com>
This commit is contained in:
Albert Kharisov
2021-09-10 00:37:32 +03:00
committed by GitHub
parent 9bce160ca6
commit fbccb9fbaf
36 changed files with 1216 additions and 223 deletions

View File

@@ -39,11 +39,11 @@ IrdaStatus irda_decoder_samsung32_decode_repeat(IrdaCommonDecoder* decoder) {
if ((decoder->timings[0] > IRDA_SAMSUNG_REPEAT_PAUSE_MIN)
&& (decoder->timings[0] < IRDA_SAMSUNG_REPEAT_PAUSE_MAX)
&& MATCH_PREAMBLE_TIMING(decoder->timings[1], IRDA_SAMSUNG_REPEAT_MARK, preamble_tolerance)
&& MATCH_PREAMBLE_TIMING(decoder->timings[2], IRDA_SAMSUNG_REPEAT_SPACE, preamble_tolerance)
&& MATCH_BIT_TIMING(decoder->timings[3], decoder->protocol->timings.bit1_mark, bit_tolerance)
&& MATCH_BIT_TIMING(decoder->timings[4], decoder->protocol->timings.bit1_space, bit_tolerance)
&& MATCH_BIT_TIMING(decoder->timings[5], decoder->protocol->timings.bit1_mark, bit_tolerance)
&& MATCH_TIMING(decoder->timings[1], IRDA_SAMSUNG_REPEAT_MARK, preamble_tolerance)
&& MATCH_TIMING(decoder->timings[2], IRDA_SAMSUNG_REPEAT_SPACE, preamble_tolerance)
&& MATCH_TIMING(decoder->timings[3], decoder->protocol->timings.bit1_mark, bit_tolerance)
&& MATCH_TIMING(decoder->timings[4], decoder->protocol->timings.bit1_space, bit_tolerance)
&& MATCH_TIMING(decoder->timings[5], decoder->protocol->timings.bit1_mark, bit_tolerance)
) {
status = IrdaStatusReady;
decoder->timings_cnt = 0;

View File

@@ -3,8 +3,8 @@
static const IrdaProtocolSpecification irda_samsung32_protocol_specification = {
.name = "Samsung32",
.address_length = 2,
.command_length = 2,
.address_length = 8,
.command_length = 8,
.frequency = IRDA_COMMON_CARRIER_FREQUENCY,
.duty_cycle = IRDA_COMMON_DUTY_CYCLE,
};