mirror of
https://github.com/DarkFlippers/unleashed-firmware
synced 2024-11-26 22:40:25 +00:00
SubGhz: add protocol Nice_Flo 20bit (#1983)
Co-authored-by: あく <alleteam@gmail.com>
This commit is contained in:
parent
41de5f3c52
commit
cf5b87f82e
1 changed files with 6 additions and 6 deletions
|
@ -138,9 +138,9 @@ bool subghz_protocol_encoder_nice_flo_deserialize(void* context, FlipperFormat*
|
||||||
FURI_LOG_E(TAG, "Deserialize error");
|
FURI_LOG_E(TAG, "Deserialize error");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if((instance->generic.data_count_bit !=
|
if((instance->generic.data_count_bit <
|
||||||
subghz_protocol_nice_flo_const.min_count_bit_for_found) &&
|
subghz_protocol_nice_flo_const.min_count_bit_for_found) ||
|
||||||
(instance->generic.data_count_bit !=
|
(instance->generic.data_count_bit >
|
||||||
2 * subghz_protocol_nice_flo_const.min_count_bit_for_found)) {
|
2 * subghz_protocol_nice_flo_const.min_count_bit_for_found)) {
|
||||||
FURI_LOG_E(TAG, "Wrong number of bits in key");
|
FURI_LOG_E(TAG, "Wrong number of bits in key");
|
||||||
break;
|
break;
|
||||||
|
@ -297,9 +297,9 @@ bool subghz_protocol_decoder_nice_flo_deserialize(void* context, FlipperFormat*
|
||||||
if(!subghz_block_generic_deserialize(&instance->generic, flipper_format)) {
|
if(!subghz_block_generic_deserialize(&instance->generic, flipper_format)) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if((instance->generic.data_count_bit !=
|
if((instance->generic.data_count_bit <
|
||||||
subghz_protocol_nice_flo_const.min_count_bit_for_found) &&
|
subghz_protocol_nice_flo_const.min_count_bit_for_found) ||
|
||||||
(instance->generic.data_count_bit !=
|
(instance->generic.data_count_bit >
|
||||||
2 * subghz_protocol_nice_flo_const.min_count_bit_for_found)) {
|
2 * subghz_protocol_nice_flo_const.min_count_bit_for_found)) {
|
||||||
FURI_LOG_E(TAG, "Wrong number of bits in key");
|
FURI_LOG_E(TAG, "Wrong number of bits in key");
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in a new issue