From 5a8a0dff5e9db128c7096ae076183b69a02f6f06 Mon Sep 17 00:00:00 2001 From: MX <10697207+xMasterX@users.noreply.github.com> Date: Tue, 30 Sep 2025 02:54:11 +0300 Subject: [PATCH] if got no luck with seed set it back to zero --- lib/subghz/protocols/keeloq.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/subghz/protocols/keeloq.c b/lib/subghz/protocols/keeloq.c index 921c3fadc..e9542eb34 100644 --- a/lib/subghz/protocols/keeloq.c +++ b/lib/subghz/protocols/keeloq.c @@ -858,9 +858,11 @@ static uint8_t subghz_protocol_keeloq_check_remote_controller_selector( } break; case KEELOQ_LEARNING_SECURE: + bool reset_seed_back = false; if((strcmp(furi_string_get_cstr(manufacture_code->name), "BFT") == 0)) { if(instance->seed == 0) { instance->seed = (fix & 0xFFFFFFF); + reset_seed_back = true; } } man = subghz_protocol_keeloq_common_secure_learning( @@ -870,6 +872,8 @@ static uint8_t subghz_protocol_keeloq_check_remote_controller_selector( *manufacture_name = furi_string_get_cstr(manufacture_code->name); keystore->mfname = *manufacture_name; return 1; + } else { + if(reset_seed_back) instance->seed = 0; } break; case KEELOQ_LEARNING_MAGIC_XOR_TYPE_1: