From 5f8ab3abc0a3d6017f87c8144cc563f1b7f8615b Mon Sep 17 00:00:00 2001 From: deimos Date: Fri, 30 Aug 2024 19:54:18 -0600 Subject: [PATCH 01/22] chore: fix minino path and add link to dev guide --- README.md | 4 ++++ firmware/README.md | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index f0a6b61c..d0838cfe 100644 --- a/README.md +++ b/README.md @@ -90,6 +90,10 @@ Minino can operate in 6 different technologies: Inspired by projects such as [Amini Project](https://github.com/Ocelot-Offensive-Security/Arsenal) and [USBNugget](https://github.com/HakCat-Tech/USB-Nugget). +## How to build the firmware + +Check the [Developer guide](./firmware/README.md) to learn how to build the firmware from scratch. + ## How to contribute Contributions are welcome! diff --git a/firmware/README.md b/firmware/README.md index ace5a8fd..8ca20dc0 100644 --- a/firmware/README.md +++ b/firmware/README.md @@ -43,7 +43,7 @@ git clone git@github.com:ElectronicCats/Minino.git 2. Change to the firmware directory: ```bash -cd Minino/examples/minino +cd Minino/firmware ``` 3. Set the IDF_PATH environment variable: From dd925de2dd0520376527f33ffa211b943ed6b023 Mon Sep 17 00:00:00 2001 From: Roberto Arellano Date: Mon, 2 Sep 2024 09:50:40 -0600 Subject: [PATCH 02/22] refactor: reset last selected item on menus exit --- firmware/main/modules/menus_module/menus_module.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/firmware/main/modules/menus_module/menus_module.c b/firmware/main/modules/menus_module/menus_module.c index 698dc384..e4d56af6 100644 --- a/firmware/main/modules/menus_module/menus_module.c +++ b/firmware/main/modules/menus_module/menus_module.c @@ -110,8 +110,7 @@ static void navigation_exit() { screen_saver_run(); return; } - menus[get_menu_idx(menus_ctx->current_menu)].last_selected_submenu = - menus_ctx->selected_submenu; + menus[get_menu_idx(menus_ctx->current_menu)].last_selected_submenu = 0; void (*cb)() = menus[get_menu_idx(menus_ctx->current_menu)].on_exit_cb; if (cb) { cb(); From c1bc5731686bd4ff1a4385e1d1ed8ae5fac077b5 Mon Sep 17 00:00:00 2001 From: deimos Date: Mon, 2 Sep 2024 13:22:56 -0600 Subject: [PATCH 03/22] refactor: move menus.h to include dir --- firmware/main/modules/menus_module/{ => menus_include}/menus.h | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename firmware/main/modules/menus_module/{ => menus_include}/menus.h (100%) diff --git a/firmware/main/modules/menus_module/menus.h b/firmware/main/modules/menus_module/menus_include/menus.h similarity index 100% rename from firmware/main/modules/menus_module/menus.h rename to firmware/main/modules/menus_module/menus_include/menus.h From 6f336e927569f57424334ff033a34a945274ff10 Mon Sep 17 00:00:00 2001 From: deimos Date: Mon, 2 Sep 2024 14:05:11 -0600 Subject: [PATCH 04/22] refactor: move kconfig to a component --- .../components/minino_config/CMakeLists.txt | 1 + .../minino_config}/Kconfig.projbuild | 0 firmware/main/CMakeLists.txt | 35 ------------------- 3 files changed, 1 insertion(+), 35 deletions(-) create mode 100644 firmware/components/minino_config/CMakeLists.txt rename firmware/{main => components/minino_config}/Kconfig.projbuild (100%) diff --git a/firmware/components/minino_config/CMakeLists.txt b/firmware/components/minino_config/CMakeLists.txt new file mode 100644 index 00000000..eb299554 --- /dev/null +++ b/firmware/components/minino_config/CMakeLists.txt @@ -0,0 +1 @@ +idf_component_register(SRCS INCLUDE_DIRS) diff --git a/firmware/main/Kconfig.projbuild b/firmware/components/minino_config/Kconfig.projbuild similarity index 100% rename from firmware/main/Kconfig.projbuild rename to firmware/components/minino_config/Kconfig.projbuild diff --git a/firmware/main/CMakeLists.txt b/firmware/main/CMakeLists.txt index 326e32da..1782cedb 100644 --- a/firmware/main/CMakeLists.txt +++ b/firmware/main/CMakeLists.txt @@ -26,38 +26,3 @@ idf_component_register( modules/web_file_browser/http_server/style.css INCLUDE_DIRS "${headers_dirs}") - -# # Append all directories to INCLUDE_DIRS - -# file(GLOB_RECURSE ALL_INCLUDE_PATHS "./*") -# set(INCLUDE_DIRS "") - -# foreach(path ${ALL_INCLUDE_PATHS}) -# get_filename_component(parentDir ${path} DIRECTORY) - -# if(IS_DIRECTORY ${parentDir}) -# list(APPEND INCLUDE_DIRS ${parentDir}) -# endif() -# endforeach() - -# list(REMOVE_DUPLICATES INCLUDE_DIRS) - -# # Append all source files to SRCS - -# file(GLOB_RECURSE ALL_SOURCE_FILES "./*") -# set(SRCS "") - -# foreach(file ${ALL_SOURCE_FILES}) -# get_filename_component(extension ${file} EXT) -# if(NOT extension STREQUAL "") -# list(APPEND SRCS ${file}) -# endif() -# endforeach() - -# # Register the component - -# idf_component_register( -# SRCS -# ${SRCS} -# INCLUDE_DIRS -# ${INCLUDE_DIRS}) From 183cc76a9da460ed6d78deb8e693222185299351 Mon Sep 17 00:00:00 2001 From: deimos Date: Mon, 2 Sep 2024 16:22:53 -0600 Subject: [PATCH 05/22] refactor: menu idx --- firmware/main/modules/gps/gps_screens.c | 6 +- .../menus_module/menus_include/menus.h | 302 +++++++++--------- .../main/modules/menus_module/menus_module.c | 8 +- .../modules/open_thread/open_thread_module.c | 2 +- .../main/modules/screen_saver/screen_saver.c | 6 +- .../web_file_browser_module.c | 2 +- firmware/main/modules/zigbee/zigbee_module.c | 4 +- 7 files changed, 165 insertions(+), 165 deletions(-) diff --git a/firmware/main/modules/gps/gps_screens.c b/firmware/main/modules/gps/gps_screens.c index ddd40be5..0bb641f4 100644 --- a/firmware/main/modules/gps/gps_screens.c +++ b/firmware/main/modules/gps/gps_screens.c @@ -71,13 +71,13 @@ void gps_screens_show_waiting_signal() { void gps_screens_update_handler(gps_t* gps) { menu_idx_t current = menus_module_get_current_menu(); switch (current) { - case MENU_GPS_DATE_TIME_2: + case MENU_GPS_DATE_TIME: gps_screens_update_date_and_time(gps); break; - case MENU_GPS_LOCATION_2: + case MENU_GPS_LOCATION: gps_screens_update_location(gps); break; - case MENU_GPS_SPEED_2: + case MENU_GPS_SPEED: gps_screens_update_speed(gps); break; default: diff --git a/firmware/main/modules/menus_module/menus_include/menus.h b/firmware/main/modules/menus_module/menus_include/menus.h index 414d1000..95d551f2 100644 --- a/firmware/main/modules/menus_module/menus_include/menus.h +++ b/firmware/main/modules/menus_module/menus_include/menus.h @@ -26,74 +26,74 @@ #include "zigbee_module.h" typedef enum { - MENU_MAIN_2 = 0, - MENU_APPLICATIONS_2, - MENU_SETTINGS_2, - MENU_ABOUT_2, + MENU_MAIN = 0, + MENU_APPLICATIONS, + MENU_SETTINGS, + MENU_ABOUT, /* Applications */ - MENU_WIFI_APPS_2, - MENU_BLUETOOTH_APPS_2, - MENU_ZIGBEE_APPS_2, - MENU_THREAD_APPS_2, - MENU_GPS_2, + MENU_WIFI_APPS, + MENU_BLUETOOTH_APPS, + MENU_ZIGBEE_APPS, + MENU_THREAD_APPS, + MENU_GPS, /* WiFi applications */ - MENU_WIFI_ANALIZER_2, - MENU_WIFI_DEAUTH_2, - MENU_WIFI_DOS_2, + MENU_WIFI_ANALIZER, + MENU_WIFI_DEAUTH, + MENU_WIFI_DOS, /* WiFi analizer items */ - MENU_WIFI_ANALYZER_RUN_2, - MENU_WIFI_ANALYZER_SETTINGS_2, - MENU_WIFI_ANALYZER_HELP_2, + MENU_WIFI_ANALYZER_RUN, + MENU_WIFI_ANALYZER_SETTINGS, + MENU_WIFI_ANALYZER_HELP, /* WiFi analizer start items */ - MENU_WIFI_ANALYZER_ASK_SUMMARY_2, - MENU_WIFI_ANALYZER_SUMMARY_2, + MENU_WIFI_ANALYZER_ASK_SUMMARY, + MENU_WIFI_ANALYZER_SUMMARY, /* WiFi analizer settings */ - MENU_WIFI_ANALYZER_CHANNEL_2, - MENU_WIFI_ANALYZER_DESTINATION_2, - MENU_WIFI_ANALYZER_SD_EREASE_WARNING_2, + MENU_WIFI_ANALYZER_CHANNEL, + MENU_WIFI_ANALYZER_DESTINATION, + MENU_WIFI_ANALYZER_SD_EREASE_WARNING, /* Bluetooth applications */ - MENU_BLUETOOTH_TRAKERS_SCAN_2, - MENU_BLUETOOTH_SPAM_2, + MENU_BLUETOOTH_TRAKERS_SCAN, + MENU_BLUETOOTH_SPAM, MENU_BLUETOOTH_HID, /* Zigbee applications */ - MENU_ZIGBEE_SPOOFING_2, - MENU_ZIGBEE_SWITCH_2, - MENU_ZIGBEE_LIGHT_2, - MENU_ZIGBEE_SNIFFER_2, + MENU_ZIGBEE_SPOOFING, + MENU_ZIGBEE_SWITCH, + MENU_ZIGBEE_LIGHT, + MENU_ZIGBEE_SNIFFER, /* Thread applications */ - MENU_THREAD_BROADCAST_2, - MENU_THREAD_SNIFFER_2, + MENU_THREAD_BROADCAST, + MENU_THREAD_SNIFFER, /* Thread Sniffer App */ - MENU_THREAD_SNIFFER_RUN_2, + MENU_THREAD_SNIFFER_RUN, /* GPS applications */ - MENU_GPS_WARDRIVING_2, - MENU_GPS_DATE_TIME_2, - MENU_GPS_LOCATION_2, - MENU_GPS_SPEED_2, - MENU_GPS_HELP_2, + MENU_GPS_WARDRIVING, + MENU_GPS_DATE_TIME, + MENU_GPS_LOCATION, + MENU_GPS_SPEED, + MENU_GPS_HELP, /* Wardriving submenus */ - MENU_GPS_WARDRIVING_START_2, - MENU_GPS_WARDRIVING_HELP_2, + MENU_GPS_WARDRIVING_START, + MENU_GPS_WARDRIVING_HELP, /* About submenus */ - MENU_ABOUT_VERSION_2, - MENU_ABOUT_LICENSE_2, - MENU_ABOUT_CREDITS_2, - MENU_ABOUT_LEGAL_2, - MENU_ABOUT_UPDATE_2, + MENU_ABOUT_VERSION, + MENU_ABOUT_LICENSE, + MENU_ABOUT_CREDITS, + MENU_ABOUT_LEGAL, + MENU_ABOUT_UPDATE, /* Settings items */ - MENU_SETTINGS_DISPLAY_2, - MENU_FILE_MANAGER_2, - MENU_FILE_MANAGER_LOCAL_2, - MENU_FILE_MANAGER_WEB_2, - MENU_SETTINGS_SYSTEM_2, - MENU_SETTINGS_TIME_ZONE_2, - MENU_SETTINGS_WIFI_2, - MENU_SETTINGS_SD_CARD_2, - MENU_SETTINGS_SD_CARD_INFO_2, - MENU_SETTINGS_SD_CARD_FORMAT_2, - MENU_STEALTH_MODE_2, + MENU_SETTINGS_DISPLAY, + MENU_FILE_MANAGER, + MENU_FILE_MANAGER_LOCAL, + MENU_FILE_MANAGER_WEB, + MENU_SETTINGS_SYSTEM, + MENU_SETTINGS_TIME_ZONE, + MENU_SETTINGS_WIFI, + MENU_SETTINGS_SD_CARD, + MENU_SETTINGS_SD_CARD_INFO, + MENU_SETTINGS_SD_CARD_FORMAT, + MENU_STEALTH_MODE, /* Menu count */ - MENU_COUNT_2, // Keep this at the end + MENU_COUNT, // Keep this at the end } menu_idx_t; typedef struct { @@ -118,108 +118,108 @@ typedef struct { menu_t menus[] = { ////////////////////////////////// {.display_name = "Must Not See This", - .menu_idx = MENU_MAIN_2, + .menu_idx = MENU_MAIN, .parent_idx = -1, .last_selected_submenu = 0, .on_enter_cb = NULL, .on_exit_cb = NULL, .is_visible = false}, {.display_name = "Applications", - .menu_idx = MENU_APPLICATIONS_2, - .parent_idx = MENU_MAIN_2, + .menu_idx = MENU_APPLICATIONS, + .parent_idx = MENU_MAIN, .last_selected_submenu = 0, .on_enter_cb = NULL, .on_exit_cb = NULL, .is_visible = true}, {.display_name = "Settings", - .menu_idx = MENU_SETTINGS_2, - .parent_idx = MENU_MAIN_2, + .menu_idx = MENU_SETTINGS, + .parent_idx = MENU_MAIN, .last_selected_submenu = 0, .on_enter_cb = NULL, .on_exit_cb = NULL, .is_visible = true}, {.display_name = "About", - .menu_idx = MENU_ABOUT_2, - .parent_idx = MENU_MAIN_2, + .menu_idx = MENU_ABOUT, + .parent_idx = MENU_MAIN, .last_selected_submenu = 0, .on_enter_cb = NULL, .on_exit_cb = NULL, .is_visible = true}, {.display_name = "Version", - .menu_idx = MENU_ABOUT_VERSION_2, - .parent_idx = MENU_ABOUT_2, + .menu_idx = MENU_ABOUT_VERSION, + .parent_idx = MENU_ABOUT, .last_selected_submenu = 0, .on_enter_cb = about_module_display_version, .on_exit_cb = NULL, .is_visible = true}, {.display_name = "License", - .menu_idx = MENU_ABOUT_LICENSE_2, - .parent_idx = MENU_ABOUT_2, + .menu_idx = MENU_ABOUT_LICENSE, + .parent_idx = MENU_ABOUT, .last_selected_submenu = 0, .on_enter_cb = about_module_display_license, .on_exit_cb = NULL, .is_visible = true}, {.display_name = "Credits", - .menu_idx = MENU_ABOUT_CREDITS_2, - .parent_idx = MENU_ABOUT_2, + .menu_idx = MENU_ABOUT_CREDITS, + .parent_idx = MENU_ABOUT, .last_selected_submenu = 0, .on_enter_cb = about_module_display_credits_menu, .on_exit_cb = NULL, .is_visible = true}, {.display_name = "Legal", - .menu_idx = MENU_ABOUT_LEGAL_2, - .parent_idx = MENU_ABOUT_2, + .menu_idx = MENU_ABOUT_LEGAL, + .parent_idx = MENU_ABOUT, .last_selected_submenu = 0, .on_enter_cb = about_module_display_legal_menu, .on_exit_cb = NULL, .is_visible = true}, #ifdef CONFIG_WIFI_APPS_ENABLE {.display_name = "WiFi", - .menu_idx = MENU_WIFI_APPS_2, - .parent_idx = MENU_APPLICATIONS_2, + .menu_idx = MENU_WIFI_APPS, + .parent_idx = MENU_APPLICATIONS, .last_selected_submenu = 0, .on_enter_cb = NULL, .on_exit_cb = NULL, .is_visible = true}, #ifdef CONFIG_WIFI_APP_ANALYZER {.display_name = "Analyzer", - .menu_idx = MENU_WIFI_ANALIZER_2, - .parent_idx = MENU_WIFI_APPS_2, + .menu_idx = MENU_WIFI_ANALIZER, + .parent_idx = MENU_WIFI_APPS, .last_selected_submenu = 0, .on_enter_cb = wifi_module_analizer_begin, .on_exit_cb = wifi_module_analyzer_exit, .is_visible = true}, {.display_name = "Start", - .menu_idx = MENU_WIFI_ANALYZER_RUN_2, - .parent_idx = MENU_WIFI_ANALIZER_2, + .menu_idx = MENU_WIFI_ANALYZER_RUN, + .parent_idx = MENU_WIFI_ANALIZER, .last_selected_submenu = 0, .on_enter_cb = wifi_module_analyzer_run, .on_exit_cb = NULL, .is_visible = true}, {.display_name = "Settings", - .menu_idx = MENU_WIFI_ANALYZER_SETTINGS_2, - .parent_idx = MENU_WIFI_ANALIZER_2, + .menu_idx = MENU_WIFI_ANALYZER_SETTINGS, + .parent_idx = MENU_WIFI_ANALIZER, .last_selected_submenu = 0, .on_enter_cb = NULL, .on_exit_cb = NULL, .is_visible = true}, {.display_name = "Channel", - .menu_idx = MENU_WIFI_ANALYZER_CHANNEL_2, - .parent_idx = MENU_WIFI_ANALYZER_SETTINGS_2, + .menu_idx = MENU_WIFI_ANALYZER_CHANNEL, + .parent_idx = MENU_WIFI_ANALYZER_SETTINGS, .last_selected_submenu = 0, .on_enter_cb = wifi_module_analyzer_channel, .on_exit_cb = NULL, .is_visible = true}, {.display_name = "Destination", - .menu_idx = MENU_WIFI_ANALYZER_DESTINATION_2, - .parent_idx = MENU_WIFI_ANALYZER_SETTINGS_2, + .menu_idx = MENU_WIFI_ANALYZER_DESTINATION, + .parent_idx = MENU_WIFI_ANALYZER_SETTINGS, .last_selected_submenu = 0, .on_enter_cb = wifi_module_analyzer_destination, .on_exit_cb = wifi_module_analyzer_destination_exit, .is_visible = true}, {.display_name = "Help", - .menu_idx = MENU_WIFI_ANALYZER_HELP_2, - .parent_idx = MENU_WIFI_ANALIZER_2, + .menu_idx = MENU_WIFI_ANALYZER_HELP, + .parent_idx = MENU_WIFI_ANALIZER, .last_selected_submenu = 0, .on_enter_cb = wifi_module_show_analyzer_help, .on_exit_cb = NULL, @@ -227,8 +227,8 @@ menu_t menus[] = { ////////////////////////////////// #endif #ifdef CONFIG_WIFI_APP_DEAUTH {.display_name = "Deauth", - .menu_idx = MENU_WIFI_DEAUTH_2, - .parent_idx = MENU_WIFI_APPS_2, + .menu_idx = MENU_WIFI_DEAUTH, + .parent_idx = MENU_WIFI_APPS, .last_selected_submenu = 0, .on_enter_cb = deauth_module_begin, .on_exit_cb = NULL, @@ -236,8 +236,8 @@ menu_t menus[] = { ////////////////////////////////// #endif #ifdef CONFIG_WIFI_APP_DOS {.display_name = "DoS", - .menu_idx = MENU_WIFI_DOS_2, - .parent_idx = MENU_WIFI_APPS_2, + .menu_idx = MENU_WIFI_DOS, + .parent_idx = MENU_WIFI_APPS, .last_selected_submenu = 0, .on_enter_cb = catdos_module_begin, .on_exit_cb = NULL, @@ -246,16 +246,16 @@ menu_t menus[] = { ////////////////////////////////// #endif #ifdef CONFIG_BLUETOOTH_APPS_ENABLE {.display_name = "Bluetooth", - .menu_idx = MENU_BLUETOOTH_APPS_2, - .parent_idx = MENU_APPLICATIONS_2, + .menu_idx = MENU_BLUETOOTH_APPS, + .parent_idx = MENU_APPLICATIONS, .last_selected_submenu = 0, .on_enter_cb = NULL, .on_exit_cb = NULL, .is_visible = true}, #ifdef CONFIG_BLUETOOTH_APP_TRAKERS {.display_name = "Trakers scan", - .menu_idx = MENU_BLUETOOTH_TRAKERS_SCAN_2, - .parent_idx = MENU_BLUETOOTH_APPS_2, + .menu_idx = MENU_BLUETOOTH_TRAKERS_SCAN, + .parent_idx = MENU_BLUETOOTH_APPS, .last_selected_submenu = 0, .on_enter_cb = trackers_module_begin, .on_exit_cb = NULL, @@ -263,8 +263,8 @@ menu_t menus[] = { ////////////////////////////////// #endif #ifdef CONFIG_BLUETOOTH_APP_SPAM {.display_name = "Spam", - .menu_idx = MENU_BLUETOOTH_SPAM_2, - .parent_idx = MENU_BLUETOOTH_APPS_2, + .menu_idx = MENU_BLUETOOTH_SPAM, + .parent_idx = MENU_BLUETOOTH_APPS, .last_selected_submenu = 0, .on_enter_cb = ble_module_begin, .on_exit_cb = NULL, @@ -273,7 +273,7 @@ menu_t menus[] = { ////////////////////////////////// #ifdef CONFIG_BLUETOOTH_APP_HID {.display_name = "HID", .menu_idx = MENU_BLUETOOTH_HID, - .parent_idx = MENU_BLUETOOTH_APPS_2, + .parent_idx = MENU_BLUETOOTH_APPS, .last_selected_submenu = 0, .on_enter_cb = hid_module_begin, .on_exit_cb = NULL, @@ -282,30 +282,30 @@ menu_t menus[] = { ////////////////////////////////// #endif #ifdef CONFIG_ZIGBEE_APPS_ENABLE {.display_name = "Zigbee", - .menu_idx = MENU_ZIGBEE_APPS_2, - .parent_idx = MENU_APPLICATIONS_2, + .menu_idx = MENU_ZIGBEE_APPS, + .parent_idx = MENU_APPLICATIONS, .last_selected_submenu = 0, .on_enter_cb = NULL, .on_exit_cb = NULL, .is_visible = true}, #ifdef CONFIG_ZIGBEE_APP_SPOOFING {.display_name = "Spoofing", - .menu_idx = MENU_ZIGBEE_SPOOFING_2, - .parent_idx = MENU_ZIGBEE_APPS_2, + .menu_idx = MENU_ZIGBEE_SPOOFING, + .parent_idx = MENU_ZIGBEE_APPS, .last_selected_submenu = 0, .on_enter_cb = NULL, .on_exit_cb = NULL, .is_visible = true}, {.display_name = "Switch", - .menu_idx = MENU_ZIGBEE_SWITCH_2, - .parent_idx = MENU_ZIGBEE_SPOOFING_2, + .menu_idx = MENU_ZIGBEE_SWITCH, + .parent_idx = MENU_ZIGBEE_SPOOFING, .last_selected_submenu = 0, .on_enter_cb = zigbee_module_switch_enter, .on_exit_cb = NULL, .is_visible = true}, {.display_name = "Light", - .menu_idx = MENU_ZIGBEE_LIGHT_2, - .parent_idx = MENU_ZIGBEE_SPOOFING_2, + .menu_idx = MENU_ZIGBEE_LIGHT, + .parent_idx = MENU_ZIGBEE_SPOOFING, .last_selected_submenu = 0, .on_enter_cb = NULL, .on_exit_cb = NULL, @@ -313,8 +313,8 @@ menu_t menus[] = { ////////////////////////////////// #endif #ifdef CONFIG_ZIGBEE_APP_SNIFFER {.display_name = "Sniffer", - .menu_idx = MENU_ZIGBEE_SNIFFER_2, - .parent_idx = MENU_ZIGBEE_APPS_2, + .menu_idx = MENU_ZIGBEE_SNIFFER, + .parent_idx = MENU_ZIGBEE_APPS, .last_selected_submenu = 0, .on_enter_cb = zigbee_module_sniffer_enter, .on_exit_cb = NULL, @@ -323,16 +323,16 @@ menu_t menus[] = { ////////////////////////////////// #endif #ifdef CONFIG_THREAD_APPS_ENABLE {.display_name = "Thread", - .menu_idx = MENU_THREAD_APPS_2, - .parent_idx = MENU_APPLICATIONS_2, + .menu_idx = MENU_THREAD_APPS, + .parent_idx = MENU_APPLICATIONS, .last_selected_submenu = 0, .on_enter_cb = NULL, .on_exit_cb = NULL, .is_visible = true}, #ifdef CONFIG_THREAD_APP_BROADCAST {.display_name = "Broadcast", - .menu_idx = MENU_THREAD_BROADCAST_2, - .parent_idx = MENU_THREAD_APPS_2, + .menu_idx = MENU_THREAD_BROADCAST, + .parent_idx = MENU_THREAD_APPS, .last_selected_submenu = 0, .on_enter_cb = open_thread_module_broadcast_enter, .on_exit_cb = open_thread_module_exit, @@ -340,15 +340,15 @@ menu_t menus[] = { ////////////////////////////////// #endif #ifdef CONFIG_THREAD_APP_SNIFFER {.display_name = "Sniffer", - .menu_idx = MENU_THREAD_SNIFFER_2, - .parent_idx = MENU_THREAD_APPS_2, + .menu_idx = MENU_THREAD_SNIFFER, + .parent_idx = MENU_THREAD_APPS, .last_selected_submenu = 0, .on_enter_cb = open_thread_module_sniffer_enter, .on_exit_cb = open_thread_module_exit, .is_visible = true}, {.display_name = "Run", - .menu_idx = MENU_THREAD_SNIFFER_RUN_2, - .parent_idx = MENU_THREAD_SNIFFER_2, + .menu_idx = MENU_THREAD_SNIFFER_RUN, + .parent_idx = MENU_THREAD_SNIFFER, .last_selected_submenu = 0, .on_enter_cb = open_thread_module_sniffer_run, .on_exit_cb = NULL, @@ -357,66 +357,66 @@ menu_t menus[] = { ////////////////////////////////// #endif #ifdef CONFIG_GPS_APPS_ENABLE {.display_name = "GPS", - .menu_idx = MENU_GPS_2, - .parent_idx = MENU_APPLICATIONS_2, + .menu_idx = MENU_GPS, + .parent_idx = MENU_APPLICATIONS, .last_selected_submenu = 0, .on_enter_cb = NULL, .on_exit_cb = NULL, .is_visible = true}, #ifdef CONFIG_GPS_APP_WARDRIVING {.display_name = "Wardriving", - .menu_idx = MENU_GPS_WARDRIVING_2, - .parent_idx = MENU_GPS_2, + .menu_idx = MENU_GPS_WARDRIVING, + .parent_idx = MENU_GPS, .last_selected_submenu = 0, .on_enter_cb = wardriving_module_begin, .on_exit_cb = wardriving_module_end, .is_visible = true}, {.display_name = "Start", - .menu_idx = MENU_GPS_WARDRIVING_START_2, - .parent_idx = MENU_GPS_WARDRIVING_2, + .menu_idx = MENU_GPS_WARDRIVING_START, + .parent_idx = MENU_GPS_WARDRIVING, .last_selected_submenu = 0, .on_enter_cb = wardriving_module_start_scan, .on_exit_cb = wardriving_module_stop_scan, .is_visible = true}, {.display_name = "Help", - .menu_idx = MENU_GPS_WARDRIVING_HELP_2, - .parent_idx = MENU_GPS_WARDRIVING_2, + .menu_idx = MENU_GPS_WARDRIVING_HELP, + .parent_idx = MENU_GPS_WARDRIVING, .last_selected_submenu = 0, .on_enter_cb = wardriving_screens_show_help, .on_exit_cb = NULL, .is_visible = true}, #endif {.display_name = "Date & Time", - .menu_idx = MENU_GPS_DATE_TIME_2, - .parent_idx = MENU_GPS_2, + .menu_idx = MENU_GPS_DATE_TIME, + .parent_idx = MENU_GPS, .last_selected_submenu = 0, .on_enter_cb = gps_module_general_data_run, .on_exit_cb = NULL, .is_visible = true}, {.display_name = "Location", - .menu_idx = MENU_GPS_LOCATION_2, - .parent_idx = MENU_GPS_2, + .menu_idx = MENU_GPS_LOCATION, + .parent_idx = MENU_GPS, .last_selected_submenu = 0, .on_enter_cb = gps_module_general_data_run, .on_exit_cb = NULL, .is_visible = true}, {.display_name = "Speed", - .menu_idx = MENU_GPS_SPEED_2, - .parent_idx = MENU_GPS_2, + .menu_idx = MENU_GPS_SPEED, + .parent_idx = MENU_GPS, .last_selected_submenu = 0, .on_enter_cb = gps_module_general_data_run, .on_exit_cb = NULL, .is_visible = true}, {.display_name = "Help", - .menu_idx = MENU_GPS_HELP_2, - .parent_idx = MENU_GPS_2, + .menu_idx = MENU_GPS_HELP, + .parent_idx = MENU_GPS, .last_selected_submenu = 0, .on_enter_cb = gps_screens_show_help, .on_exit_cb = NULL, .is_visible = true}, {.display_name = "Time zone", - .menu_idx = MENU_SETTINGS_TIME_ZONE_2, - .parent_idx = MENU_SETTINGS_SYSTEM_2, + .menu_idx = MENU_SETTINGS_TIME_ZONE, + .parent_idx = MENU_SETTINGS_SYSTEM, .last_selected_submenu = 0, .on_enter_cb = settings_module_time_zone, .on_exit_cb = NULL, @@ -424,67 +424,67 @@ menu_t menus[] = { ////////////////////////////////// #endif #ifdef CONFIG_OTA_ENABLE {.display_name = "Update", - .menu_idx = MENU_ABOUT_UPDATE_2, - .parent_idx = MENU_ABOUT_2, + .menu_idx = MENU_ABOUT_UPDATE, + .parent_idx = MENU_ABOUT, .last_selected_submenu = 0, .on_enter_cb = ota_module_init, .on_exit_cb = NULL, .is_visible = true}, #endif {.display_name = "Display", - .menu_idx = MENU_SETTINGS_DISPLAY_2, - .parent_idx = MENU_SETTINGS_2, + .menu_idx = MENU_SETTINGS_DISPLAY, + .parent_idx = MENU_SETTINGS, .last_selected_submenu = 0, .on_enter_cb = display_config_module_begin, .on_exit_cb = NULL, .is_visible = true}, {.display_name = "System", - .menu_idx = MENU_SETTINGS_SYSTEM_2, - .parent_idx = MENU_SETTINGS_2, + .menu_idx = MENU_SETTINGS_SYSTEM, + .parent_idx = MENU_SETTINGS, .last_selected_submenu = 0, .on_enter_cb = NULL, .on_exit_cb = NULL, .is_visible = true}, {.display_name = "WiFi", - .menu_idx = MENU_SETTINGS_WIFI_2, - .parent_idx = MENU_SETTINGS_SYSTEM_2, + .menu_idx = MENU_SETTINGS_WIFI, + .parent_idx = MENU_SETTINGS_SYSTEM, .last_selected_submenu = 0, .on_enter_cb = wifi_settings_begin, .on_exit_cb = NULL, .is_visible = true}, {.display_name = "SD card", - .menu_idx = MENU_SETTINGS_SD_CARD_2, - .parent_idx = MENU_SETTINGS_SYSTEM_2, + .menu_idx = MENU_SETTINGS_SD_CARD, + .parent_idx = MENU_SETTINGS_SYSTEM, .last_selected_submenu = 0, .on_enter_cb = NULL, .on_exit_cb = NULL, .is_visible = true}, {.display_name = "Info", - .menu_idx = MENU_SETTINGS_SD_CARD_INFO_2, - .parent_idx = MENU_SETTINGS_SD_CARD_2, + .menu_idx = MENU_SETTINGS_SD_CARD_INFO, + .parent_idx = MENU_SETTINGS_SD_CARD, .last_selected_submenu = 0, .on_enter_cb = update_sd_card_info, .on_exit_cb = NULL, .is_visible = true}, {.display_name = "Check Format", - .menu_idx = MENU_SETTINGS_SD_CARD_FORMAT_2, - .parent_idx = MENU_SETTINGS_SD_CARD_2, + .menu_idx = MENU_SETTINGS_SD_CARD_FORMAT, + .parent_idx = MENU_SETTINGS_SD_CARD, .last_selected_submenu = 0, .on_enter_cb = sd_card_settings_verify_sd_card, .on_exit_cb = NULL, .is_visible = true}, #ifdef CONFIG_FILE_MANAGER_ENABLE {.display_name = "File Manager", - .menu_idx = MENU_FILE_MANAGER_2, - .parent_idx = MENU_SETTINGS_2, + .menu_idx = MENU_FILE_MANAGER, + .parent_idx = MENU_SETTINGS, .last_selected_submenu = 0, .on_enter_cb = NULL, .on_exit_cb = NULL, .is_visible = true}, #ifdef CONFIG_FILE_MANAGER_LOCAL {.display_name = "Local", - .menu_idx = MENU_FILE_MANAGER_LOCAL_2, - .parent_idx = MENU_FILE_MANAGER_2, + .menu_idx = MENU_FILE_MANAGER_LOCAL, + .parent_idx = MENU_FILE_MANAGER, .last_selected_submenu = 0, .on_enter_cb = file_manager_module_init, .on_exit_cb = NULL, @@ -492,8 +492,8 @@ menu_t menus[] = { ////////////////////////////////// #endif #ifdef CONFIG_FILE_MANAGER_WEB {.display_name = "Web", - .menu_idx = MENU_FILE_MANAGER_WEB_2, - .parent_idx = MENU_FILE_MANAGER_2, + .menu_idx = MENU_FILE_MANAGER_WEB, + .parent_idx = MENU_FILE_MANAGER, .last_selected_submenu = 0, .on_enter_cb = web_file_browser_module_begin, .on_exit_cb = NULL, @@ -501,8 +501,8 @@ menu_t menus[] = { ////////////////////////////////// #endif #endif {.display_name = "Stealth Mode", - .menu_idx = MENU_STEALTH_MODE_2, - .parent_idx = MENU_SETTINGS_2, + .menu_idx = MENU_STEALTH_MODE, + .parent_idx = MENU_SETTINGS, .last_selected_submenu = 0, .on_enter_cb = stealth_mode_open_menu, .on_exit_cb = NULL, diff --git a/firmware/main/modules/menus_module/menus_module.c b/firmware/main/modules/menus_module/menus_module.c index e4d56af6..3f01547d 100644 --- a/firmware/main/modules/menus_module/menus_module.c +++ b/firmware/main/modules/menus_module/menus_module.c @@ -106,7 +106,7 @@ static void navigation_enter() { } static void navigation_exit() { - if (menus_ctx->current_menu == MENU_MAIN_2) { + if (menus_ctx->current_menu == MENU_MAIN) { screen_saver_run(); return; } @@ -176,11 +176,11 @@ void menus_module_set_reset_screen(menu_idx_t menu) { } static void get_reset_menu() { - menus_ctx->current_menu = preferences_get_int("MENUNUMBER", MENU_MAIN_2); - if ((int) menus_ctx->current_menu == MENU_MAIN_2) { + menus_ctx->current_menu = preferences_get_int("MENUNUMBER", MENU_MAIN); + if ((int) menus_ctx->current_menu == MENU_MAIN) { show_logo(); } else { - preferences_put_int("MENUNUMBER", MENU_MAIN_2); + preferences_put_int("MENUNUMBER", MENU_MAIN); screen_saver_get_idle_state(); refresh_menus(); } diff --git a/firmware/main/modules/open_thread/open_thread_module.c b/firmware/main/modules/open_thread/open_thread_module.c index db969cec..5c375d02 100644 --- a/firmware/main/modules/open_thread/open_thread_module.c +++ b/firmware/main/modules/open_thread/open_thread_module.c @@ -23,7 +23,7 @@ void open_thread_module_begin() { } void open_thread_module_exit() { - menus_module_set_reset_screen(MENU_THREAD_APPS_2); + menus_module_set_reset_screen(MENU_THREAD_APPS); esp_restart(); } diff --git a/firmware/main/modules/screen_saver/screen_saver.c b/firmware/main/modules/screen_saver/screen_saver.c index e66311e5..37805d5d 100644 --- a/firmware/main/modules/screen_saver/screen_saver.c +++ b/firmware/main/modules/screen_saver/screen_saver.c @@ -21,9 +21,9 @@ static void timer_callback() { } menu_idx_t menu = menus_module_get_current_menu(); - if (menu == MENU_WIFI_ANALYZER_RUN_2 || - menu == MENU_WIFI_ANALYZER_SUMMARY_2 || menu == MENU_GPS_DATE_TIME_2 || - menu == MENU_GPS_LOCATION_2 || menu == MENU_GPS_SPEED_2) { + if (menu == MENU_WIFI_ANALYZER_RUN || menu == MENU_WIFI_ANALYZER_SUMMARY || + menu == MENU_GPS_DATE_TIME || menu == MENU_GPS_LOCATION || + menu == MENU_GPS_SPEED) { return; } diff --git a/firmware/main/modules/web_file_browser/web_file_browser_module.c b/firmware/main/modules/web_file_browser/web_file_browser_module.c index 466d2372..89ab3f21 100644 --- a/firmware/main/modules/web_file_browser/web_file_browser_module.c +++ b/firmware/main/modules/web_file_browser/web_file_browser_module.c @@ -33,7 +33,7 @@ void web_file_browser_module_begin() { } } void web_file_browser_module_exit() { - menus_module_set_reset_screen(MENU_FILE_MANAGER_2); + menus_module_set_reset_screen(MENU_FILE_MANAGER); esp_restart(); } static void web_file_browser_input_cb(uint8_t button_name, diff --git a/firmware/main/modules/zigbee/zigbee_module.c b/firmware/main/modules/zigbee/zigbee_module.c index 3a6ec3d0..4e5049eb 100644 --- a/firmware/main/modules/zigbee/zigbee_module.c +++ b/firmware/main/modules/zigbee/zigbee_module.c @@ -79,7 +79,7 @@ static void switch_input_cb(uint8_t button_name, uint8_t button_event) { case BUTTON_LEFT: switch (button_event) { case BUTTON_PRESS_DOWN: - menus_module_set_reset_screen(MENU_ZIGBEE_SPOOFING_2); + menus_module_set_reset_screen(MENU_ZIGBEE_SPOOFING); zigbee_switch_deinit(); break; } @@ -95,7 +95,7 @@ static void sniffer_input_cb(uint8_t button_name, uint8_t button_event) { case BUTTON_LEFT: if (button_event == BUTTON_SINGLE_CLICK) { led_control_stop(); - menus_module_set_reset_screen(MENU_ZIGBEE_APPS_2); + menus_module_set_reset_screen(MENU_ZIGBEE_APPS); esp_restart(); } break; From dc744aa1b5b976d0f30949cd08ab3e855f6fd261 Mon Sep 17 00:00:00 2001 From: deimos Date: Mon, 2 Sep 2024 18:56:15 -0600 Subject: [PATCH 06/22] refactor: gps help --- firmware/main/modules/gps/gps_screens.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/firmware/main/modules/gps/gps_screens.c b/firmware/main/modules/gps/gps_screens.c index 0bb641f4..d6e0be52 100644 --- a/firmware/main/modules/gps/gps_screens.c +++ b/firmware/main/modules/gps/gps_screens.c @@ -4,13 +4,13 @@ #include "menus_module.h" #include "oled_screen.h" -char* gps_help_2[] = { +char* gps_help[] = { "Verify your", "time zone if", "the time is not", "correct, go to", "`Settings/", "System/Time", "zone` and", "select the", "correct one.", }; const general_menu_t gps_help_menu = {.menu_count = 9, - .menu_items = gps_help_2, + .menu_items = gps_help, .menu_level = GENERAL_TREE_APP_MENU}; void gps_screens_show_help() { From af1f4f176276fb02f60cc69fb0a8e880557a6844 Mon Sep 17 00:00:00 2001 From: Kevin Jahaziel Leon Morales Date: Tue, 3 Sep 2024 09:31:06 -0600 Subject: [PATCH 07/22] feat: Change version build --- firmware/main/modules/about/about_module.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/firmware/main/modules/about/about_module.c b/firmware/main/modules/about/about_module.c index 7061764c..f898b225 100644 --- a/firmware/main/modules/about/about_module.c +++ b/firmware/main/modules/about/about_module.c @@ -56,7 +56,7 @@ void about_module_display_legal_menu() { void about_module_display_version() { general_screen_display_card_information_handler( - "Minino", "v" CONFIG_PROJECT_VERSION, menus_module_exit_app, NULL); + "Minino", CONFIG_PROJECT_VERSION, menus_module_exit_app, NULL); } void about_module_display_license() { general_screen_display_card_information_handler("License", "GNU GPL 3.0", From 95e061f5ee9e6b633e0eacde6caae1fee714827d Mon Sep 17 00:00:00 2001 From: deimos Date: Thu, 5 Sep 2024 09:15:08 -0600 Subject: [PATCH 08/22] feat: increase wardriving csv lines --- firmware/main/modules/gps/wardriving/wardriving_module.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/firmware/main/modules/gps/wardriving/wardriving_module.c b/firmware/main/modules/gps/wardriving/wardriving_module.c index c8d6c430..0db52c6c 100644 --- a/firmware/main/modules/gps/wardriving/wardriving_module.c +++ b/firmware/main/modules/gps/wardriving/wardriving_module.c @@ -28,7 +28,7 @@ #define MAC_ADDRESS_FORMAT "%02x:%02x:%02x:%02x:%02x:%02x" #define EMPTY_MAC_ADDRESS "00:00:00:00:00:00" -#define MAX_CSV_LINES 100 +#define MAX_CSV_LINES 500 #define CSV_LINE_SIZE 200 // Got it from real time tests #define CSV_FILE_SIZE CSV_LINE_SIZE* MAX_CSV_LINES #define CSV_HEADER_LINES 2 // Check `csv_header` variable From 0f3e292d82f96c09f26f53757b7271a175b7a32d Mon Sep 17 00:00:00 2001 From: Roberto Arellano Date: Thu, 5 Sep 2024 17:38:28 -0600 Subject: [PATCH 09/22] feat: hiding menu functions --- .../main/modules/menus_module/menus_module.c | 18 ++++++++++++++++++ .../main/modules/menus_module/menus_module.h | 4 ++++ 2 files changed, 22 insertions(+) diff --git a/firmware/main/modules/menus_module/menus_module.c b/firmware/main/modules/menus_module/menus_module.c index 3f01547d..b17bba04 100644 --- a/firmware/main/modules/menus_module/menus_module.c +++ b/firmware/main/modules/menus_module/menus_module.c @@ -223,6 +223,24 @@ bool menus_module_get_app_state() { return app_state2.in_app; } +void menus_module_set_menu(menu_idx_t menu_idx) { + keyboard_module_set_input_callback(menus_input_cb); + menus_ctx->current_menu = menus[get_menu_idx(menu_idx)].menu_idx; + menus_ctx->parent_menu_idx = menus[get_menu_idx(menu_idx)].parent_idx; + refresh_menus(); +} + +void menus_module_hide_menu(menu_idx_t menu_idx) { + menus[get_menu_idx(menu_idx)].is_visible = false; +} + +void menus_module_reveal_menu(menu_idx_t menu_idx) { + menus[get_menu_idx(menu_idx)].is_visible = true; +} +void menus_module_refresh() { + refresh_menus(); +} + void menus_module_begin() { menus_ctx = calloc(1, sizeof(menus_manager_t)); menus_ctx->menus_count = sizeof(menus) / sizeof(menu_t); diff --git a/firmware/main/modules/menus_module/menus_module.h b/firmware/main/modules/menus_module/menus_module.h index 6d68b3d2..16607e37 100644 --- a/firmware/main/modules/menus_module/menus_module.h +++ b/firmware/main/modules/menus_module/menus_module.h @@ -29,3 +29,7 @@ void menus_module_restart(); void menus_module_exit_app(); void menus_module_screen_saver_run(); void menus_module_set_reset_screen(menu_idx_t menu); +void menus_module_set_menu(menu_idx_t menu_idx); +void menus_module_hide_menu(menu_idx_t menu_idx); +void menus_module_reveal_menu(menu_idx_t menu_idx); +void menus_module_refresh(); \ No newline at end of file From cc95dcdbf36e06d731320e7a7ab9ff7f9e75884e Mon Sep 17 00:00:00 2001 From: deimos Date: Sat, 7 Sep 2024 18:26:48 -0600 Subject: [PATCH 10/22] fix: do not count empty wifi ap --- .../gps/wardriving/wardriving_module.c | 77 +++++++++++++------ 1 file changed, 54 insertions(+), 23 deletions(-) diff --git a/firmware/main/modules/gps/wardriving/wardriving_module.c b/firmware/main/modules/gps/wardriving/wardriving_module.c index 0db52c6c..08990cb2 100644 --- a/firmware/main/modules/gps/wardriving/wardriving_module.c +++ b/firmware/main/modules/gps/wardriving/wardriving_module.c @@ -1,4 +1,5 @@ #include +#include "esp_heap_caps.h" #include "esp_log.h" #include "esp_timer.h" #include "freertos/FreeRTOS.h" @@ -28,8 +29,8 @@ #define MAC_ADDRESS_FORMAT "%02x:%02x:%02x:%02x:%02x:%02x" #define EMPTY_MAC_ADDRESS "00:00:00:00:00:00" -#define MAX_CSV_LINES 500 -#define CSV_LINE_SIZE 200 // Got it from real time tests +#define MAX_CSV_LINES 200 +#define CSV_LINE_SIZE 150 // Got it from real time tests #define CSV_FILE_SIZE CSV_LINE_SIZE* MAX_CSV_LINES #define CSV_HEADER_LINES 2 // Check `csv_header` variable @@ -119,6 +120,19 @@ void wardriving_module_scan_task(void* pvParameters) { } } +void update_file_name(char* full_date_time) { + sprintf(csv_file_name, "%s_%s.csv", FILE_NAME, full_date_time); + // Replace " " by "_" and ":" by "-" + for (int i = 0; i < strlen(csv_file_name); i++) { + if (csv_file_name[i] == ' ') { + csv_file_name[i] = '_'; + } + if (csv_file_name[i] == ':') { + csv_file_name[i] = '-'; + } + } +} + /** * @brief Save the scanned AP records to a CSV file * @@ -133,7 +147,7 @@ void wardriving_module_save_to_file(gps_t* gps) { esp_err_t err = sd_card_create_dir(DIR_NAME); if (err != ESP_OK) { - ESP_LOGE(TAG, "Failed to create directory"); + ESP_LOGE(TAG, "Failed to create %s directory", DIR_NAME); return; } @@ -142,24 +156,14 @@ void wardriving_module_save_to_file(gps_t* gps) { // Append records to csv file buffer for (int i = 0; i < ap_records->count; i++) { - csv_lines++; - wifi_scanned_packets++; + // TODO: Free memory char* mac_address_str = get_mac_address(ap_records->records[i].bssid); char* auth_mode_str = get_auth_mode(ap_records->records[i].authmode); char* full_date_time = get_full_date_time(gps); // +1 because there is a csv_lines++ before this - if (csv_lines == CSV_HEADER_LINES + 1) { - sprintf(csv_file_name, "%s_%s.csv", FILE_NAME, full_date_time); - // Replace " " by "_" and ":" by "-" - for (int i = 0; i < strlen(csv_file_name); i++) { - if (csv_file_name[i] == ' ') { - csv_file_name[i] = '_'; - } - if (csv_file_name[i] == ':') { - csv_file_name[i] = '-'; - } - } + if (csv_lines == CSV_HEADER_LINES) { + update_file_name(full_date_time); } if (csv_lines >= MAX_CSV_LINES) { @@ -167,9 +171,19 @@ void wardriving_module_save_to_file(gps_t* gps) { sd_card_write_file(csv_file_name, csv_file_buffer); csv_lines = CSV_HEADER_LINES; free(csv_file_buffer); - csv_file_buffer = malloc(CSV_FILE_SIZE); + + ESP_LOGI(TAG, "Free heap size before allocation: %" PRIu32 " bytes", + esp_get_free_heap_size()); + ESP_LOGI(TAG, "Allocating %d bytes for csv_file_buffer", CSV_FILE_SIZE); + csv_file_buffer = malloc(CSV_FILE_SIZE); // Here does not work + if (csv_file_buffer == NULL) { + ESP_LOGE(TAG, "Failed to allocate memory for csv_file_buffer"); + return; + } + sprintf(csv_file_buffer, "%s\n", csv_header); // Append header to csv file + continue; } if (strcmp(mac_address_str, EMPTY_MAC_ADDRESS) == 0) { @@ -214,7 +228,9 @@ void wardriving_module_save_to_file(gps_t* gps) { // ESP_LOGI(TAG, "CSV Line: %s", csv_line_buffer); // ESP_LOGI(TAG, "Line size %d bytes", strlen(csv_line_buffer)); - strcat(csv_file_buffer, csv_line_buffer); + strcat(csv_file_buffer, csv_line_buffer); // Append line to csv file + csv_lines++; + wifi_scanned_packets++; } free(csv_line_buffer); ESP_LOGI(TAG, "File size %d bytes, scanned packets: %u", @@ -241,10 +257,10 @@ void wardriving_gps_event_handler_cb(gps_t* gps) { gps->sats_in_use, gps_module_get_signal_strength(gps), gps->latitude, gps->longitude); - if (gps->sats_in_use == 0) { - wardriving_screens_module_no_gps_signal(); - return; - } + // if (gps->sats_in_use == 0) { + // wardriving_screens_module_no_gps_signal(); + // return; + // } if (counter % DISPLAY_REFRESH_RATE_SEC == 0 || counter == 1) { wardriving_screens_module_scanning(wifi_scanned_packets, @@ -269,6 +285,7 @@ esp_err_t wardriving_module_verify_sd_card() { return err; } +// TODO: return error code void wardriving_module_begin() { #if !defined(CONFIG_WARDRIVING_MODULE_DEBUG) esp_log_level_set(TAG, ESP_LOG_NONE); @@ -276,8 +293,22 @@ void wardriving_module_begin() { ESP_LOGI(TAG, "Wardriving module begin"); csv_lines = CSV_HEADER_LINES; wifi_scanned_packets = 0; - csv_file_buffer = malloc(CSV_FILE_SIZE); + + ESP_LOGI(TAG, "Free heap size before allocation: %" PRIu32 " bytes", + esp_get_free_heap_size()); + ESP_LOGI(TAG, "Allocating %d bytes for csv_file_buffer", CSV_FILE_SIZE); + csv_file_buffer = malloc(CSV_FILE_SIZE); // Here works + if (csv_file_buffer == NULL) { + ESP_LOGE(TAG, "Failed to allocate memory for csv_file_buffer"); + return; + } + csv_file_name = malloc(strlen(FILE_NAME) + 30); + if (csv_file_name == NULL) { + ESP_LOGE(TAG, "Failed to allocate memory for csv_file_name"); + return; + } + sprintf(csv_file_name, "%s.csv", FILE_NAME); sprintf(csv_file_buffer, "%s\n", csv_header); // Append header to csv file } From da1ae3c2212d6d563ee49357e86bb069a1644b77 Mon Sep 17 00:00:00 2001 From: deimos Date: Mon, 9 Sep 2024 15:06:03 -0600 Subject: [PATCH 11/22] fix: clear screen on 128x32 displays --- firmware/components/minino_config/Kconfig.projbuild | 2 +- firmware/main/drivers/oled_driver/oled_driver_i2c.c | 12 ++++++------ .../main/modules/gps/wardriving/wardriving_module.c | 8 ++++---- firmware/main/modules/menus_module/menus_screens.c | 2 +- firmware/main/modules/screen_saver/screen_saver.c | 11 +++++++++-- 5 files changed, 21 insertions(+), 14 deletions(-) diff --git a/firmware/components/minino_config/Kconfig.projbuild b/firmware/components/minino_config/Kconfig.projbuild index 438195ca..71524182 100644 --- a/firmware/components/minino_config/Kconfig.projbuild +++ b/firmware/components/minino_config/Kconfig.projbuild @@ -443,7 +443,7 @@ menu "OLED Screen Configuration" endmenu -menu "KEYBOARD Configuration" +menu "Keyboard Configuration" config GPIO_RANGE_MAX int diff --git a/firmware/main/drivers/oled_driver/oled_driver_i2c.c b/firmware/main/drivers/oled_driver/oled_driver_i2c.c index 9bea7d45..05e29e89 100644 --- a/firmware/main/drivers/oled_driver/oled_driver_i2c.c +++ b/firmware/main/drivers/oled_driver/oled_driver_i2c.c @@ -8,8 +8,6 @@ #include "oled_driver.h" -#define tag "oled_driver_i2c" - #if CONFIG_I2C_PORT_0 #define I2C_NUM I2C_NUM_0 #elif CONFIG_I2C_PORT_1 @@ -21,6 +19,8 @@ #define I2C_MASTER_FREQ_HZ \ 400000 /*!< I2C clock of SH1106 can run at 400 kHz max. */ +static const char* TAG = "oled_driver_i2c"; + void i2c_master_init(oled_driver_t* dev, int16_t sda, int16_t scl, @@ -105,9 +105,9 @@ void i2c_init(oled_driver_t* dev, int width, int height) { esp_err_t espRc = i2c_master_cmd_begin(I2C_NUM, cmd, 10 / portTICK_PERIOD_MS); if (espRc == ESP_OK) { - ESP_LOGI(tag, "OLED configured successfully"); + ESP_LOGI(TAG, "OLED configured successfully"); } else { - ESP_LOGE(tag, "OLED configuration failed. code: 0x%.2X", espRc); + ESP_LOGE(TAG, "OLED configuration failed. code: 0x%.2X", espRc); } i2c_cmd_link_delete(cmd); } @@ -260,9 +260,9 @@ void i2c_hardware_scroll(oled_driver_t* dev, oled_driver_scroll_type_t scroll) { i2c_master_stop(cmd); espRc = i2c_master_cmd_begin(I2C_NUM, cmd, 10 / portTICK_PERIOD_MS); if (espRc == ESP_OK) { - ESP_LOGD(tag, "Scroll command succeeded"); + ESP_LOGD(TAG, "Scroll command succeeded"); } else { - ESP_LOGE(tag, "Scroll command failed. code: 0x%.2X", espRc); + ESP_LOGE(TAG, "Scroll command failed. code: 0x%.2X", espRc); } i2c_cmd_link_delete(cmd); diff --git a/firmware/main/modules/gps/wardriving/wardriving_module.c b/firmware/main/modules/gps/wardriving/wardriving_module.c index 08990cb2..eca9e865 100644 --- a/firmware/main/modules/gps/wardriving/wardriving_module.c +++ b/firmware/main/modules/gps/wardriving/wardriving_module.c @@ -29,10 +29,10 @@ #define MAC_ADDRESS_FORMAT "%02x:%02x:%02x:%02x:%02x:%02x" #define EMPTY_MAC_ADDRESS "00:00:00:00:00:00" -#define MAX_CSV_LINES 200 #define CSV_LINE_SIZE 150 // Got it from real time tests -#define CSV_FILE_SIZE CSV_LINE_SIZE* MAX_CSV_LINES +#define CSV_FILE_SIZE (CSV_LINE_SIZE) * (MAX_CSV_LINES) #define CSV_HEADER_LINES 2 // Check `csv_header` variable +#define MAX_CSV_LINES 200 + CSV_HEADER_LINES #define WIFI_SCAN_REFRESH_RATE_MS 3000 #define DISPLAY_REFRESH_RATE_SEC 2 @@ -175,7 +175,7 @@ void wardriving_module_save_to_file(gps_t* gps) { ESP_LOGI(TAG, "Free heap size before allocation: %" PRIu32 " bytes", esp_get_free_heap_size()); ESP_LOGI(TAG, "Allocating %d bytes for csv_file_buffer", CSV_FILE_SIZE); - csv_file_buffer = malloc(CSV_FILE_SIZE); // Here does not work + csv_file_buffer = malloc(CSV_FILE_SIZE); if (csv_file_buffer == NULL) { ESP_LOGE(TAG, "Failed to allocate memory for csv_file_buffer"); return; @@ -297,7 +297,7 @@ void wardriving_module_begin() { ESP_LOGI(TAG, "Free heap size before allocation: %" PRIu32 " bytes", esp_get_free_heap_size()); ESP_LOGI(TAG, "Allocating %d bytes for csv_file_buffer", CSV_FILE_SIZE); - csv_file_buffer = malloc(CSV_FILE_SIZE); // Here works + csv_file_buffer = malloc(CSV_FILE_SIZE); if (csv_file_buffer == NULL) { ESP_LOGE(TAG, "Failed to allocate memory for csv_file_buffer"); return; diff --git a/firmware/main/modules/menus_module/menus_screens.c b/firmware/main/modules/menus_module/menus_screens.c index f19c9fc8..8dd90515 100644 --- a/firmware/main/modules/menus_module/menus_screens.c +++ b/firmware/main/modules/menus_module/menus_screens.c @@ -55,6 +55,6 @@ void menus_screens_display_menus_f(menus_manager_t* ctx) { #ifdef CONFIG_RESOLUTION_128X64 oled_screen_display_selected_item_box(); - oled_screen_display_show(); #endif + oled_screen_display_show(); } diff --git a/firmware/main/modules/screen_saver/screen_saver.c b/firmware/main/modules/screen_saver/screen_saver.c index 37805d5d..b3ba4e98 100644 --- a/firmware/main/modules/screen_saver/screen_saver.c +++ b/firmware/main/modules/screen_saver/screen_saver.c @@ -1,6 +1,7 @@ #include "screen_saver.h" #include "bitmaps_general.h" +#include "esp_log.h" #include "esp_timer.h" #include "freertos/FreeRTOS.h" #include "freertos/task.h" @@ -9,6 +10,7 @@ #include "preferences.h" static int IDLE_TIMEOUT_S = 30; +static const char* TAG = "screen_saver"; static volatile bool screen_saver_running; esp_timer_handle_t screen_savar_idle_timer2; @@ -38,13 +40,18 @@ static void show_splash_screen() { screen_saver_running = true; int w_screen_space = SCREEN_WIDTH2 - logo.width; int h_screen_space = SCREEN_HEIGHT2 - logo.height; + h_screen_space = h_screen_space == 0 ? 2 : h_screen_space; int start_x_position = w_screen_space / 2; +#if CONFIG_RESOLUTION_128X64 static int start_y_position = 16; - static int x_direction = 1; static int y_direction = 1; +#else + static int start_y_position = 0; + static int y_direction = 0; +#endif + static int x_direction = 1; while (screen_saver_running) { - // oled_screen_clear_buffer(); oled_screen_display_bitmap(logo.bitmap, start_x_position, start_y_position, logo.width, logo.height, OLED_DISPLAY_NORMAL); From 17c4d1c092a753ea36a0ad7822d8894e39ed22fb Mon Sep 17 00:00:00 2001 From: Roberto Arellano Date: Mon, 9 Sep 2024 17:07:17 -0600 Subject: [PATCH 12/22] feat: general submenus --- firmware/main/general/general_screens.c | 3 +- .../general/general_submenu/general_submenu.c | 80 +++++++++++++++++++ .../general/general_submenu/general_submenu.h | 17 ++++ .../main/modules/menus_module/menus_screens.c | 2 +- 4 files changed, 100 insertions(+), 2 deletions(-) create mode 100644 firmware/main/general/general_submenu/general_submenu.c create mode 100644 firmware/main/general/general_submenu/general_submenu.h diff --git a/firmware/main/general/general_screens.c b/firmware/main/general/general_screens.c index dac1a734..88ca3497 100644 --- a/firmware/main/general/general_screens.c +++ b/firmware/main/general/general_screens.c @@ -224,8 +224,9 @@ void genera_screen_display_card_information(char* title, char* body) { void genera_screen_display_notify_information(char* title, char* body) { general_clear_screen(); - general_screen_display_breadcrumb(); + // general_screen_display_breadcrumb(); int page = ITEM_PAGE_OFFSET; + oled_screen_display_card_border(); oled_screen_display_text_center(title, page, OLED_DISPLAY_NORMAL); page++; if (strlen(body) > MAX_LINE_CHAR) { diff --git a/firmware/main/general/general_submenu/general_submenu.c b/firmware/main/general/general_submenu/general_submenu.c new file mode 100644 index 00000000..13f05d74 --- /dev/null +++ b/firmware/main/general/general_submenu/general_submenu.c @@ -0,0 +1,80 @@ +#include "general_submenu.h" + +#include "bitmaps_general.h" +#include "menus_module.h" +#include "oled_screen.h" + +#ifdef CONFIG_RESOLUTION_128X64 + #define MAX_OPTIONS_NUM 8 +#else // CONFIG_RESOLUTION_128X32 + #define MAX_OPTIONS_NUM 4 +#endif + +static general_submenu_menu_t* general_radio_selection_ctx; + +static void list_submenu_options() { + general_submenu_menu_t* ctx = general_radio_selection_ctx; + static uint8_t items_offset = 0; + items_offset = MAX(ctx->selected_option - MAX_OPTIONS_NUM + 2, items_offset); + items_offset = + MIN(MAX(ctx->options_count - MAX_OPTIONS_NUM + 2, 0), items_offset); + items_offset = MIN(ctx->selected_option, items_offset); + oled_screen_clear_buffer(); + char* str = malloc(20); + for (uint8_t i = 0; i < (MIN(ctx->options_count, MAX_OPTIONS_NUM - 1)); i++) { + bool is_selected = i + items_offset == ctx->selected_option; + sprintf(str, "%s", ctx->options[i + items_offset]); + oled_screen_display_text(str, 0, i + 1, is_selected); + } + oled_screen_display_show(); + free(str); +} + +static void input_cb(uint8_t button_name, uint8_t button_event) { + if (button_event != BUTTON_PRESS_DOWN) { + return; + } + switch (button_name) { + case BUTTON_LEFT: + void (*exit_cb)() = general_radio_selection_ctx->exit_cb; + free(general_radio_selection_ctx); + if (exit_cb) { + exit_cb(); + } + break; + case BUTTON_RIGHT: + void (*select_cb)() = general_radio_selection_ctx->select_cb; + if (select_cb) { + select_cb(general_radio_selection_ctx->selected_option); + } + break; + case BUTTON_UP: + general_radio_selection_ctx->selected_option = + general_radio_selection_ctx->selected_option == 0 + ? general_radio_selection_ctx->options_count - 1 + : general_radio_selection_ctx->selected_option - 1; + list_submenu_options(); + break; + case BUTTON_DOWN: + general_radio_selection_ctx->selected_option = + ++general_radio_selection_ctx->selected_option < + general_radio_selection_ctx->options_count + ? general_radio_selection_ctx->selected_option + : 0; + list_submenu_options(); + break; + default: + break; + } +} + +void general_submenu(general_submenu_menu_t radio_selection_menu) { + general_radio_selection_ctx = calloc(1, sizeof(general_submenu_menu_t)); + general_radio_selection_ctx->options = radio_selection_menu.options; + general_radio_selection_ctx->options_count = + radio_selection_menu.options_count; + general_radio_selection_ctx->select_cb = radio_selection_menu.select_cb; + general_radio_selection_ctx->exit_cb = radio_selection_menu.exit_cb; + menus_module_set_app_state(true, input_cb); + list_submenu_options(); +} \ No newline at end of file diff --git a/firmware/main/general/general_submenu/general_submenu.h b/firmware/main/general/general_submenu/general_submenu.h new file mode 100644 index 00000000..d0f7f5c4 --- /dev/null +++ b/firmware/main/general/general_submenu/general_submenu.h @@ -0,0 +1,17 @@ +#pragma once + +#include +#include +#include "general_screens.h" + +typedef void (*submenu_selection_handler_t)(uint8_t); + +typedef struct { + uint8_t options_count; + char** options; + uint8_t selected_option; + submenu_selection_handler_t* select_cb; + void* exit_cb; +} general_submenu_menu_t; + +void general_submenu(general_submenu_menu_t radio_selection_menu); \ No newline at end of file diff --git a/firmware/main/modules/menus_module/menus_screens.c b/firmware/main/modules/menus_module/menus_screens.c index f19c9fc8..8dd90515 100644 --- a/firmware/main/modules/menus_module/menus_screens.c +++ b/firmware/main/modules/menus_module/menus_screens.c @@ -55,6 +55,6 @@ void menus_screens_display_menus_f(menus_manager_t* ctx) { #ifdef CONFIG_RESOLUTION_128X64 oled_screen_display_selected_item_box(); - oled_screen_display_show(); #endif + oled_screen_display_show(); } From 6273d97ebdd49fd07fa788d87aa98cf9727a42a6 Mon Sep 17 00:00:00 2001 From: Kevin Jahaziel Leon Morales Date: Tue, 10 Sep 2024 15:09:47 -0600 Subject: [PATCH 13/22] feat: Add bitmaps --- firmware/main/general/bitmaps_general.h | 22 +++++++++++++++++++ .../main/modules/oled_screen/oled_screen.c | 4 ++-- 2 files changed, 24 insertions(+), 2 deletions(-) diff --git a/firmware/main/general/bitmaps_general.h b/firmware/main/general/bitmaps_general.h index f30fe5d7..187f4b21 100644 --- a/firmware/main/general/bitmaps_general.h +++ b/firmware/main/general/bitmaps_general.h @@ -90,6 +90,28 @@ static const unsigned char epd_bitmap_electroniccats[] = { 0x7f, 0xff, 0xff, 0xfe, 0x7e, 0x7f, 0xfe, 0x7e, 0x78, 0x3f, 0xfc, 0x1e, 0x30, 0x0f, 0xf0, 0x0c, 0x30, 0x03, 0xc0, 0x0c}; +// 'arrow_left', 16x16px +static const unsigned char epd_bitmap_arrow_left[] = { + 0x01, 0x80, 0x03, 0x80, 0x07, 0x80, 0x0f, 0x80, 0x1f, 0x80, 0x3f, + 0x80, 0x7f, 0x80, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x80, 0x3f, 0x80, + 0x1f, 0x80, 0x0f, 0x80, 0x07, 0x80, 0x03, 0x80, 0x01, 0x80}; +// 'arrow_right', 16x16px +static const unsigned char epd_bitmap_arrow_right[] = { + 0x01, 0x80, 0x01, 0xc0, 0x01, 0xe0, 0x01, 0xf0, 0x01, 0xf8, 0x01, + 0xfc, 0x01, 0xfe, 0xff, 0xff, 0xff, 0xff, 0x01, 0xfe, 0x01, 0xfc, + 0x01, 0xf8, 0x01, 0xf0, 0x01, 0xe0, 0x01, 0xc0, 0x01, 0x80}; +// 'arrow_up', 16x16px +static const unsigned char + epd_bitmap_arrow_up[] = {0x01, 0x80, 0x03, 0xc0, 0x07, 0xe0, 0x0f, + 0xf0, 0x1f, 0xf8, 0x3f, 0xfc, 0x7f, 0xfe, + 0xff, 0xff, 0xff, 0xff, 0x01, 0x80, 0x01, + 0x80, 0x01, 0x80, 0x01, 0x80, 0x01, 0x80, + 0x00, 0x00, 0x00, 0x00}; // 'arrow_down', 16x16px +static const unsigned char epd_bitmap_arrow_down[] = { + 0x01, 0x80, 0x01, 0x80, 0x01, 0x80, 0x01, 0x80, 0x01, 0x80, 0x01, + 0x80, 0x01, 0x80, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0x3f, 0xfc, + 0x1f, 0xf8, 0x0f, 0xf0, 0x07, 0xe0, 0x03, 0xc0, 0x01, 0x80}; + unsigned char* epd_startup_logo[] = {epd_bitmap_minino_text_logo, epd_bitmap_face_logo}; diff --git a/firmware/main/modules/oled_screen/oled_screen.c b/firmware/main/modules/oled_screen/oled_screen.c index 01d094c2..7a26ef82 100644 --- a/firmware/main/modules/oled_screen/oled_screen.c +++ b/firmware/main/modules/oled_screen/oled_screen.c @@ -149,8 +149,8 @@ void oled_screen_display_text_splited(char* p_text, int* p_started_page, int invert) { if (strlen(p_text) > MAX_LINE_CHAR) { - char temp[50]; - strncpy(temp, p_text, 50); + char temp[100]; + strncpy(temp, p_text, 100); char* token = strtok(temp, " "); char current_line[MAX_LINE_CHAR] = ""; From 5efa284398df91ba1ea2e1b424eb2ae63e3113a7 Mon Sep 17 00:00:00 2001 From: Roberto Arellano Date: Fri, 13 Sep 2024 12:02:07 -0600 Subject: [PATCH 14/22] feat: simple arrows bitmaps --- firmware/main/general/bitmaps_general.h | 16 ++++++++++++++++ .../main/modules/menus_module/menus_module.c | 5 +++++ .../main/modules/menus_module/menus_module.h | 3 ++- 3 files changed, 23 insertions(+), 1 deletion(-) diff --git a/firmware/main/general/bitmaps_general.h b/firmware/main/general/bitmaps_general.h index 187f4b21..6cb6c472 100644 --- a/firmware/main/general/bitmaps_general.h +++ b/firmware/main/general/bitmaps_general.h @@ -112,6 +112,22 @@ static const unsigned char epd_bitmap_arrow_down[] = { 0x80, 0x01, 0x80, 0xff, 0xff, 0xff, 0xff, 0x7f, 0xfe, 0x3f, 0xfc, 0x1f, 0xf8, 0x0f, 0xf0, 0x07, 0xe0, 0x03, 0xc0, 0x01, 0x80}; +static const unsigned char* arrows_bitmap_arr[] = { + epd_bitmap_arrow_left, epd_bitmap_arrow_right, epd_bitmap_arrow_up, + epd_bitmap_arrow_down}; +// simple_left_arrow 8x8 +static const unsigned char simple_left_arrow_bmp[] = {0x08, 0x10, 0x20, 0x40, + 0x40, 0x20, 0x10, 0x08}; +// simple_right_arrow 8x8 +static const unsigned char simple_right_arrow_bmp[] = {0x10, 0x08, 0x04, 0x02, + 0x02, 0x04, 0x08, 0x10}; +// simple_up_arrow 8x8 +static const unsigned char simple_up_arrow_bmp[] = {0x00, 0x18, 0x24, 0x42, + 0x81, 0x00, 0x00, 0x00}; +// simple_down_arrow 8x8 +static const unsigned char simple_down_arrow_bmp[] = {0x00, 0x00, 0x00, 0x81, + 0x42, 0x24, 0x18, 0x00}; + unsigned char* epd_startup_logo[] = {epd_bitmap_minino_text_logo, epd_bitmap_face_logo}; diff --git a/firmware/main/modules/menus_module/menus_module.c b/firmware/main/modules/menus_module/menus_module.c index b17bba04..9f063eac 100644 --- a/firmware/main/modules/menus_module/menus_module.c +++ b/firmware/main/modules/menus_module/menus_module.c @@ -209,6 +209,11 @@ void menus_module_restart() { esp_restart(); } +void menus_module_reset() { + preferences_put_int("MENUNUMBER", menus_ctx->parent_menu_idx); + esp_restart(); +} + void menus_module_exit_app() { menus_module_set_app_state(false, menus_input_cb); screen_saver_get_idle_state(); diff --git a/firmware/main/modules/menus_module/menus_module.h b/firmware/main/modules/menus_module/menus_module.h index 16607e37..a701ea52 100644 --- a/firmware/main/modules/menus_module/menus_module.h +++ b/firmware/main/modules/menus_module/menus_module.h @@ -32,4 +32,5 @@ void menus_module_set_reset_screen(menu_idx_t menu); void menus_module_set_menu(menu_idx_t menu_idx); void menus_module_hide_menu(menu_idx_t menu_idx); void menus_module_reveal_menu(menu_idx_t menu_idx); -void menus_module_refresh(); \ No newline at end of file +void menus_module_refresh(); +void menus_module_reset(); \ No newline at end of file From 01006e44a69b806ec97839d6e2d4bf68b5bfefda Mon Sep 17 00:00:00 2001 From: deimos Date: Tue, 17 Sep 2024 07:08:04 -0600 Subject: [PATCH 15/22] refactor: change minino text logo aspect ratio --- firmware/main/general/bitmaps_general.h | 45 ++++++++++++------------ firmware/resources/minino-logo.png | Bin 0 -> 1502 bytes firmware/resources/minino-logo.xcf | Bin 0 -> 5108 bytes 3 files changed, 23 insertions(+), 22 deletions(-) create mode 100644 firmware/resources/minino-logo.png create mode 100644 firmware/resources/minino-logo.xcf diff --git a/firmware/main/general/bitmaps_general.h b/firmware/main/general/bitmaps_general.h index 187f4b21..329cad71 100644 --- a/firmware/main/general/bitmaps_general.h +++ b/firmware/main/general/bitmaps_general.h @@ -12,28 +12,29 @@ typedef struct { uint8_t width; uint8_t height; } epd_bitmap_t; -// 'logo-1', 64x32 -static const unsigned char epd_bitmap_minino_text_logo[] = { - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00,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x8f, 0xf8, - 0x3f, 0x79, 0xe7, 0x3e, 0x39, 0xcf, 0x8f, 0xf8, 0x77, 0x71, 0xc7, 0x3e, - 0x79, 0xc7, 0x8f, 0xf8, 0x77, 0x71, 0xc7, 0x3c, 0x71, 0xc7, 0x8f, 0xf0, - 0x76, 0x71, 0xc7, 0x1c, 0x71, 0xc7, 0x8f, 0xf0, 0x76, 0x71, 0xc7, 0x1c, - 0x71, 0xc7, 0x07, 0xf0, 0x72, 0x71, 0xc7, 0x1c, 0x71, 0xc7, 0x03, 0xe0, + +// 'minino-logo', 64x32px +const unsigned char epd_bitmap_minino_text_logo[] = { + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x7f, 0x09, 0xc7, 0xe2, 0x78, 0xf8, 0x9f, 0xf8, 0x3f, 0x0c, 0xe3, 0xf3, + 0x3c, 0x7c, 0xcf, 0xfc, 0x1f, 0x1c, 0xf9, 0xf3, 0x3e, 0x3c, 0xc7, 0xfe, + 0x1f, 0x3e, 0x79, 0xf3, 0x9e, 0x3c, 0xe3, 0x9e, 0x0f, 0x7e, 0x79, 0xf7, + 0x9e, 0x3d, 0xe3, 0x0e, 0x1f, 0x7c, 0xf9, 0xff, 0xbe, 0x7f, 0xe7, 0x1e, + 0x1f, 0xfc, 0xf3, 0xff, 0x3c, 0x7f, 0xe7, 0x1c, 0x3f, 0xfc, 0xf3, 0xff, + 0x3c, 0xff, 0xce, 0x1c, 0x3f, 0xfc, 0xf3, 0xbf, 0x3c, 0xef, 0xce, 0x3c, + 0x3f, 0xb9, 0xe7, 0xbe, 0x78, 0xef, 0x8f, 0x78, 0x7b, 0xb9, 0xe7, 0x9e, + 0x79, 0xe7, 0x8f, 0xf8, 0x7b, 0x39, 0xef, 0x1e, 0x79, 0xc7, 0x8f, 0xf0, + 0x72, 0x70, 0xcf, 0x1c, 0x31, 0xc7, 0x07, 0xe0, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; diff --git a/firmware/resources/minino-logo.png b/firmware/resources/minino-logo.png new file mode 100644 index 0000000000000000000000000000000000000000..866963bd88702e2d71ed09b8c5b24d0cc72d5b3e GIT binary patch literal 1502 zcmV<41tI#0P)EX>4Tx04R}tkv&MmKpe$iTcs)$5j%(|1gTDTQ4z;lg(6f4wL+^7CYOFelZGV4 z#ZhoAIQX$xb#QUk)xlK|1V2EW9h?+hq{ROvg%&X$9QWhhy~o`)J&;^Mfxh}i>#<}3IpJ#@RbZVYBOe_@ISZ-rhG*seg;)tSZl<&{D ztZ?4qtd^^+c~AbrP)=J}<~q$`B(R7jh!7y7iW17O5T#Wk#YBqs;~xGY$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4H!A;7HCh{iOtv)h< zjyF^OvPH^|@xtNWa#$*mE|D5#hH(=&D>YK20xo`>53{m7Y?PzJZL>I3y=C!XvoyMiZz+|Y5_}6Q$-U&vB6vR z1FAxqMzG}CL68?grE+z@`;K0zUmf~JrSdf~3=x+Rms_MkRU+`mLpBQ%?#iV~hxl+INv|~K@bd?A{PY1Ejeg=%N8T%wfBAT!qsa(-zL7ouFH!M zfwj`n#Zo%6KIf#fj+5QMv&@MHa?EL@IeLmLi`4-Pt`b}%nxRNwReie^MY^`YWfR?$sXKUGMhaTIRfs`3vC=@21}mh3-cI#ONS z1A;ovK&lnhO$+{9i)wsKs^XKvdY!WRVFP=ZiGRBAey$kwd-H379e@T?KPj^7c9mXP z)mFhhaNpoYwEvIb9@AtqiB|3I!oM^PO&eOeq+G#w&0CsQ%V_drG>H+K#GAy_yeU^S zYC4GtO{ct-@8Y1wQ!b$AyQ$UD3O3M~uF#PSS}lwAQrC!~)t!b7t@e>Rhsiu>)Tc5n zt}PHPT;-8Xbd%V^E$v1YOgEQ7TrkjD*3fZAi`2(Pky5tCWEe~8IH7T^Pohg*p{BH! zB9zRD8FXk;cY2FyV1PL|V_92(nK7cxCF`%&TWqi}_jWuc6^1 z_t%~840HybT=)0?F%UdJyT8u;1$gHf1LCz7xxcq&O}ns8Ggra*>9UMRy5Iu)<1#qM z03IOy(&VYhiMi>SGv2ZB*;hd6T(tV*%LULj5`C0*AO6P|4>E1#HK&ayFlPYmFBV&Y p((f_NV(ohJf5Ku6-~rlu`M&}0JYzt-)*`>ynw3xFzX5QyvtR%K literal 0 HcmV?d00001 From 72f96d593d4ca1523f5e54d7b9aab11510d59486 Mon Sep 17 00:00:00 2001 From: Kevin Jahaziel Leon Morales Date: Wed, 18 Sep 2024 19:59:42 -0600 Subject: [PATCH 16/22] feat: Fix screens --- .../components/wifi_captive/captive_portal.c | 2 +- firmware/main/apps/ble/spam/spam_screens.c | 13 +++-- .../main/apps/ble/trackers/trackers_screens.c | 2 +- .../main/apps/wifi/deauth/deauth_screens.c | 45 +++++++++++++---- firmware/main/general/general_screens.c | 49 +++++-------------- firmware/main/general/general_screens.h | 2 +- 6 files changed, 59 insertions(+), 54 deletions(-) diff --git a/firmware/components/wifi_captive/captive_portal.c b/firmware/components/wifi_captive/captive_portal.c index 0ff90e16..5b06c9c6 100644 --- a/firmware/components/wifi_captive/captive_portal.c +++ b/firmware/components/wifi_captive/captive_portal.c @@ -146,7 +146,7 @@ esp_err_t http_404_error_handler(httpd_req_t* req, httpd_err_code_t err) { static httpd_handle_t start_webserver(void) { httpd_handle_t server = NULL; httpd_config_t config = HTTPD_DEFAULT_CONFIG(); - config.max_open_sockets = 10; + config.max_open_sockets = 7; config.lru_purge_enable = true; // Start the httpd server diff --git a/firmware/main/apps/ble/spam/spam_screens.c b/firmware/main/apps/ble/spam/spam_screens.c index f7c1877d..b9c66f27 100644 --- a/firmware/main/apps/ble/spam/spam_screens.c +++ b/firmware/main/apps/ble/spam/spam_screens.c @@ -12,11 +12,18 @@ static void ble_screens_display_scanning_animation() { void ble_screens_start_scanning_animation() { oled_screen_clear(); - oled_screen_display_text_center("BLE SPAM", 0, OLED_DISPLAY_NORMAL); + oled_screen_display_text_center("< Back", 0, OLED_DISPLAY_NORMAL); + oled_screen_display_text_center("BLE SPAM", 1, OLED_DISPLAY_NORMAL); +#ifdef CONFIG_RESOLUTION_128X64 animations_task_run(ble_screens_display_scanning_animation, 100, NULL); +#endif } void ble_screens_display_scanning_text(char* name) { - oled_screen_clear_line(0, 7, OLED_DISPLAY_NORMAL); - oled_screen_display_text_center(name, 7, OLED_DISPLAY_INVERT); + int page = 7; +#ifdef CONFIG_RESOLUTION_128X32 + page = 2; +#endif + oled_screen_clear_line(0, page, OLED_DISPLAY_NORMAL); + oled_screen_display_text_center(name, page, OLED_DISPLAY_INVERT); } diff --git a/firmware/main/apps/ble/trackers/trackers_screens.c b/firmware/main/apps/ble/trackers/trackers_screens.c index 3da54fb3..e7a74d6e 100644 --- a/firmware/main/apps/ble/trackers/trackers_screens.c +++ b/firmware/main/apps/ble/trackers/trackers_screens.c @@ -54,7 +54,7 @@ void module_update_tracker_name(char* tracker_name, uint16_t index) { void module_display_scanning() { led_control_run_effect(led_control_pulse_leds); - genera_screen_display_notify_information("Searching", "Looking for devices"); + genera_screen_display_notify_information("Searching", "Devices"); } void module_display_tracker_information(char* title, char* body) { diff --git a/firmware/main/apps/wifi/deauth/deauth_screens.c b/firmware/main/apps/wifi/deauth/deauth_screens.c index 7d0b746c..4c462f67 100644 --- a/firmware/main/apps/wifi/deauth/deauth_screens.c +++ b/firmware/main/apps/wifi/deauth/deauth_screens.c @@ -4,9 +4,16 @@ #include "animations_task.h" #include "esp_wifi.h" #include "general/bitmaps_general.h" +#include "general/general_screens.h" #include "oled_screen.h" -#define ITEMOFFSET 2 +#ifdef CONFIG_RESOLUTION_128X64 + #define ITEMOFFSET 2 + #define ITEMSPERSCREEN 4 +#else // CONFIG_RESOLUTION_128X32 + #define ITEMOFFSET 1 + #define ITEMSPERSCREEN 2 +#endif static int ap_count = 0; @@ -63,8 +70,10 @@ void deauth_display_menu(uint16_t current_item, oled_screen_display_text("< Exit", 0, 0, OLED_DISPLAY_NORMAL); int position = 1; + uint16_t start_item = (current_item / ITEMSPERSCREEN) * ITEMSPERSCREEN; - for (uint16_t i = 0; i < MENUCOUNT; i++) { + for (uint16_t i = start_item; + i < start_item + ITEMSPERSCREEN && i < MENUCOUNT; i++) { if (deauth_menu[i] == NULL) { break; } @@ -93,7 +102,7 @@ void deauth_display_menu(uint16_t current_item, } else { oled_screen_display_text(item, 0, position, OLED_DISPLAY_NORMAL); } - position = position + 2; + position = position + ITEMOFFSET; } oled_screen_display_show(); } @@ -111,16 +120,19 @@ void deauth_display_scanned_ap(wifi_ap_record_t* ap_records, if (i >= scanned_records) { break; } + char ssid[MAX_LINE_CHAR]; + general_screen_truncate_text((char*) ap_records[i].ssid, ssid); if (i == current_option) { char* prefix = "> "; - char item_text[strlen(prefix) + strlen((char*) ap_records[i].ssid) + 1]; + + char item_text[strlen(prefix) + strlen((char*) ssid) + 1]; strcpy(item_text, prefix); - strcat(item_text, (char*) ap_records[i].ssid); + strcat(item_text, (char*) ssid); oled_screen_display_text(item_text, 0, (i + 1) - current_option, OLED_DISPLAY_INVERT); } else { - oled_screen_display_text((char*) ap_records[i].ssid, 0, - (i + 1) - current_option, OLED_DISPLAY_NORMAL); + oled_screen_display_text((char*) ssid, 0, (i + 1) - current_option, + OLED_DISPLAY_NORMAL); } } oled_screen_display_show(); @@ -131,7 +143,11 @@ void deauth_display_attacks(uint16_t current_item, oled_screen_clear_buffer(); oled_screen_display_text("< Back", 0, 0, OLED_DISPLAY_NORMAL); - for (uint16_t i = 0; i < ATTACKSCOUNT; i++) { + int position = 1; + uint16_t start_item = (current_item / ITEMSPERSCREEN) * ITEMSPERSCREEN; + + for (uint16_t i = start_item; + i < start_item + ITEMSPERSCREEN && i < MENUCOUNT; i++) { if (deauth_attacks[i] == NULL) { break; } @@ -142,10 +158,11 @@ void deauth_display_attacks(uint16_t current_item, snprintf(item, 18, "%s", deauth_attacks[i]); } if (i == current_item) { - deauth_display_selected_item(item, i + ITEMOFFSET); + deauth_display_selected_item(item, position); } else { - oled_screen_display_text(item, 0, i + ITEMOFFSET, OLED_DISPLAY_NORMAL); + oled_screen_display_text(item, 0, position, OLED_DISPLAY_NORMAL); } + position = position + ITEMOFFSET; } oled_screen_display_show(); } @@ -182,6 +199,7 @@ void deauth_display_captive_waiting() { void deauth_display_captive_portal_creds(char* ssid, char* user, char* pass) { oled_screen_clear(); +#ifdef CONFIG_RESOLUTION_128X64 oled_screen_display_text_center("Captive Portal", 0, OLED_DISPLAY_NORMAL); oled_screen_display_text_center("SSID", 1, OLED_DISPLAY_NORMAL); oled_screen_display_text_center(ssid, 2, OLED_DISPLAY_NORMAL); @@ -191,4 +209,11 @@ void deauth_display_captive_portal_creds(char* ssid, char* user, char* pass) { oled_screen_display_text_center("PASS", 5, OLED_DISPLAY_NORMAL); oled_screen_display_text_center(pass, 6, OLED_DISPLAY_INVERT); } +#else // CONFIG_RESOLUTION_128X32 + oled_screen_display_text_center(ssid, 0, OLED_DISPLAY_NORMAL); + oled_screen_display_text_center(user, 1, OLED_DISPLAY_INVERT); + if (strcmp(pass, "") != 0) { + oled_screen_display_text_center(pass, 2, OLED_DISPLAY_INVERT); + } +#endif } \ No newline at end of file diff --git a/firmware/main/general/general_screens.c b/firmware/main/general/general_screens.c index 88ca3497..92e14fe0 100644 --- a/firmware/main/general/general_screens.c +++ b/firmware/main/general/general_screens.c @@ -26,45 +26,18 @@ static const general_menu_t card_info_menu_ctx = { .menu_level = GENERAL_TREE_APP_SUBMENU, }; -char** general_screen_truncate_text(char* p_text, int* num_lines) { - char** lines = NULL; - *num_lines = 0; - - if (strlen(p_text) > MAX_LINE_CHAR) { - char temp[50]; - strncpy(temp, p_text, 50); - - char* token = strtok(temp, " "); - char current_line[MAX_LINE_CHAR] = ""; - - while (token != NULL) { - if (strlen(current_line) + strlen(token) + 1 <= MAX_LINE_CHAR) { - if (strlen(current_line) > 0) { - strcat(current_line, " "); - } - strcat(current_line, token); - } else { - lines = realloc(lines, sizeof(char*) * (*num_lines + 1)); - lines[*num_lines] = strdup(current_line); - (*num_lines)++; - - strcpy(current_line, token); - } - token = strtok(NULL, " "); - } - - if (strlen(current_line) > 0) { - lines = realloc(lines, sizeof(char*) * (*num_lines + 1)); - lines[*num_lines] = strdup(current_line); - (*num_lines)++; - } - } else { - lines = realloc(lines, sizeof(char*) * (*num_lines + 1)); - lines[*num_lines] = strdup(p_text); - (*num_lines)++; +void general_screen_truncate_text(char* p_text, char* p_truncated_text) { + // Truncate the text if it is longer than the screen width and add 3 dots + char* p_truncated_text_ptr = p_truncated_text; + for (uint8_t i = 0; i < (MAX_LINE_CHAR - 3); i++) { + *p_truncated_text_ptr = *p_text; + p_text++; + p_truncated_text_ptr++; } - - return lines; // Regresar el array de líneas spliteadas + *p_truncated_text_ptr++ = '.'; + *p_truncated_text_ptr++ = '.'; + *p_truncated_text_ptr++ = '.'; + *p_truncated_text_ptr = '\0'; } static void general_screen_display_selected_item(char* item_text, diff --git a/firmware/main/general/general_screens.h b/firmware/main/general/general_screens.h index 15774bf7..1f39edb8 100644 --- a/firmware/main/general/general_screens.h +++ b/firmware/main/general/general_screens.h @@ -37,7 +37,7 @@ void general_screen_display_card_information_handler(char* title, void* callback_exit, void* callback_restore); void general_screen_display_scrolling_text_handler(void* callback_exit); -char** general_screen_truncate_text(char* p_text, int* num_lines); +void general_screen_truncate_text(char* p_text, char* p_truncated_text); void general_screen_display_auto_card(char* lines, int num_lines, void* callback_exit); From 615ba16a7771e2e0dfb8b634c5ea14c6b04f2bf7 Mon Sep 17 00:00:00 2001 From: deimos Date: Thu, 19 Sep 2024 10:07:34 -0600 Subject: [PATCH 17/22] feat: add wifi animation to wardriving --- .../modules/animations_task/animations_task.c | 10 +- .../modules/animations_task/animations_task.h | 19 +- .../gps/wardriving/wardriving_module.c | 36 +- .../wardriving/wardriving_screens_module.c | 30 +- .../wardriving/wardriving_screens_module.h | 16 +- .../main/modules/keyboard/keyboard_module.c | 31 +- firmware/main/modules/wifi/wifi_bitmaps.h | 320 ++++++++---------- .../main/modules/wifi/wifi_screens_module.c | 2 +- firmware/resources/loading-animation.xcf | Bin 9475 -> 0 bytes firmware/resources/wifi-loading-1.png | Bin 2035 -> 2342 bytes firmware/resources/wifi-loading-2.png | Bin 2018 -> 2337 bytes firmware/resources/wifi-loading-3.png | Bin 2104 -> 2426 bytes firmware/resources/wifi-loading-4.png | Bin 2040 -> 2383 bytes firmware/resources/wifi-loading.xcf | Bin 0 -> 11486 bytes 14 files changed, 248 insertions(+), 216 deletions(-) delete mode 100644 firmware/resources/loading-animation.xcf create mode 100644 firmware/resources/wifi-loading.xcf diff --git a/firmware/main/modules/animations_task/animations_task.c b/firmware/main/modules/animations_task/animations_task.c index fb3fd964..f75a1b4d 100644 --- a/firmware/main/modules/animations_task/animations_task.c +++ b/firmware/main/modules/animations_task/animations_task.c @@ -9,24 +9,26 @@ void (*animations_task_cb)(void*) = NULL; bool running = false; uint32_t delay_ms = 100; -static void animations_task(void* ctx) { +static void animations_task(void* pvParameters) { running = true; while (running) { if (animations_task_cb != NULL) { - animations_task_cb(ctx); + animations_task_cb(pvParameters); } vTaskDelay(pdMS_TO_TICKS(delay_ms)); } vTaskDelete(NULL); } -void animations_task_run(void* animation_cb, uint32_t period_ms, void* ctx) { +void animations_task_run(void* animation_cb, + uint32_t period_ms, + void* pvParameters) { if (preferences_get_bool("stealth_mode", false)) { return; } animations_task_cb = animation_cb; delay_ms = period_ms; - xTaskCreate(animations_task, "animations_task", 2048, ctx, 5, NULL); + xTaskCreate(animations_task, "animations_task", 2048, pvParameters, 5, NULL); } void animations_task_stop() { diff --git a/firmware/main/modules/animations_task/animations_task.h b/firmware/main/modules/animations_task/animations_task.h index cc113904..53bc5314 100644 --- a/firmware/main/modules/animations_task/animations_task.h +++ b/firmware/main/modules/animations_task/animations_task.h @@ -1,5 +1,22 @@ #pragma once #include -void animations_task_run(void* animation_cb, uint32_t period_ms, void* ctx); +/** + * @brief Run the given animation callback every `period_ms` milliseconds. + * + * @param animation_cb The callback to run. + * @param period_ms The period in milliseconds. + * @param pvParameters The parameters to pass to the callback. + * + * @return void + */ +void animations_task_run(void* animation_cb, + uint32_t period_ms, + void* pvParameters); + +/** + * @brief Stop the animations task. + * + * @return void + */ void animations_task_stop(); \ No newline at end of file diff --git a/firmware/main/modules/gps/wardriving/wardriving_module.c b/firmware/main/modules/gps/wardriving/wardriving_module.c index eca9e865..c267b223 100644 --- a/firmware/main/modules/gps/wardriving/wardriving_module.c +++ b/firmware/main/modules/gps/wardriving/wardriving_module.c @@ -49,6 +49,9 @@ const char* TAG = "wardriving"; wardriving_module_state_t wardriving_module_state = WARDRIVING_MODULE_STATE_STOPPED; TaskHandle_t wardriving_module_scan_task_handle = NULL; +TaskHandle_t scanning_wifi_animation_task_handle = NULL; +bool running_wifi_scanner_animation = false; + uint16_t csv_lines; uint16_t wifi_scanned_packets; char* csv_file_name = NULL; @@ -120,6 +123,13 @@ void wardriving_module_scan_task(void* pvParameters) { } } +/** + * @brief Update the file name where the scanned packets will be saved + * + * @param full_date_time The full date and time string + * + * @return void + */ void update_file_name(char* full_date_time) { sprintf(csv_file_name, "%s_%s.csv", FILE_NAME, full_date_time); // Replace " " by "_" and ":" by "-" @@ -156,12 +166,11 @@ void wardriving_module_save_to_file(gps_t* gps) { // Append records to csv file buffer for (int i = 0; i < ap_records->count; i++) { - // TODO: Free memory - char* mac_address_str = get_mac_address(ap_records->records[i].bssid); char* auth_mode_str = get_auth_mode(ap_records->records[i].authmode); + char* mac_address_str = get_mac_address(ap_records->records[i].bssid); char* full_date_time = get_full_date_time(gps); - // +1 because there is a csv_lines++ before this + // End of file reached, write to new file if (csv_lines == CSV_HEADER_LINES) { update_file_name(full_date_time); } @@ -258,10 +267,17 @@ void wardriving_gps_event_handler_cb(gps_t* gps) { gps->longitude); // if (gps->sats_in_use == 0) { + // vTaskSuspend(scanning_wifi_animation_task_handle); + // running_wifi_scanner_animation = false; // wardriving_screens_module_no_gps_signal(); // return; // } + if (!running_wifi_scanner_animation) { + vTaskResume(scanning_wifi_animation_task_handle); + } + running_wifi_scanner_animation = true; + if (counter % DISPLAY_REFRESH_RATE_SEC == 0 || counter == 1) { wardriving_screens_module_scanning(wifi_scanned_packets, gps_module_get_signal_strength(gps)); @@ -328,6 +344,12 @@ void wardriving_module_start_scan() { wardriving_module_state = WARDRIVING_MODULE_STATE_SCANNING; xTaskCreate(wardriving_module_scan_task, "wardriving_module_scan_task", 4096, NULL, 5, &wardriving_module_scan_task_handle); + xTaskCreate(wardriving_screens_wifi_animation_task, + "scanning_wifi_animation_task", 4096, NULL, 5, + &scanning_wifi_animation_task_handle); + vTaskSuspend(scanning_wifi_animation_task_handle); + running_wifi_scanner_animation = false; + gps_module_register_cb(wardriving_gps_event_handler_cb); wardriving_screens_module_loading_text(); gps_module_start_scan(); @@ -348,7 +370,13 @@ void wardriving_module_stop_scan() { if (wardriving_module_scan_task_handle != NULL) { vTaskDelete(wardriving_module_scan_task_handle); wardriving_module_scan_task_handle = NULL; - ESP_LOGI(TAG, "Task deleted"); + ESP_LOGI(TAG, "Task wardriving_module_scan_task deleted"); + } + + if (scanning_wifi_animation_task_handle != NULL) { + vTaskDelete(scanning_wifi_animation_task_handle); + scanning_wifi_animation_task_handle = NULL; + ESP_LOGI(TAG, "Task scanning_wifi_animation_task deleted"); } } diff --git a/firmware/main/modules/gps/wardriving/wardriving_screens_module.c b/firmware/main/modules/gps/wardriving/wardriving_screens_module.c index 66290b69..319573b7 100644 --- a/firmware/main/modules/gps/wardriving/wardriving_screens_module.c +++ b/firmware/main/modules/gps/wardriving/wardriving_screens_module.c @@ -1,10 +1,13 @@ #include +#include "esp_log.h" + #include "general_screens.h" #include "gps_bitmaps.h" #include "menus_module.h" #include "oled_screen.h" #include "wardriving_screens_module.h" +#include "wifi_bitmaps.h" char* wardriving_help_2[] = { "This tool", "allows you to", "scan for WiFi", @@ -23,16 +26,33 @@ void wardriving_screens_show_help() { general_screen_display_scrolling_text_handler(menus_module_exit_app); } +void wardriving_screens_wifi_animation_task() { + oled_screen_clear_buffer(); + + while (true) { + static uint8_t idx = 0; + oled_screen_display_bitmap(epd_bitmap_wifi_loading[idx], 0, 0, 56, 56, + OLED_DISPLAY_NORMAL); + idx = ++idx > 3 ? 0 : idx; + vTaskDelay(500 / portTICK_PERIOD_MS); + } +} + void wardriving_screens_module_scanning(uint32_t packets, char* signal) { char* packets_str = (char*) malloc(20); sprintf(packets_str, "%ld", packets); - oled_screen_clear_buffer(); - oled_screen_display_text("Packets", 64, 0, OLED_DISPLAY_INVERT); - oled_screen_display_text(packets_str, 64, 1, OLED_DISPLAY_INVERT); - oled_screen_display_text("Signal", 64, 3, OLED_DISPLAY_INVERT); - oled_screen_display_text(signal, 64, 4, OLED_DISPLAY_INVERT); + // oled_screen_clear_buffer(); + uint8_t x = 64; + uint8_t y = 0; + + oled_screen_display_text("Packets", x, y++, OLED_DISPLAY_INVERT); + oled_screen_display_text(packets_str, x, y++, OLED_DISPLAY_INVERT); + y++; + oled_screen_display_text("GPS", x, y++, OLED_DISPLAY_INVERT); + oled_screen_display_text(signal, x, y++, OLED_DISPLAY_INVERT); oled_screen_display_show(); + free(packets_str); } void wardriving_screens_module_loading_text() { diff --git a/firmware/main/modules/gps/wardriving/wardriving_screens_module.h b/firmware/main/modules/gps/wardriving/wardriving_screens_module.h index 44b82bdc..1f8bcefc 100644 --- a/firmware/main/modules/gps/wardriving/wardriving_screens_module.h +++ b/firmware/main/modules/gps/wardriving/wardriving_screens_module.h @@ -1,5 +1,19 @@ #pragma once +/** + * @brief Show the help screen + * + * @return void + */ +void wardriving_screens_show_help(); + +/** + * @brif Display the scanning wifi networks animation + * + * @return void + */ +void wardriving_screens_wifi_animation_task(); + /** * @brief Display the scanning screen * @@ -51,5 +65,3 @@ void wardriving_screens_module_formating_sd_card(); * @return void */ void wardriving_screens_module_failed_format_sd_card(); - -void wardriving_screens_show_help(); diff --git a/firmware/main/modules/keyboard/keyboard_module.c b/firmware/main/modules/keyboard/keyboard_module.c index c78661dc..0d10b316 100644 --- a/firmware/main/modules/keyboard/keyboard_module.c +++ b/firmware/main/modules/keyboard/keyboard_module.c @@ -12,6 +12,10 @@ esp_timer_handle_t idle_timer; static bool is_idle = false; static bool lock_input = false; +const char* button_to_name[] = { + "BOOT", "LEFT", "RIGHT", "UP", "DOWN", +}; + static void button_event_cb(void* arg, void* data); void keyboard_module_reset_idle_timer() { @@ -65,33 +69,22 @@ void button_init(uint32_t button_num, uint8_t mask) { * @return void */ static void button_event_cb(void* arg, void* data) { - uint8_t button_name = - (((button_event_t) data) >> 4); // >> 4 to get the button number - uint8_t button_event = - ((button_event_t) data) & - 0x0F; // & 0x0F to get the event number without the mask - // esp_timer_stop(idle_timer); - - // If we have an app with a custom handler, we call it + // >> 4 to get the button number + uint8_t button_name = (((button_event_t) data) >> 4); + // & 0x0F to get the event number without the mask + uint8_t button_event = ((button_event_t) data) & 0x0F; + // DO NOT REMOVE THIS LOG + ESP_LOGI(TAG, "Button %s event %d", button_to_name[button_name], + button_event); if (lock_input) { return; } + if (input_callback) { input_callback(button_name, button_event); return; } - - // IDLE_TIMEOUT_S = preferences_get_int("dp_time", 30); - // esp_timer_start_once(idle_timer, IDLE_TIMEOUT_S * 1000 * 1000); - // if (button_event != BUTTON_PRESS_DOWN) { - // return; - // } - - // if (is_idle) { - // is_idle = false; - // return; - // } } void keyboard_module_set_input_callback(input_callback_t input_cb) { diff --git a/firmware/main/modules/wifi/wifi_bitmaps.h b/firmware/main/modules/wifi/wifi_bitmaps.h index b8ef3705..bba20895 100644 --- a/firmware/main/modules/wifi/wifi_bitmaps.h +++ b/firmware/main/modules/wifi/wifi_bitmaps.h @@ -153,189 +153,149 @@ unsigned char* wifi_bitmap_attackallArray[4] = { wifi_bitmap_attackattack_1, wifi_bitmap_attackattack_2, wifi_bitmap_attackattack_3, wifi_bitmap_attackattack_4}; -// 'wifi-loading-1', 64x64px -static const unsigned char epd_bitmap_wifi_loading_1[] = { - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, - 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x3f, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0xff, - 0xfc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x07, 0x87, 0x80, 0x00, 0x00, - 0x00, 0x00, 0x38, 0x07, 0x80, 0xe0, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x07, - 0x80, 0x30, 0x00, 0x00, 0x00, 0x01, 0x80, 0x07, 0x80, 0x1c, 0x00, 0x00, - 0x00, 0x03, 0x00, 0x03, 0x00, 0x06, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, - 0x00, 0x03, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x01, 0x80, 0x00, - 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x30, 0x00, 0x00, - 0x00, 0x00, 0x60, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, - 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0xc0, 0x00, 0x00, - 0x00, 0x00, 0x18, 0x00, 0x00, 0x80, 0x00, 0x7f, 0xf0, 0x00, 0x08, 0x00, - 0x01, 0x80, 0x03, 0xff, 0xfe, 0x00, 0x0c, 0x00, 0x01, 0x80, 0x0f, 0xff, - 0xff, 0x80, 0x04, 0x00, 0x01, 0x00, 0x3f, 0xff, 0xff, 0xe0, 0x04, 0x00, - 0x03, 0x00, 0x7f, 0x00, 0x07, 0xf0, 0x06, 0x00, 0x02, 0x00, 0xfc, 0x00, - 0x01, 0xf8, 0x06, 0x00, 0x02, 0x01, 0xf0, 0x3f, 0xe0, 0x7c, 0x02, 0x00, - 0x02, 0x03, 0xe0, 0xff, 0xf8, 0x3e, 0x03, 0x00, 0x06, 0x03, 0xc3, 0xff, - 0xfe, 0x1e, 0x03, 0x00, 0x7f, 0xe1, 0x87, 0xff, 0xff, 0x0c, 0x3f, 0xf0, - 0xff, 0xf0, 0x0f, 0xe0, 0x3f, 0x80, 0x7f, 0xf8, 0xff, 0xf0, 0x1f, 0x80, - 0x0f, 0xc0, 0x7f, 0xf8, 0x7f, 0xe0, 0x3e, 0x07, 0x03, 0xe0, 0x3f, 0xf0, - 0x06, 0x00, 0x3c, 0x1f, 0xc1, 0xe0, 0x03, 0x00, 0x06, 0x00, 0x18, 0x3f, - 0xe0, 0xc0, 0x03, 0x00, 0x02, 0x00, 0x00, 0x7f, 0xf0, 0x00, 0x02, 0x00, - 0x02, 0x10, 0x00, 0xff, 0xf8, 0x00, 0x02, 0x00, 0x03, 0x18, 0x00, 0xf0, - 0x78, 0x00, 0x06, 0x00, 0x03, 0x1c, 0x00, 0x60, 0x30, 0x00, 0x06, 0x00, - 0x01, 0x0c, 0x00, 0x07, 0x00, 0x00, 0x04, 0x00, 0x01, 0x06, 0x00, 0x0f, - 0x80, 0x00, 0x04, 0x00, 0x01, 0x86, 0x00, 0x0f, 0x80, 0x00, 0x0c, 0x00, - 0x00, 0x83, 0x00, 0x0f, 0x80, 0x00, 0x08, 0x00, 0x00, 0xc3, 0x80, 0x07, - 0x00, 0x00, 0x18, 0x00, 0x00, 0x61, 0xc0, 0x00, 0x00, 0x00, 0x10, 0x00, - 0x00, 0x20, 0xe0, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x30, 0x70, 0x00, - 0x00, 0x00, 0x60, 0x00, 0x00, 0x18, 0x38, 0x00, 0x00, 0x00, 0xc0, 0x00, - 0x00, 0x0c, 0x1e, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x06, 0x07, 0x00, - 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x01, 0x83, 0x00, 0x06, 0x00, 0x00, - 0x00, 0x01, 0xc0, 0x07, 0x80, 0x0c, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x07, - 0x80, 0x38, 0x00, 0x00, 0x00, 0x00, 0x38, 0x07, 0x80, 0xe0, 0x00, 0x00, - 0x00, 0x00, 0x0f, 0x87, 0x87, 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0xff, - 0xfc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1f, 0xe0, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, - 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; +// 'wifi-loading-1', 56x56px +const unsigned char epd_bitmap_wifi_loading_1[] = { + 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0xff, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x3c, 0x3c, 0x78, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x3c, + 0x0e, 0x00, 0x00, 0x00, 0x03, 0x80, 0x3c, 0x03, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x3c, 0x01, 0xc0, 0x00, 0x00, 0x0c, 0x00, 0x18, 0x00, 0x60, 0x00, + 0x00, 0x18, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, + 0x18, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x40, 0x00, + 0x00, 0x00, 0x06, 0x00, 0x00, 0xc0, 0x03, 0xff, 0x80, 0x02, 0x00, 0x01, + 0x80, 0x1f, 0xff, 0xf0, 0x03, 0x00, 0x01, 0x00, 0x7f, 0xff, 0xfc, 0x01, + 0x00, 0x01, 0x01, 0xff, 0xff, 0xff, 0x01, 0x80, 0x03, 0x03, 0xf8, 0x00, + 0x3f, 0x80, 0x80, 0x02, 0x07, 0xe0, 0x00, 0x0f, 0xc0, 0x80, 0x06, 0x0f, + 0x81, 0xff, 0x03, 0xe0, 0xc0, 0x04, 0x1f, 0x07, 0xff, 0xc1, 0xf0, 0x40, + 0x04, 0x1e, 0x1f, 0xff, 0xf0, 0xf0, 0x40, 0x04, 0x0c, 0x3f, 0xff, 0xf8, + 0x60, 0x40, 0x7f, 0xc0, 0x7f, 0x01, 0xfc, 0x07, 0xfe, 0xff, 0xe0, 0xfc, + 0x00, 0x7e, 0x0f, 0xff, 0xff, 0xe1, 0xf0, 0x38, 0x1f, 0x0f, 0xff, 0x7f, + 0xc1, 0xe0, 0xfe, 0x0f, 0x07, 0xfe, 0x04, 0x00, 0xc1, 0xff, 0x06, 0x00, + 0x40, 0x04, 0x00, 0x03, 0xff, 0x80, 0x00, 0x40, 0x04, 0x80, 0x07, 0xff, + 0xc0, 0x00, 0x40, 0x04, 0xc0, 0x07, 0x83, 0xc0, 0x00, 0x40, 0x06, 0xe0, + 0x03, 0x01, 0x80, 0x00, 0xc0, 0x02, 0x60, 0x00, 0x38, 0x00, 0x00, 0x80, + 0x02, 0x30, 0x00, 0x7c, 0x00, 0x00, 0x80, 0x03, 0x30, 0x00, 0x7c, 0x00, + 0x01, 0x80, 0x01, 0x18, 0x00, 0x7c, 0x00, 0x01, 0x00, 0x01, 0x9c, 0x00, + 0x38, 0x00, 0x03, 0x00, 0x00, 0xce, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, + 0x47, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x63, 0x80, 0x00, 0x00, 0x0c, + 0x00, 0x00, 0x31, 0xc0, 0x00, 0x00, 0x18, 0x00, 0x00, 0x18, 0xf0, 0x00, + 0x00, 0x30, 0x00, 0x00, 0x0c, 0x38, 0x18, 0x00, 0x60, 0x00, 0x00, 0x07, + 0x0c, 0x3c, 0x00, 0xc0, 0x00, 0x00, 0x01, 0x80, 0x3c, 0x03, 0x80, 0x00, + 0x00, 0x00, 0xe0, 0x3c, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x3e, 0x3c, 0x78, + 0x00, 0x00, 0x00, 0x00, 0x07, 0xff, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00}; -// 'wifi-loading-2', 64x64px -static const unsigned char epd_bitmap_wifi_loading_2[] = { - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, - 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x3f, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0xff, - 0xfc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x07, 0x87, 0x80, 0x00, 0x00, - 0x00, 0x00, 0x38, 0x07, 0x80, 0xe0, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x07, - 0x80, 0x30, 0x00, 0x00, 0x00, 0x01, 0x80, 0x07, 0x80, 0x1c, 0x00, 0x00, - 0x00, 0x03, 0x00, 0x03, 0x00, 0x06, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, - 0x00, 0x03, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x01, 0x80, 0x00, - 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x30, 0x00, 0x00, - 0x00, 0x00, 0x60, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, - 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0xc0, 0x00, 0x00, - 0x00, 0x00, 0x18, 0x00, 0x00, 0x80, 0x00, 0x7f, 0xf0, 0x00, 0x08, 0x00, - 0x01, 0x80, 0x03, 0xff, 0xfe, 0x00, 0x0c, 0x00, 0x01, 0x80, 0x0f, 0xff, - 0xff, 0x80, 0x04, 0x00, 0x01, 0x00, 0x3f, 0xff, 0xff, 0xe0, 0x04, 0x00, - 0x03, 0x00, 0x7f, 0x00, 0x07, 0xf0, 0x06, 0x00, 0x02, 0x00, 0xfc, 0x00, - 0x01, 0xf8, 0x06, 0x00, 0x02, 0x01, 0xf0, 0x3f, 0xe0, 0x7c, 0x02, 0x00, - 0x02, 0x03, 0xe0, 0xff, 0xf8, 0x3e, 0x03, 0x00, 0x06, 0x03, 0xc3, 0xff, - 0xfe, 0x1e, 0x03, 0x00, 0x7f, 0xe1, 0x87, 0xff, 0xff, 0x0c, 0x3f, 0xf0, - 0xff, 0xf0, 0x0f, 0xe0, 0x3f, 0x80, 0x7f, 0xf8, 0xff, 0xf0, 0x1f, 0x80, - 0x0f, 0xc0, 0x7f, 0xf8, 0x7f, 0xe0, 0x3e, 0x07, 0x03, 0xe0, 0x3f, 0xf0, - 0x06, 0x00, 0x3c, 0x1f, 0xc1, 0xe0, 0x03, 0x00, 0x06, 0x00, 0x18, 0x3f, - 0xe0, 0xc0, 0x03, 0x00, 0x02, 0x00, 0x00, 0x7f, 0xf0, 0x00, 0x02, 0x00, - 0x02, 0x00, 0x00, 0xff, 0xf8, 0x00, 0x22, 0x00, 0x03, 0x00, 0x00, 0xf0, - 0x78, 0x00, 0x66, 0x00, 0x03, 0x00, 0x00, 0x60, 0x30, 0x00, 0x46, 0x00, - 0x01, 0x00, 0x00, 0x07, 0x00, 0x00, 0xc4, 0x00, 0x01, 0x00, 0x00, 0x0f, - 0x80, 0x01, 0x84, 0x00, 0x01, 0x80, 0x00, 0x0f, 0x80, 0x01, 0x8c, 0x00, - 0x00, 0x80, 0x00, 0x0f, 0x80, 0x03, 0x08, 0x00, 0x00, 0xc0, 0x00, 0x07, - 0x00, 0x06, 0x18, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x0e, 0x10, 0x00, - 0x00, 0x20, 0x00, 0x00, 0x00, 0x1c, 0x30, 0x00, 0x00, 0x30, 0x00, 0x00, - 0x00, 0x38, 0x60, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x70, 0xc0, 0x00, - 0x00, 0x0c, 0x00, 0x00, 0x00, 0xe1, 0x80, 0x00, 0x00, 0x06, 0x00, 0x00, - 0x03, 0x83, 0x00, 0x00, 0x00, 0x03, 0x00, 0x03, 0x07, 0x06, 0x00, 0x00, - 0x00, 0x01, 0xc0, 0x07, 0x80, 0x0c, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x07, - 0x80, 0x38, 0x00, 0x00, 0x00, 0x00, 0x38, 0x07, 0x80, 0xe0, 0x00, 0x00, - 0x00, 0x00, 0x0f, 0x87, 0x87, 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0xff, - 0xfc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1f, 0xe0, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, - 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; +// 'wifi-loading-2', 56x56px +const unsigned char epd_bitmap_wifi_loading_2[] = { + 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0xff, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x3c, 0x3c, 0x78, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x3c, + 0x0e, 0x00, 0x00, 0x00, 0x03, 0x80, 0x3c, 0x03, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x3c, 0x01, 0xc0, 0x00, 0x00, 0x0c, 0x00, 0x18, 0x00, 0x60, 0x00, + 0x00, 0x18, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, + 0x18, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x40, 0x00, + 0x00, 0x00, 0x06, 0x00, 0x00, 0xc0, 0x03, 0xff, 0x80, 0x02, 0x00, 0x01, + 0x80, 0x1f, 0xff, 0xf0, 0x03, 0x00, 0x01, 0x00, 0x7f, 0xff, 0xfc, 0x01, + 0x00, 0x01, 0x01, 0xff, 0xff, 0xff, 0x01, 0x80, 0x03, 0x03, 0xf8, 0x00, + 0x3f, 0x80, 0x80, 0x02, 0x07, 0xe0, 0x00, 0x0f, 0xc0, 0x80, 0x06, 0x0f, + 0x81, 0xff, 0x03, 0xe0, 0xc0, 0x04, 0x1f, 0x07, 0xff, 0xc1, 0xf0, 0x40, + 0x04, 0x1e, 0x1f, 0xff, 0xf0, 0xf0, 0x40, 0x04, 0x0c, 0x3f, 0xff, 0xf8, + 0x60, 0x40, 0x7f, 0xc0, 0x7f, 0x01, 0xfc, 0x07, 0xfe, 0xff, 0xe0, 0xfc, + 0x00, 0x7e, 0x0f, 0xff, 0xff, 0xe1, 0xf0, 0x38, 0x1f, 0x0f, 0xff, 0x7f, + 0xc1, 0xe0, 0xfe, 0x0f, 0x07, 0xfe, 0x04, 0x00, 0xc1, 0xff, 0x06, 0x00, + 0x40, 0x04, 0x00, 0x03, 0xff, 0x80, 0x00, 0x40, 0x04, 0x00, 0x07, 0xff, + 0xc0, 0x01, 0x40, 0x04, 0x00, 0x07, 0x83, 0xc0, 0x03, 0x40, 0x06, 0x00, + 0x03, 0x01, 0x80, 0x02, 0xc0, 0x02, 0x00, 0x00, 0x38, 0x00, 0x06, 0x80, + 0x02, 0x00, 0x00, 0x7c, 0x00, 0x0c, 0x80, 0x03, 0x00, 0x00, 0x7c, 0x00, + 0x0d, 0x80, 0x01, 0x00, 0x00, 0x7c, 0x00, 0x19, 0x00, 0x01, 0x80, 0x00, + 0x38, 0x00, 0x33, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x72, 0x00, 0x00, + 0x40, 0x00, 0x00, 0x00, 0xe6, 0x00, 0x00, 0x60, 0x00, 0x00, 0x01, 0xcc, + 0x00, 0x00, 0x30, 0x00, 0x00, 0x03, 0x98, 0x00, 0x00, 0x18, 0x00, 0x00, + 0x07, 0x30, 0x00, 0x00, 0x0c, 0x00, 0x18, 0x1c, 0x60, 0x00, 0x00, 0x07, + 0x00, 0x3c, 0x38, 0xc0, 0x00, 0x00, 0x01, 0x80, 0x3c, 0x03, 0x80, 0x00, + 0x00, 0x00, 0xe0, 0x3c, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x3e, 0x3c, 0x78, + 0x00, 0x00, 0x00, 0x00, 0x07, 0xff, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00}; -// 'wifi-loading-3', 64x64px -static const unsigned char epd_bitmap_wifi_loading_3[] = { - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, - 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x3f, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0xff, - 0xfc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x07, 0x87, 0x80, 0x00, 0x00, - 0x00, 0x00, 0x38, 0x07, 0x80, 0xe0, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x07, - 0x80, 0x30, 0x00, 0x00, 0x00, 0x01, 0x80, 0x07, 0x80, 0x1c, 0x00, 0x00, - 0x00, 0x03, 0x00, 0x03, 0x0e, 0x06, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, - 0x07, 0x83, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x01, 0xe1, 0x80, 0x00, - 0x00, 0x18, 0x00, 0x00, 0x00, 0x70, 0xc0, 0x00, 0x00, 0x30, 0x00, 0x00, - 0x00, 0x38, 0x60, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x1c, 0x30, 0x00, - 0x00, 0x60, 0x00, 0x00, 0x00, 0x0e, 0x10, 0x00, 0x00, 0xc0, 0x00, 0x00, - 0x00, 0x07, 0x18, 0x00, 0x00, 0x80, 0x00, 0x7f, 0xf0, 0x03, 0x88, 0x00, - 0x01, 0x80, 0x03, 0xff, 0xfe, 0x01, 0x8c, 0x00, 0x01, 0x80, 0x0f, 0xff, - 0xff, 0x80, 0xc4, 0x00, 0x01, 0x00, 0x3f, 0xff, 0xff, 0xe0, 0x64, 0x00, - 0x03, 0x00, 0x7f, 0x00, 0x07, 0xf0, 0x66, 0x00, 0x02, 0x00, 0xfc, 0x00, - 0x01, 0xf8, 0x26, 0x00, 0x02, 0x01, 0xf0, 0x3f, 0xe0, 0x7c, 0x02, 0x00, - 0x02, 0x03, 0xe0, 0xff, 0xf8, 0x3e, 0x03, 0x00, 0x06, 0x03, 0xc3, 0xff, - 0xfe, 0x1e, 0x03, 0x00, 0x7f, 0xe1, 0x87, 0xff, 0xff, 0x0c, 0x3f, 0xf0, - 0xff, 0xf0, 0x0f, 0xe0, 0x3f, 0x80, 0x7f, 0xf8, 0xff, 0xf0, 0x1f, 0x80, - 0x0f, 0xc0, 0x7f, 0xf8, 0x7f, 0xe0, 0x3e, 0x07, 0x03, 0xe0, 0x3f, 0xf0, - 0x06, 0x00, 0x3c, 0x1f, 0xc1, 0xe0, 0x03, 0x00, 0x06, 0x00, 0x18, 0x3f, - 0xe0, 0xc0, 0x03, 0x00, 0x02, 0x00, 0x00, 0x7f, 0xf0, 0x00, 0x02, 0x00, - 0x02, 0x00, 0x00, 0xff, 0xf8, 0x00, 0x02, 0x00, 0x03, 0x00, 0x00, 0xf0, - 0x78, 0x00, 0x06, 0x00, 0x03, 0x00, 0x00, 0x60, 0x30, 0x00, 0x06, 0x00, - 0x01, 0x00, 0x00, 0x07, 0x00, 0x00, 0x04, 0x00, 0x01, 0x00, 0x00, 0x0f, - 0x80, 0x00, 0x04, 0x00, 0x01, 0x80, 0x00, 0x0f, 0x80, 0x00, 0x0c, 0x00, - 0x00, 0x80, 0x00, 0x0f, 0x80, 0x00, 0x08, 0x00, 0x00, 0xc0, 0x00, 0x07, - 0x00, 0x00, 0x18, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, - 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x30, 0x00, 0x00, - 0x00, 0x00, 0x60, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, - 0x00, 0x0c, 0x00, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x06, 0x00, 0x00, - 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x03, 0x00, 0x06, 0x00, 0x00, - 0x00, 0x01, 0xc0, 0x07, 0x80, 0x0c, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x07, - 0x80, 0x38, 0x00, 0x00, 0x00, 0x00, 0x38, 0x07, 0x80, 0xe0, 0x00, 0x00, - 0x00, 0x00, 0x0f, 0x87, 0x87, 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0xff, - 0xfc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1f, 0xe0, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, - 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; +// 'wifi-loading-3', 56x56px +const unsigned char epd_bitmap_wifi_loading_3[] = { + 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0xff, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x3c, 0x3c, 0x78, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x3c, + 0x0e, 0x00, 0x00, 0x00, 0x03, 0x80, 0x3c, 0xc3, 0x00, 0x00, 0x00, 0x06, + 0x00, 0x3c, 0x71, 0xc0, 0x00, 0x00, 0x0c, 0x00, 0x18, 0x1c, 0x60, 0x00, + 0x00, 0x18, 0x00, 0x00, 0x0e, 0x30, 0x00, 0x00, 0x30, 0x00, 0x00, 0x07, + 0x18, 0x00, 0x00, 0x60, 0x00, 0x00, 0x03, 0x8c, 0x00, 0x00, 0x40, 0x00, + 0x00, 0x01, 0xc6, 0x00, 0x00, 0xc0, 0x03, 0xff, 0x80, 0xe2, 0x00, 0x01, + 0x80, 0x1f, 0xff, 0xf0, 0x73, 0x00, 0x01, 0x00, 0x7f, 0xff, 0xfc, 0x39, + 0x00, 0x01, 0x01, 0xff, 0xff, 0xff, 0x19, 0x80, 0x03, 0x03, 0xf8, 0x00, + 0x3f, 0x8c, 0x80, 0x02, 0x07, 0xe0, 0x00, 0x0f, 0xc6, 0x80, 0x06, 0x0f, + 0x81, 0xff, 0x03, 0xe2, 0xc0, 0x04, 0x1f, 0x07, 0xff, 0xc1, 0xf2, 0x40, + 0x04, 0x1e, 0x1f, 0xff, 0xf0, 0xf0, 0x40, 0x04, 0x0c, 0x3f, 0xff, 0xf8, + 0x60, 0x40, 0x7f, 0xc0, 0x7f, 0x01, 0xfc, 0x07, 0xfe, 0xff, 0xe0, 0xfc, + 0x00, 0x7e, 0x0f, 0xff, 0xff, 0xe1, 0xf0, 0x38, 0x1f, 0x0f, 0xff, 0x7f, + 0xc1, 0xe0, 0xfe, 0x0f, 0x07, 0xfe, 0x04, 0x00, 0xc1, 0xff, 0x06, 0x00, + 0x40, 0x04, 0x00, 0x03, 0xff, 0x80, 0x00, 0x40, 0x04, 0x00, 0x07, 0xff, + 0xc0, 0x00, 0x40, 0x04, 0x00, 0x07, 0x83, 0xc0, 0x00, 0x40, 0x06, 0x00, + 0x03, 0x01, 0x80, 0x00, 0xc0, 0x02, 0x00, 0x00, 0x38, 0x00, 0x00, 0x80, + 0x02, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x7c, 0x00, + 0x01, 0x80, 0x01, 0x00, 0x00, 0x7c, 0x00, 0x01, 0x00, 0x01, 0x80, 0x00, + 0x38, 0x00, 0x03, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, + 0x40, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x0c, + 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x18, 0x00, 0x00, + 0x00, 0x30, 0x00, 0x00, 0x0c, 0x00, 0x18, 0x00, 0x60, 0x00, 0x00, 0x07, + 0x00, 0x3c, 0x00, 0xc0, 0x00, 0x00, 0x01, 0x80, 0x3c, 0x03, 0x80, 0x00, + 0x00, 0x00, 0xe0, 0x3c, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x3e, 0x3c, 0x78, + 0x00, 0x00, 0x00, 0x00, 0x07, 0xff, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00}; -// 'wifi-loading-4', 64x64px -static const unsigned char epd_bitmap_wifi_loading_4[] = { - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, - 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x3f, 0xf0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0xff, - 0xfc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0f, 0x07, 0x87, 0x80, 0x00, 0x00, - 0x00, 0x00, 0x38, 0x07, 0x80, 0xe0, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x07, - 0x80, 0x30, 0x00, 0x00, 0x00, 0x01, 0x80, 0x07, 0x80, 0x1c, 0x00, 0x00, - 0x00, 0x03, 0x03, 0x83, 0x00, 0x06, 0x00, 0x00, 0x00, 0x06, 0x0e, 0x00, - 0x00, 0x03, 0x00, 0x00, 0x00, 0x0c, 0x1c, 0x00, 0x00, 0x01, 0x80, 0x00, - 0x00, 0x18, 0x78, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x30, 0xe0, 0x00, - 0x00, 0x00, 0x60, 0x00, 0x00, 0x21, 0xc0, 0x00, 0x00, 0x00, 0x30, 0x00, - 0x00, 0x63, 0x80, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0xc7, 0x00, 0x00, - 0x00, 0x00, 0x18, 0x00, 0x00, 0x86, 0x00, 0x7f, 0xf0, 0x00, 0x08, 0x00, - 0x01, 0x8c, 0x03, 0xff, 0xfe, 0x00, 0x0c, 0x00, 0x01, 0x8c, 0x0f, 0xff, - 0xff, 0x80, 0x04, 0x00, 0x01, 0x18, 0x3f, 0xff, 0xff, 0xe0, 0x04, 0x00, - 0x03, 0x10, 0x7f, 0x00, 0x07, 0xf0, 0x06, 0x00, 0x02, 0x10, 0xfc, 0x00, - 0x01, 0xf8, 0x06, 0x00, 0x02, 0x01, 0xf0, 0x3f, 0xe0, 0x7c, 0x02, 0x00, - 0x02, 0x03, 0xe0, 0xff, 0xf8, 0x3e, 0x03, 0x00, 0x06, 0x03, 0xc3, 0xff, - 0xfe, 0x1e, 0x03, 0x00, 0x7f, 0xe1, 0x87, 0xff, 0xff, 0x0c, 0x3f, 0xf0, - 0xff, 0xf0, 0x0f, 0xe0, 0x3f, 0x80, 0x7f, 0xf8, 0xff, 0xf0, 0x1f, 0x80, - 0x0f, 0xc0, 0x7f, 0xf8, 0x7f, 0xe0, 0x3e, 0x07, 0x03, 0xe0, 0x3f, 0xf0, - 0x06, 0x00, 0x3c, 0x1f, 0xc1, 0xe0, 0x03, 0x00, 0x06, 0x00, 0x18, 0x3f, - 0xe0, 0xc0, 0x03, 0x00, 0x02, 0x00, 0x00, 0x7f, 0xf0, 0x00, 0x02, 0x00, - 0x02, 0x00, 0x00, 0xff, 0xf8, 0x00, 0x02, 0x00, 0x03, 0x00, 0x00, 0xf0, - 0x78, 0x00, 0x06, 0x00, 0x03, 0x00, 0x00, 0x60, 0x30, 0x00, 0x06, 0x00, - 0x01, 0x00, 0x00, 0x07, 0x00, 0x00, 0x04, 0x00, 0x01, 0x00, 0x00, 0x0f, - 0x80, 0x00, 0x04, 0x00, 0x01, 0x80, 0x00, 0x0f, 0x80, 0x00, 0x0c, 0x00, - 0x00, 0x80, 0x00, 0x0f, 0x80, 0x00, 0x08, 0x00, 0x00, 0xc0, 0x00, 0x07, - 0x00, 0x00, 0x18, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, - 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x30, 0x00, 0x00, - 0x00, 0x00, 0x60, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, - 0x00, 0x0c, 0x00, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x06, 0x00, 0x00, - 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x03, 0x00, 0x06, 0x00, 0x00, - 0x00, 0x01, 0xc0, 0x07, 0x80, 0x0c, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x07, - 0x80, 0x38, 0x00, 0x00, 0x00, 0x00, 0x38, 0x07, 0x80, 0xe0, 0x00, 0x00, - 0x00, 0x00, 0x0f, 0x87, 0x87, 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0xff, - 0xfc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1f, 0xe0, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, - 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x07, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, - 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; +// 'wifi-loading-4', 56x56px +const unsigned char epd_bitmap_wifi_loading_4[] = { + 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0xff, 0xc0, 0x00, + 0x00, 0x00, 0x00, 0x3c, 0x3c, 0x78, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x3c, + 0x0e, 0x00, 0x00, 0x00, 0x03, 0x8e, 0x3c, 0x03, 0x00, 0x00, 0x00, 0x06, + 0x38, 0x3c, 0x01, 0xc0, 0x00, 0x00, 0x0c, 0x70, 0x18, 0x00, 0x60, 0x00, + 0x00, 0x19, 0xe0, 0x00, 0x00, 0x30, 0x00, 0x00, 0x33, 0x80, 0x00, 0x00, + 0x18, 0x00, 0x00, 0x67, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x4e, 0x00, + 0x00, 0x00, 0x06, 0x00, 0x00, 0xdc, 0x03, 0xff, 0x80, 0x02, 0x00, 0x01, + 0x98, 0x1f, 0xff, 0xf0, 0x03, 0x00, 0x01, 0x30, 0x7f, 0xff, 0xfc, 0x01, + 0x00, 0x01, 0x31, 0xff, 0xff, 0xff, 0x01, 0x80, 0x03, 0x63, 0xf8, 0x00, + 0x3f, 0x80, 0x80, 0x02, 0x47, 0xe0, 0x00, 0x0f, 0xc0, 0x80, 0x06, 0x4f, + 0x81, 0xff, 0x03, 0xe0, 0xc0, 0x04, 0x1f, 0x07, 0xff, 0xc1, 0xf0, 0x40, + 0x04, 0x1e, 0x1f, 0xff, 0xf0, 0xf0, 0x40, 0x04, 0x0c, 0x3f, 0xff, 0xf8, + 0x60, 0x40, 0x7f, 0xc0, 0x7f, 0x01, 0xfc, 0x07, 0xfe, 0xff, 0xe0, 0xfc, + 0x00, 0x7e, 0x0f, 0xff, 0xff, 0xe1, 0xf0, 0x38, 0x1f, 0x0f, 0xff, 0x7f, + 0xc1, 0xe0, 0xfe, 0x0f, 0x07, 0xfe, 0x04, 0x00, 0xc1, 0xff, 0x06, 0x00, + 0x40, 0x04, 0x00, 0x03, 0xff, 0x80, 0x00, 0x40, 0x04, 0x00, 0x07, 0xff, + 0xc0, 0x00, 0x40, 0x04, 0x00, 0x07, 0x83, 0xc0, 0x00, 0x40, 0x06, 0x00, + 0x03, 0x01, 0x80, 0x00, 0xc0, 0x02, 0x00, 0x00, 0x38, 0x00, 0x00, 0x80, + 0x02, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x7c, 0x00, + 0x01, 0x80, 0x01, 0x00, 0x00, 0x7c, 0x00, 0x01, 0x00, 0x01, 0x80, 0x00, + 0x38, 0x00, 0x03, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, + 0x40, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x0c, + 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x18, 0x00, 0x00, + 0x00, 0x30, 0x00, 0x00, 0x0c, 0x00, 0x18, 0x00, 0x60, 0x00, 0x00, 0x07, + 0x00, 0x3c, 0x00, 0xc0, 0x00, 0x00, 0x01, 0x80, 0x3c, 0x03, 0x80, 0x00, + 0x00, 0x00, 0xe0, 0x3c, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x3e, 0x3c, 0x78, + 0x00, 0x00, 0x00, 0x00, 0x07, 0xff, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00}; static const unsigned char* epd_bitmap_wifi_loading[4] = { epd_bitmap_wifi_loading_1, diff --git a/firmware/main/modules/wifi/wifi_screens_module.c b/firmware/main/modules/wifi/wifi_screens_module.c index 59f94e90..3d8acc1f 100644 --- a/firmware/main/modules/wifi/wifi_screens_module.c +++ b/firmware/main/modules/wifi/wifi_screens_module.c @@ -28,7 +28,7 @@ void wifi_screens_module_display_sniffer_cb(sniffer_runtime_t* sniffer) { void wifi_screens_display_sniffer_animation_task() { static uint8_t idx = 0; - oled_screen_display_bitmap(epd_bitmap_wifi_loading[idx], 0, 0, 64, 64, + oled_screen_display_bitmap(epd_bitmap_wifi_loading[idx], 0, 1, 61, 61, OLED_DISPLAY_NORMAL); idx = ++idx > 3 ? 0 : idx; } diff --git a/firmware/resources/loading-animation.xcf b/firmware/resources/loading-animation.xcf deleted file mode 100644 index 158af414d717e8d5f2d0f5f587cbcec61240631d..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 9475 zcmds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dBDN?gcL}6$)cg*3p>ub)WB_7YB$R(r-zRRBe^a>-16!}l%uks!a`v-4()Dt_>G6WM?LZgwThQh(efIrE9B%d)@x6w-Ynp%Z1BUlFog5r)0(lILAkF)gYu9gl^wzz* zAHQ>x(%b$7rX~;j2~5wAL+un|u=eHQg8YB^-w!$8UARu@pLb^07-0mp`kweIGS>-m j?)(}fjZ*2vw_5(MiN~M7GJg8XTMF<4W$KNfA!Pm&n9B`= diff --git a/firmware/resources/wifi-loading-1.png b/firmware/resources/wifi-loading-1.png index ae119625b54486e5572e85d9d9c1cf6f7d508efc..1b84114203e34da9d0c968445a025479fc9c5e6e 100644 GIT binary patch literal 2342 zcmV+>3EB3EP)EX>4Tx04R}tkv&MmKpe$iQ>7|ZhjtKg$WR5rE-K;vxAeOirV~S;m|sCDCzw-NVP%yC~1ZLMN=c5CXT3@PWeK{ zW0mt3XRTai&3p0}26Ot#GS_L2Ab~|JL4pVcRg_SMjVP@;DHc++AMfBFcKs5$6mpfo z$gzM5G{~+W{11M2YvrdVy`*3q=zejWk5M473p8qu^L^|%jT6BC3|#3gf29u0ev)2m zX^|sfa2vR|ZfVLMaJd5vJsGkoyON)#kk13}XY@^3Aao1#t$DpQ_i_3Fq^Yaq4RCM> zj1?$*y~DeE+I#!=OtZfqZ}W1cISqLN00006VoOIv02u)J0QjB2eEk3b010qNS#tmY zE+YT{E+YYWr9XB6000McNliru=m`@K77+vsdshGe02y>eSad^gZEa<4bO1wgWnpw> zWFU8GbZ8()Nlj2!fese{00#a^L_t(&-tAiJdYeWNJ;OzkEkkVG<+MrP|83eQXwt?O zx;bIpSO#{dKNb)mkU)}^^!v&mTN1E)cFvrc*;(p#yNnB6&X>OdB8dCYe6Yx)enGDJ6|(1q9{TXML(|vBc)&&daca(Zy1KK zZM(3XMuI8@mVo>zEf^^U6;Cb*0)QFcUtR!a1YrnR76<@k!2tjfjH@fO90#p#7p+zc zrfC8w0zDl#ouZ*iSIgX_#AFI&{K{D_a$rTTzx{3Q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}!zdIADL2B)gD^uUU5dWzv-G zzTJ6%sH)X!CcFHWt<5MC?Mf2aE+pk-xJTJ>KXEa8VjDAZY%n!L)m{D+{h0ETJ)APk zaEgGnP-oV?5Ah9~2;EHN6Nd;4*{WaBk0#7^Q=XX@a1L4;sP| z(Nl{RjQH8l`E5Z>R+*sp}eA` z*hDeI0SmFMWxL=Txqu;wRuPYH@jiq;M+w}DXk6Z&;ry)|`DTn=8@mYHGiP~*?G!s| zP;8FaCYSMzy7iV8%|GMXQK`sqn?)qmQ)10{drzX;&j zXqfW((`fIXS^h~9O*r7KjbAUwzW{GQk-OY%WeJx7XPRY7b zGT{YEmba(1Q?l+US>vpca4Q|_o{qKY>p1J{xUDyJOx(DsW9UsCxAmru8Qi{(A$vMT zUrxt}zztwu$E?8R^(9$dSUT7IL#ne*G_i3|nU_645K|TmUtW~U%YL~}Wo4)6PM8%7 z?QwzloxoeOc7DB{9a6A&8jm0_c<&?S?`D$y1XB?U3A*&|m;~hR;3go*yDW<&X&9)k5D?N` zA;>iXLefM72%+UFAp(LNA;C>RE~}b3Lh?CIf4oUJRcl-?AZL!84v>?g$jPbJ7y-bf zK~965200CK8sr4Vfe4rc#^vq5*`^az+;cfk93% zXCq+bG|0*4SpGy#YO-R>4Fqx;>>vr<|YD?}}>~L>v>)h6H$Ypan zUCYM+8K4?&NAbi-|}@A751>#F=l&Ovs5GmUH?ZftlFm Date: Thu, 19 Sep 2024 11:15:44 -0600 Subject: [PATCH 18/22] feat: move wardriving text periodically --- .../main/drivers/oled_driver/oled_driver.c | 3 ++- .../wardriving/wardriving_screens_module.c | 27 ++++++++++++++----- .../main/modules/oled_screen/oled_screen.c | 4 +++ .../main/modules/oled_screen/oled_screen.h | 9 ++++++- 4 files changed, 35 insertions(+), 8 deletions(-) diff --git a/firmware/main/drivers/oled_driver/oled_driver.c b/firmware/main/drivers/oled_driver/oled_driver.c index 2828ed4b..e0a32313 100644 --- a/firmware/main/drivers/oled_driver/oled_driver.c +++ b/firmware/main/drivers/oled_driver/oled_driver.c @@ -190,7 +190,8 @@ void oled_driver_clear_line(oled_driver_t* dev, int x, int page, bool invert) { // char space[16]; // memset(space, 0x00, sizeof(space)); // oled_driver_display_text(dev, page, space, sizeof(space), invert); - char* space = " "; + // char* space = " "; + char* space = " "; oled_driver_display_text(dev, page, space, x, invert); } diff --git a/firmware/main/modules/gps/wardriving/wardriving_screens_module.c b/firmware/main/modules/gps/wardriving/wardriving_screens_module.c index 319573b7..4ae4d722 100644 --- a/firmware/main/modules/gps/wardriving/wardriving_screens_module.c +++ b/firmware/main/modules/gps/wardriving/wardriving_screens_module.c @@ -44,13 +44,28 @@ void wardriving_screens_module_scanning(uint32_t packets, char* signal) { // oled_screen_clear_buffer(); uint8_t x = 64; - uint8_t y = 0; + static uint8_t y = 0; + + static uint8_t count = 0; + count++; + if (count == 255) { + uint8_t pages = oled_screen_get_pages(); + for (uint8_t page = 0; page < pages; page++) { + oled_screen_clear_line(x, page, OLED_DISPLAY_NORMAL); + } + y++; + } + + if (y == 2) { + y = 0; + } - oled_screen_display_text("Packets", x, y++, OLED_DISPLAY_INVERT); - oled_screen_display_text(packets_str, x, y++, OLED_DISPLAY_INVERT); - y++; - oled_screen_display_text("GPS", x, y++, OLED_DISPLAY_INVERT); - oled_screen_display_text(signal, x, y++, OLED_DISPLAY_INVERT); + uint8_t yy = y; + oled_screen_display_text("Packets", x, yy++, OLED_DISPLAY_INVERT); + oled_screen_display_text(packets_str, x, yy++, OLED_DISPLAY_INVERT); + yy++; + oled_screen_display_text("GPS", x, yy++, OLED_DISPLAY_INVERT); + oled_screen_display_text(signal, x, yy++, OLED_DISPLAY_INVERT); oled_screen_display_show(); free(packets_str); } diff --git a/firmware/main/modules/oled_screen/oled_screen.c b/firmware/main/modules/oled_screen/oled_screen.c index 7a26ef82..8eecb95f 100644 --- a/firmware/main/modules/oled_screen/oled_screen.c +++ b/firmware/main/modules/oled_screen/oled_screen.c @@ -189,3 +189,7 @@ void oled_screen_display_loading_bar(uint8_t value, uint8_t page) { oled_screen_display_bitmap(bar_bitmap, 0, page * 8, 128, 8, OLED_DISPLAY_NORMAL); } + +uint8_t oled_screen_get_pages() { + return dev._pages; +} diff --git a/firmware/main/modules/oled_screen/oled_screen.h b/firmware/main/modules/oled_screen/oled_screen.h index 48bc947f..5a1a0075 100644 --- a/firmware/main/modules/oled_screen/oled_screen.h +++ b/firmware/main/modules/oled_screen/oled_screen.h @@ -134,4 +134,11 @@ void oled_screen_display_text_splited(char* p_text, void oled_screen_display_loading_bar(uint8_t value, uint8_t page); void oled_screen_display_card_border(); void oled_screen_clear_buffer(); -void oled_screen_display_show(); \ No newline at end of file +void oled_screen_display_show(); + +/** + * @brief Get the number of pages of the OLED display + * + * @return Number of pages of the OLED display + */ +uint8_t oled_screen_get_pages(); \ No newline at end of file From 475d4e9f57ce5ce24a782fbf51b9177c80324cf4 Mon Sep 17 00:00:00 2001 From: deimos Date: Thu, 19 Sep 2024 11:18:54 -0600 Subject: [PATCH 19/22] fix: wifi loading size --- firmware/main/modules/wifi/wifi_screens_module.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/firmware/main/modules/wifi/wifi_screens_module.c b/firmware/main/modules/wifi/wifi_screens_module.c index 3d8acc1f..156cf43b 100644 --- a/firmware/main/modules/wifi/wifi_screens_module.c +++ b/firmware/main/modules/wifi/wifi_screens_module.c @@ -28,7 +28,7 @@ void wifi_screens_module_display_sniffer_cb(sniffer_runtime_t* sniffer) { void wifi_screens_display_sniffer_animation_task() { static uint8_t idx = 0; - oled_screen_display_bitmap(epd_bitmap_wifi_loading[idx], 0, 1, 61, 61, + oled_screen_display_bitmap(epd_bitmap_wifi_loading[idx], 0, 1, 56, 56, OLED_DISPLAY_NORMAL); idx = ++idx > 3 ? 0 : idx; } From b15ff5d30702d8ecc50a2f54d47fae02d7a6de9f Mon Sep 17 00:00:00 2001 From: deimos Date: Thu, 19 Sep 2024 11:55:27 -0600 Subject: [PATCH 20/22] chore: reactivate no gps signal screen --- .../main/modules/gps/wardriving/wardriving_module.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/firmware/main/modules/gps/wardriving/wardriving_module.c b/firmware/main/modules/gps/wardriving/wardriving_module.c index c267b223..a7807e21 100644 --- a/firmware/main/modules/gps/wardriving/wardriving_module.c +++ b/firmware/main/modules/gps/wardriving/wardriving_module.c @@ -266,12 +266,12 @@ void wardriving_gps_event_handler_cb(gps_t* gps) { gps->sats_in_use, gps_module_get_signal_strength(gps), gps->latitude, gps->longitude); - // if (gps->sats_in_use == 0) { - // vTaskSuspend(scanning_wifi_animation_task_handle); - // running_wifi_scanner_animation = false; - // wardriving_screens_module_no_gps_signal(); - // return; - // } + if (gps->sats_in_use == 0) { + vTaskSuspend(scanning_wifi_animation_task_handle); + running_wifi_scanner_animation = false; + wardriving_screens_module_no_gps_signal(); + return; + } if (!running_wifi_scanner_animation) { vTaskResume(scanning_wifi_animation_task_handle); From 2bddbd68838dd9b22ea4ec28063b9f90fd64783d Mon Sep 17 00:00:00 2001 From: deimos Date: Thu, 19 Sep 2024 13:17:48 -0600 Subject: [PATCH 21/22] chore: update minino build files --- .gitignore | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index 01d2b74c..a788427e 100644 --- a/.gitignore +++ b/.gitignore @@ -34,10 +34,10 @@ hardware/minino-backups/ # Firmware binaries /**/build/ +/**/build-ota/ +/**/build-noota/ /**/managed_components/ -/**/build_files/ -/**/build_files.tgz -/**/build_files.zip +/**/minino-*.zip # IDF sdkconfig /**/sdkconfig From 339c7cb06717435ba5d0cf525638313dbe35f542 Mon Sep 17 00:00:00 2001 From: deimos Date: Thu, 19 Sep 2024 13:20:07 -0600 Subject: [PATCH 22/22] feat: compress ota and no ota build files --- firmware/get_build.sh | 50 +++++++++++++++++++++++++++---------- firmware/sdkconfig.defaults | 2 ++ 2 files changed, 39 insertions(+), 13 deletions(-) diff --git a/firmware/get_build.sh b/firmware/get_build.sh index 1523a31b..d4e345ac 100755 --- a/firmware/get_build.sh +++ b/firmware/get_build.sh @@ -4,25 +4,49 @@ PROJECT_NAME="minino" CONFIG_FILE="sdkconfig" +OTA_BUILD_DIR="build-ota" +NO_OTA_BUILD_DIR="build-noota" +TEMPORARY_BUILD_DIR="build_files" -project_version=$(grep '^CONFIG_PROJECT_VERSION=' "$CONFIG_FILE" | cut -d'=' -f2 | tr -d '"') -# Build the firmware -make compile +PROJECT_VERSION=$(grep '^CONFIG_PROJECT_VERSION=' "$CONFIG_FILE" | cut -d'=' -f2 | tr -d '"') +OTA_BUILD_FINAL_DIR="minino-ota-firmware-$PROJECT_VERSION" +NO_OTA_BUILD_FINAL_DIR="minino-noota-firmware-$PROJECT_VERSION" -mkdir -p build_files/ -mkdir -p build_files/partition_table/ -mkdir -p build_files/bootloader/ +# Build the firmware +echo "Building ota firmware..." +make setup +idf.py @profiles/ota build +mkdir -p $TEMPORARY_BUILD_DIR # Copy the firmware files to the build directory echo "Copying firmware files to build directory..." -cp build/$PROJECT_NAME.bin build_files/ -cp build/partition_table/partition-table.bin build_files/partition_table/ -cp build/bootloader/bootloader.bin build_files/bootloader/ -cp build/ota_data_initial.bin build_files/ +cp $OTA_BUILD_DIR/$PROJECT_NAME.bin $TEMPORARY_BUILD_DIR +cp $OTA_BUILD_DIR/partition_table/partition-table.bin $TEMPORARY_BUILD_DIR +cp $OTA_BUILD_DIR/bootloader/bootloader.bin $TEMPORARY_BUILD_DIR +cp $OTA_BUILD_DIR/ota_data_initial.bin $TEMPORARY_BUILD_DIR +mv $TEMPORARY_BUILD_DIR $OTA_BUILD_FINAL_DIR + +echo "Building no ota firmware..." +idf.py @profiles/noota build +rm -rf $TEMPORARY_BUILD_DIR +mkdir -p $TEMPORARY_BUILD_DIR + +echo "Copying firmware files to build directory..." +cp $NO_OTA_BUILD_DIR/$PROJECT_NAME.bin $TEMPORARY_BUILD_DIR +cp $NO_OTA_BUILD_DIR/partition_table/partition-table.bin $TEMPORARY_BUILD_DIR +cp $NO_OTA_BUILD_DIR/bootloader/bootloader.bin $TEMPORARY_BUILD_DIR +mv $TEMPORARY_BUILD_DIR $NO_OTA_BUILD_FINAL_DIR # Compress build_files and delete directory -echo "Compressing build_files..." -zip -r build_files_$project_version.zip build_files -rm -rf build_files/ +echo "Compressing ota build files..." +# zip -r build_files_$PROJECT_VERSION.zip build_files +zip -r $OTA_BUILD_FINAL_DIR.zip $OTA_BUILD_FINAL_DIR +echo "Compressing no ota build files..." +zip -r $NO_OTA_BUILD_FINAL_DIR.zip $NO_OTA_BUILD_FINAL_DIR + +echo "Cleaning build files..." +rm -rf $TEMPORARY_BUILD_DIR +rm -rf $OTA_BUILD_FINAL_DIR +rm -rf $NO_OTA_BUILD_FINAL_DIR echo "Done!" diff --git a/firmware/sdkconfig.defaults b/firmware/sdkconfig.defaults index 83e8e768..3f7e2bd5 100644 --- a/firmware/sdkconfig.defaults +++ b/firmware/sdkconfig.defaults @@ -1,3 +1,5 @@ +CONFIG_PROJECT_VERSION="1.2.0.1" + # Enable support for power management CONFIG_PM_ENABLE=y # Enable tickless idle mode