From 97302f7f7954e9e09f52a3597b94fea837acdf43 Mon Sep 17 00:00:00 2001 From: MX <10697207+xMasterX@users.noreply.github.com> Date: Thu, 12 Feb 2026 21:02:09 +0300 Subject: [PATCH] fix missing check --- scenes/protopirate_scene_receiver_config.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/scenes/protopirate_scene_receiver_config.c b/scenes/protopirate_scene_receiver_config.c index d88a8a6..72bc8d3 100644 --- a/scenes/protopirate_scene_receiver_config.c +++ b/scenes/protopirate_scene_receiver_config.c @@ -5,7 +5,9 @@ enum ProtoPirateSettingIndex { ProtoPirateSettingIndexFrequency, ProtoPirateSettingIndexHopping, ProtoPirateSettingIndexModulation, +#ifdef ENABLE_EMULATE_FEATURE ProtoPirateSettingIndexTXPower, +#endif ProtoPirateSettingIndexAutoSave, ProtoPirateSettingIndexLock, }; @@ -27,6 +29,7 @@ const char* const auto_save_text[AUTO_SAVE_COUNT] = { "ON", }; +#ifdef ENABLE_EMULATE_FEATURE #define TX_POWER_COUNT 9 const char* const tx_power_text[TX_POWER_COUNT] = { "Preset", @@ -39,6 +42,7 @@ const char* const tx_power_text[TX_POWER_COUNT] = { "-20dBm", "-30dBm", }; +#endif uint8_t protopirate_scene_receiver_config_next_frequency(const uint32_t value, void* context) { furi_check(context); @@ -165,6 +169,7 @@ static void protopirate_scene_receiver_config_set_auto_save(VariableItem* item) variable_item_set_current_value_text(item, auto_save_text[index]); } +#ifdef ENABLE_EMULATE_FEATURE static void protopirate_scene_receiver_config_set_tx_power(VariableItem* item) { ProtoPirateApp* app = variable_item_get_context(item); uint8_t index = variable_item_get_current_value_index(item); @@ -172,6 +177,7 @@ static void protopirate_scene_receiver_config_set_tx_power(VariableItem* item) { app->tx_power = index; variable_item_set_current_value_text(item, tx_power_text[index]); } +#endif static void protopirate_scene_receiver_config_var_list_enter_callback(void* context, uint32_t index) { @@ -231,6 +237,7 @@ void protopirate_scene_receiver_config_on_enter(void* context) { variable_item_set_current_value_text( item, subghz_setting_get_preset_name(app->setting, value_index)); +#ifdef ENABLE_EMULATE_FEATURE // TX power option item = variable_item_list_add( app->variable_item_list, @@ -240,7 +247,7 @@ void protopirate_scene_receiver_config_on_enter(void* context) { app); variable_item_set_current_value_index(item, app->tx_power); variable_item_set_current_value_text(item, tx_power_text[app->tx_power]); - +#endif // Auto-save option item = variable_item_list_add( app->variable_item_list,