diff --git a/firmware/application/apps/ui_external_module_view.cpp b/firmware/application/apps/ui_external_module_view.cpp index a7f192515..b3c0e0559 100644 --- a/firmware/application/apps/ui_external_module_view.cpp +++ b/firmware/application/apps/ui_external_module_view.cpp @@ -92,6 +92,9 @@ void ExternalModuleView::on_tick_second() { case app_location_t::TX: btnText += " (TX)"; break; + case app_location_t::TRX: + btnText += " (TRX)"; + break; case app_location_t::SETTINGS: btnText += " (Settings)"; break; diff --git a/firmware/application/bitmap.hpp b/firmware/application/bitmap.hpp index 63a1f58d3..b895e9fd6 100644 --- a/firmware/application/bitmap.hpp +++ b/firmware/application/bitmap.hpp @@ -4221,6 +4221,44 @@ static constexpr Bitmap bitmap_icon_tpms{ {16, 16}, bitmap_icon_tpms_data}; +static constexpr uint8_t bitmap_icon_tranceivers_data[] = { + 0x80, + 0x01, + 0xC0, + 0x03, + 0xE0, + 0x07, + 0xB0, + 0x0D, + 0x98, + 0x19, + 0x80, + 0x01, + 0x80, + 0x01, + 0x80, + 0x01, + 0x98, + 0x19, + 0xB0, + 0x0D, + 0xE0, + 0x07, + 0xC0, + 0x03, + 0x83, + 0xC1, + 0x03, + 0xC0, + 0xFF, + 0xFF, + 0xFF, + 0xFF, +}; +static constexpr Bitmap bitmap_icon_tranceivers{ + {16, 16}, + bitmap_icon_tranceivers_data}; + static constexpr uint8_t bitmap_icon_transmit_data[] = { 0x80, 0x01, diff --git a/firmware/application/external/remote/main.cpp b/firmware/application/external/remote/main.cpp index 358452a4b..8c0ae1592 100644 --- a/firmware/application/external/remote/main.cpp +++ b/firmware/application/external/remote/main.cpp @@ -75,7 +75,7 @@ __attribute__((section(".external_app.app_remote.application_information"), used }, /*.icon_color = */ ui::Color::green().v, /*.menu_location = */ app_location_t::HOME, - /*.desired_menu_position = */ 4, + /*.desired_menu_position = */ 6, /*.m4_app_tag = portapack::spi_flash::image_tag_replay */ {'P', 'R', 'E', 'P'}, /*.m4_app_offset = */ 0x00000000, // will be filled at compile time diff --git a/firmware/application/ui_navigation.cpp b/firmware/application/ui_navigation.cpp index 4ef180bc9..6a4dc6eb2 100644 --- a/firmware/application/ui_navigation.cpp +++ b/firmware/application/ui_navigation.cpp @@ -117,10 +117,10 @@ const NavigationView::AppList NavigationView::appList = { /* HOME ******************************************************************/ {nullptr, "Receive", HOME, Color::cyan(), &bitmap_icon_receivers, new ViewFactory()}, {nullptr, "Transmit", HOME, Color::cyan(), &bitmap_icon_transmit, new ViewFactory()}, + {nullptr, "Tranceiver", HOME, Color::cyan(), &bitmap_icon_tranceivers, new ViewFactory()}, + {"recon", "Recon", HOME, Color::green(), &bitmap_icon_scanner, new ViewFactory()}, {"capture", "Capture", HOME, Color::red(), &bitmap_icon_capture, new ViewFactory()}, {"replay", "Replay", HOME, Color::green(), &bitmap_icon_replay, new ViewFactory()}, - {"recon", "Recon", HOME, Color::green(), &bitmap_icon_scanner, new ViewFactory()}, - {"microphone", "Microphone", HOME, Color::green(), &bitmap_icon_microphone, new ViewFactory()}, {"lookingglass", "Looking Glass", HOME, Color::green(), &bitmap_icon_looking, new ViewFactory()}, {nullptr, "Utilities", HOME, Color::cyan(), &bitmap_icon_utilities, new ViewFactory()}, {nullptr, "Games", HOME, Color::cyan(), &bitmap_icon_games, new ViewFactory()}, @@ -147,6 +147,8 @@ const NavigationView::AppList NavigationView::appList = { {"soundbrd", "Soundbrd", TX, ui::Color::green(), &bitmap_icon_soundboard, new ViewFactory()}, {"touchtune", "TouchTune", TX, ui::Color::green(), &bitmap_icon_touchtunes, new ViewFactory()}, {"signalgen", "SignalGen", TX, Color::green(), &bitmap_icon_cwgen, new ViewFactory()}, + /* TRX ********************************************************************/ + {"microphone", "Mic", TRX, Color::green(), &bitmap_icon_microphone, new ViewFactory()}, /* UTILITIES *************************************************************/ {"filemanager", "File Manager", UTILITIES, Color::green(), &bitmap_icon_dir, new ViewFactory()}, {"freqman", "Freq. Manager", UTILITIES, Color::green(), &bitmap_icon_freqman, new ViewFactory()}, @@ -841,6 +843,20 @@ void TransmittersMenuView::on_populate() { add_external_items(nav_, app_location_t::TX, *this, return_icon ? 1 : 0); } +/* TranceiversMenuView **************************************************/ + +TranceiversMenuView::TranceiversMenuView(NavigationView& nav) + : nav_(nav) {} + +void TranceiversMenuView::on_populate() { + bool return_icon = pmem::show_gui_return_icon(); + if (return_icon) { + add_items({{"..", Theme::getInstance()->fg_light->foreground, &bitmap_icon_previous, [this]() { nav_.pop(); }}}); + } + add_apps(nav_, *this, TRX); + add_external_items(nav_, app_location_t::TRX, *this, return_icon ? 1 : 0); +} + /* UtilitiesMenuView *****************************************************/ UtilitiesMenuView::UtilitiesMenuView(NavigationView& nav) diff --git a/firmware/application/ui_navigation.hpp b/firmware/application/ui_navigation.hpp index bc5c58f99..75df0bed1 100644 --- a/firmware/application/ui_navigation.hpp +++ b/firmware/application/ui_navigation.hpp @@ -379,6 +379,16 @@ class TransmittersMenuView : public BtnGridView { void on_populate() override; }; +class TranceiversMenuView : public BtnGridView { + public: + TranceiversMenuView(NavigationView& nav); + std::string title() const override { return "Tranceiver"; }; + + private: + NavigationView& nav_; + void on_populate() override; +}; + class UtilitiesMenuView : public BtnGridView { public: UtilitiesMenuView(NavigationView& nav); diff --git a/firmware/application/usb_serial_shell.cpp b/firmware/application/usb_serial_shell.cpp index 1c8fb9df6..31fb67034 100644 --- a/firmware/application/usb_serial_shell.cpp +++ b/firmware/application/usb_serial_shell.cpp @@ -691,6 +691,9 @@ static void printAppInfo(BaseSequentialStream* chp, ui::AppInfoConsole& element) case TX: chprintf(chp, "[TX]\r\n"); break; + case TRX: + chprintf(chp, "[TRX]\r\n"); + break; case UTILITIES: chprintf(chp, "[UTIL]\r\n"); break; @@ -715,6 +718,9 @@ static void printAppInfo(BaseSequentialStream* chp, const ui::AppInfo& element) case TX: chprintf(chp, "[TX]\r\n"); break; + case TRX: + chprintf(chp, "[TRX]\r\n"); + break; case UTILITIES: chprintf(chp, "[UTIL]\r\n"); break; diff --git a/firmware/common/standalone_app.hpp b/firmware/common/standalone_app.hpp index bd4d300a5..5de9e19d3 100644 --- a/firmware/common/standalone_app.hpp +++ b/firmware/common/standalone_app.hpp @@ -73,7 +73,8 @@ enum app_location_t : uint32_t { DEBUG, HOME, SETTINGS, - GAMES + GAMES, + TRX }; struct standalone_application_information_t { diff --git a/firmware/graphics/icon_tranceivers.png b/firmware/graphics/icon_tranceivers.png new file mode 100644 index 000000000..67e220ca1 Binary files /dev/null and b/firmware/graphics/icon_tranceivers.png differ