vad7 2 年之前
父节点
当前提交
8e80d21be3
共有 2 个文件被更改,包括 6 次插入3 次删除
  1. 1 1
      application.fam
  2. 5 2
      nrf24scan.c

+ 1 - 1
application.fam

@@ -1,5 +1,5 @@
 App(
 App(
-    appid="Nrf24_Scanner",
+    appid="nrf24_scanner",
     name="[NRF24] Scanner",
     name="[NRF24] Scanner",
     apptype=FlipperAppType.EXTERNAL,
     apptype=FlipperAppType.EXTERNAL,
     entry_point="nrf24scan_app",
     entry_point="nrf24scan_app",

+ 5 - 2
nrf24scan.c

@@ -1200,8 +1200,11 @@ int32_t nrf24scan_app(void* p) {
 						if(what_doing == 0) {
 						if(what_doing == 0) {
 							if(menu_selected < menu_selected_max) menu_selected++; else menu_selected = 0;
 							if(menu_selected < menu_selected_max) menu_selected++; else menu_selected = 0;
 						} else if(what_doing == 1) {
 						} else if(what_doing == 1) {
-							view_log_arr_idx += event.input.type == InputTypeRepeat ? 10 : 1;
-							if(view_log_arr_idx >= log_arr_idx) view_log_arr_idx = log_arr_idx - 1;
+							if(log_arr_idx == 0) view_log_arr_idx = 0;
+							else {
+								view_log_arr_idx += event.input.type == InputTypeRepeat ? 10 : 1;
+								if(view_log_arr_idx >= log_arr_idx) view_log_arr_idx = log_arr_idx - 1;
+							} 
 						} else if(what_doing == 2) {
 						} else if(what_doing == 2) {
 							if(view_found < found_total / 7) view_found++;
 							if(view_found < found_total / 7) view_found++;
 						}
 						}