From 7fa92868d79b3c37f289d5d97443ea151ebef973 Mon Sep 17 00:00:00 2001 From: Jonathan Elder Date: Sat, 6 Jun 2020 11:45:19 -0700 Subject: [PATCH 1/9] Scanner update Renamed scanner squelch to trigger Added squelch for audio output --- firmware/application/apps/ui_scanner.cpp | 12 ++++++++++-- firmware/application/apps/ui_scanner.hpp | 17 +++++++++++++---- 2 files changed, 23 insertions(+), 6 deletions(-) diff --git a/firmware/application/apps/ui_scanner.cpp b/firmware/application/apps/ui_scanner.cpp index 02b36370b..4ba63ffd7 100644 --- a/firmware/application/apps/ui_scanner.cpp +++ b/firmware/application/apps/ui_scanner.cpp @@ -104,6 +104,7 @@ ScannerView::ScannerView( &field_rf_amp, &field_volume, &field_bw, + &field_trigger, &field_squelch, &field_wait, //&record_view, @@ -143,10 +144,17 @@ ScannerView::ScannerView( }; field_wait.set_value(5); + field_trigger.on_change = [this](int32_t v) { + trigger = v; + }; + field_trigger.set_value(30); + + field_squelch.set_value(receiver_model.squelch_level()); field_squelch.on_change = [this](int32_t v) { squelch = v; + receiver_model.set_squelch_level(v); }; - field_squelch.set_value(30); + field_volume.set_value((receiver_model.headphone_volume() - audio::headphone::volume_range().max).decibel() + 99); field_volume.on_change = [this](int32_t v) { @@ -175,7 +183,7 @@ void ScannerView::on_statistics_update(const ChannelStatistics& statistics) { if (timer <= wait) timer++; - if (max_db < -squelch) { + if (max_db < -trigger) { if (timer == wait) { //audio::output::stop(); scan_thread->set_scanning(true); diff --git a/firmware/application/apps/ui_scanner.hpp b/firmware/application/apps/ui_scanner.hpp index 52e48e290..6d5c84f2b 100644 --- a/firmware/application/apps/ui_scanner.hpp +++ b/firmware/application/apps/ui_scanner.hpp @@ -66,6 +66,7 @@ private: void handle_retune(uint32_t i); std::vector frequency_list { }; + int32_t trigger { 0 }; int32_t squelch { 0 }; uint32_t timer { 0 }; uint32_t wait { 0 }; @@ -73,8 +74,8 @@ private: Labels labels { { { 0 * 8, 0 * 16 }, "LNA: VGA: AMP: VOL:", Color::light_grey() }, - { { 0 * 8, 1 * 16 }, "BW: SQUELCH: /99 WAIT:", Color::light_grey() }, - { { 0 * 8, 3 * 16 }, "Work in progress...", Color::light_grey() } + { { 0 * 8, 1 * 16 }, "BW: TR: /99 SQ: /99 WT:", Color::light_grey() }, + { { 0 * 8, 3 * 16 }, "Work in progress!", Color::light_grey() } }; LNAGainField field_lna { @@ -107,8 +108,16 @@ private: } }; + NumberField field_trigger { + { 10 * 8, 1 * 16 }, + 2, + { 0, 99 }, + 1, + ' ', + }; + NumberField field_squelch { - { 15 * 8, 1 * 16 }, + { 19 * 8, 1 * 16 }, 2, { 0, 99 }, 1, @@ -116,7 +125,7 @@ private: }; NumberField field_wait { - { 26 * 8, 1 * 16 }, + { 28 * 8, 1 * 16 }, 2, { 0, 99 }, 1, From 81d5ac4923094dffe53e24a1f32498bdd1c92062 Mon Sep 17 00:00:00 2001 From: eried <1091420+eried@users.noreply.github.com> Date: Sun, 7 Jun 2020 04:33:47 +0200 Subject: [PATCH 2/9] Update ui_scanner.hpp --- firmware/application/apps/ui_scanner.hpp | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/firmware/application/apps/ui_scanner.hpp b/firmware/application/apps/ui_scanner.hpp index 6d5c84f2b..02abe1ace 100644 --- a/firmware/application/apps/ui_scanner.hpp +++ b/firmware/application/apps/ui_scanner.hpp @@ -73,9 +73,9 @@ private: freqman_db database { }; Labels labels { - { { 0 * 8, 0 * 16 }, "LNA: VGA: AMP: VOL:", Color::light_grey() }, - { { 0 * 8, 1 * 16 }, "BW: TR: /99 SQ: /99 WT:", Color::light_grey() }, - { { 0 * 8, 3 * 16 }, "Work in progress!", Color::light_grey() } + { { 0 * 8, 0 * 16 }, "LNA: TRIGGER: /99 VOL:", Color::light_grey() }, + { { 0 * 8, 1 * 16 }, "VGA: SQUELCH: /99 AMP:", Color::light_grey() }, + { { 0 * 8, 2 * 16 }, " BW: WAIT:", Color::light_grey() }, }; LNAGainField field_lna { @@ -83,15 +83,15 @@ private: }; VGAGainField field_vga { - { 11 * 8, 0 * 16 } + { 4 * 8, 1 * 16 } }; RFAmpField field_rf_amp { - { 18 * 8, 0 * 16 } + { 28 * 8, 1 * 16 } }; NumberField field_volume { - { 24 * 8, 0 * 16 }, + { 28 * 8, 0 * 16 }, 2, { 0, 99 }, 1, @@ -99,7 +99,7 @@ private: }; OptionsField field_bw { - { 3 * 8, 1 * 16 }, + { 4 * 8, 2 * 16 }, 3, { { "8k5", 0 }, @@ -109,7 +109,7 @@ private: }; NumberField field_trigger { - { 10 * 8, 1 * 16 }, + { 16 * 8, 0 * 16 }, 2, { 0, 99 }, 1, @@ -117,7 +117,7 @@ private: }; NumberField field_squelch { - { 19 * 8, 1 * 16 }, + { 16 * 8, 1 * 16 }, 2, { 0, 99 }, 1, @@ -125,7 +125,7 @@ private: }; NumberField field_wait { - { 28 * 8, 1 * 16 }, + { 16 * 8, 2 * 16 }, 2, { 0, 99 }, 1, From 993396a048499e7e3c79e65f0b428d47b01c92dd Mon Sep 17 00:00:00 2001 From: eried <1091420+eried@users.noreply.github.com> Date: Sun, 7 Jun 2020 06:26:19 +0200 Subject: [PATCH 3/9] Dark cyan for generic submenus --- firmware/application/apps/ui_debug.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/firmware/application/apps/ui_debug.cpp b/firmware/application/apps/ui_debug.cpp index 76b645899..6d81f620f 100644 --- a/firmware/application/apps/ui_debug.cpp +++ b/firmware/application/apps/ui_debug.cpp @@ -346,12 +346,12 @@ DebugPeripheralsMenuView::DebugPeripheralsMenuView(NavigationView& nav) { DebugMenuView::DebugMenuView(NavigationView& nav) { add_items({ //{ "..", ui::Color::light_grey(),&bitmap_icon_previous, [&nav](){ nav.pop(); } }, - { "Memory", ui::Color::cyan(), &bitmap_icon_memory, [&nav](){ nav.push(); } }, + { "Memory", ui::Color::dark_cyan(), &bitmap_icon_memory, [&nav](){ nav.push(); } }, //{ "Radio State", ui::Color::white(), nullptr, [&nav](){ nav.push(); } }, - { "SD Card", ui::Color::cyan(), &bitmap_icon_sdcard, [&nav](){ nav.push(); } }, - { "Peripherals", ui::Color::cyan(), &bitmap_icon_peripherals, [&nav](){ nav.push(); } }, - { "Temperature", ui::Color::cyan(), &bitmap_icon_temperature, [&nav](){ nav.push(); } }, - { "Controls", ui::Color::cyan(), &bitmap_icon_controls, [&nav](){ nav.push(); } }, + { "SD Card", ui::Color::dark_cyan(), &bitmap_icon_sdcard, [&nav](){ nav.push(); } }, + { "Peripherals", ui::Color::dark_cyan(), &bitmap_icon_peripherals, [&nav](){ nav.push(); } }, + { "Temperature", ui::Color::dark_cyan(), &bitmap_icon_temperature, [&nav](){ nav.push(); } }, + { "Buttons test", ui::Color::dark_cyan(), &bitmap_icon_controls, [&nav](){ nav.push(); } }, }); set_max_rows(2); // allow wider buttons } From 0e75cfea1243e4ee0cf899e6f0d224d50cf0a3eb Mon Sep 17 00:00:00 2001 From: eried <1091420+eried@users.noreply.github.com> Date: Sun, 7 Jun 2020 06:27:23 +0200 Subject: [PATCH 4/9] New icons --- firmware/graphics/icon_morse.png | Bin 117 -> 159 bytes firmware/graphics/icon_speaker.png | Bin 121 -> 165 bytes firmware/graphics/icon_tools_antenna.png | Bin 156 -> 153 bytes 3 files changed, 0 insertions(+), 0 deletions(-) diff --git a/firmware/graphics/icon_morse.png b/firmware/graphics/icon_morse.png index 7b49fbee57a60cb54de7478af9fcb78bf6a8dc82..5b10b1d3b5ff7a07217fcea2a641ea040f1c8dfb 100644 GIT binary patch delta 129 zcmV-{0Dk{fzp?R33gB2gsPfIs z06g9`o&x-ngEN4~8ImeQRSZz&xKDsk&H$=B0Gh;}cm%c?0eNyA1A3Y`eg1 q`!xr;3k>-@i2+;M1%|xY#uEd@zx6YFDYO6p002ovPDHLk0$_qsTss>8 delta 91 zcmZ3=SUEu@)WOrmF~p)bIUyn8hrgm)?B)Oe|DQBxU^`*NAUPq2!RmkkL#&YWY#ru; v#)&Bm7aKhaO)l9e2C8Z*OFKgTe~DWM4f3r`?Z diff --git a/firmware/graphics/icon_tools_antenna.png b/firmware/graphics/icon_tools_antenna.png index c83f3fe6dbb2892d858080632236ae160f5745a0..75923dd6dbc6ee71fa755e760de6c5c9cd0cacbf 100644 GIT binary patch delta 124 zcmV-?0E7RW0hs}iBz0d&L_t(IPsNi-4geqs1MUAGjp0z!m?%BCcmjk;!-6I+B7!ae z(AN0;Kaw Date: Sun, 7 Jun 2020 06:27:59 +0200 Subject: [PATCH 5/9] Icons and colors changes --- firmware/application/apps/ui_settings.cpp | 16 +- firmware/application/bitmap.hpp | 222 +++++++++++++++++----- firmware/application/ui_navigation.cpp | 18 +- 3 files changed, 194 insertions(+), 62 deletions(-) diff --git a/firmware/application/apps/ui_settings.cpp b/firmware/application/apps/ui_settings.cpp index 3d02f94dc..b963ab057 100644 --- a/firmware/application/apps/ui_settings.cpp +++ b/firmware/application/apps/ui_settings.cpp @@ -473,14 +473,14 @@ void ModInfoView::focus() { SettingsMenuView::SettingsMenuView(NavigationView& nav) { add_items({ - //{ "..", ui::Color::light_grey(), &bitmap_icon_previous, [&nav](){ nav.pop(); } }, - { "Audio", ui::Color::dark_cyan(), &bitmap_icon_speaker, [&nav](){ nav.push(); } }, - { "Radio", ui::Color::dark_cyan(), nullptr, [&nav](){ nav.push(); } }, - { "UI", ui::Color::dark_cyan(), nullptr, [&nav](){ nav.push(); } }, - //{ "SD card modules", ui::Color::dark_cyan(), [&nav](){ nav.push(); } }, - { "Date/Time", ui::Color::dark_cyan(), nullptr, [&nav](){ nav.push(); } }, - { "Touch screen", ui::Color::dark_cyan(), nullptr, [&nav](){ nav.push(); } }, - //{ "Play dead", ui::Color::dark_cyan(), &bitmap_icon_playdead, [&nav](){ nav.push(); } } + //{ "..", ui::Color::light_grey(), &bitmap_icon_previous, [&nav](){ nav.pop(); } }, + { "Audio", ui::Color::dark_cyan(), &bitmap_icon_speaker, [&nav](){ nav.push(); } }, + { "Radio", ui::Color::dark_cyan(), &bitmap_icon_options_radio, [&nav](){ nav.push(); } }, + { "Interface", ui::Color::dark_cyan(), &bitmap_icon_options_ui, [&nav](){ nav.push(); } }, + //{ "SD card modules", ui::Color::dark_cyan(), [&nav](){ nav.push(); } }, + { "Date/Time", ui::Color::dark_cyan(), &bitmap_icon_options_datetime, [&nav](){ nav.push(); } }, + { "Touchscreen", ui::Color::dark_cyan(), &bitmap_icon_options_touch, [&nav](){ nav.push(); } }, + //{ "Play dead", ui::Color::dark_cyan(), &bitmap_icon_playdead, [&nav](){ nav.push(); } } }); set_max_rows(2); // allow wider buttons } diff --git a/firmware/application/bitmap.hpp b/firmware/application/bitmap.hpp index bcf6d7786..0097ade8f 100644 --- a/firmware/application/bitmap.hpp +++ b/firmware/application/bitmap.hpp @@ -979,20 +979,20 @@ static constexpr Bitmap bitmap_icon_modem { static constexpr uint8_t bitmap_icon_morse_data[] = { 0x00, 0x00, - 0x18, 0x00, - 0x18, 0x00, - 0x18, 0x00, - 0x0C, 0x00, - 0x0C, 0x00, - 0x0C, 0x00, - 0x0C, 0x1F, - 0x06, 0x1F, - 0x06, 0x00, - 0x66, 0xC0, - 0x66, 0xC0, - 0x03, 0x00, - 0x03, 0x00, - 0x03, 0x00, + 0xFE, 0x7F, + 0xFF, 0xFF, + 0xBB, 0xD0, + 0xFF, 0xFF, + 0xFF, 0xFF, + 0x0B, 0xE1, + 0xFF, 0xFF, + 0xFF, 0xFF, + 0xEB, 0xD0, + 0xFF, 0xFF, + 0xFE, 0x7F, + 0x70, 0x00, + 0x30, 0x00, + 0x10, 0x00, 0x00, 0x00, }; static constexpr Bitmap bitmap_icon_morse { @@ -1087,6 +1087,94 @@ static constexpr Bitmap bitmap_icon_nuoptix { { 16, 16 }, bitmap_icon_nuoptix_data }; +static constexpr uint8_t bitmap_icon_options_datetime_data[] = { + 0x0C, 0x06, + 0xFF, 0x1F, + 0x49, 0x12, + 0x49, 0x12, + 0xFF, 0x1F, + 0x49, 0x00, + 0x49, 0x1C, + 0x7F, 0x63, + 0x09, 0x49, + 0x89, 0x88, + 0xBE, 0xB8, + 0x80, 0x80, + 0x00, 0x41, + 0x00, 0x63, + 0x00, 0x1C, + 0x00, 0x00, +}; +static constexpr Bitmap bitmap_icon_options_datetime { + { 16, 16 }, bitmap_icon_options_datetime_data +}; + +static constexpr uint8_t bitmap_icon_options_radio_data[] = { + 0x00, 0x00, + 0x00, 0x00, + 0x04, 0x20, + 0x12, 0x48, + 0x8A, 0x51, + 0xCA, 0x53, + 0xCA, 0x53, + 0x8A, 0x51, + 0x12, 0x48, + 0x84, 0x21, + 0xC0, 0x03, + 0x40, 0x02, + 0x60, 0x06, + 0x20, 0x04, + 0x30, 0x0C, + 0xF0, 0x0F, +}; +static constexpr Bitmap bitmap_icon_options_radio { + { 16, 16 }, bitmap_icon_options_radio_data +}; + +static constexpr uint8_t bitmap_icon_options_touch_data[] = { + 0xC7, 0xF1, + 0x97, 0xF4, + 0x27, 0xF2, + 0x8F, 0xF8, + 0x5F, 0xFD, + 0x47, 0xFD, + 0x53, 0xC1, + 0x4B, 0x9F, + 0x43, 0xB5, + 0x6F, 0xA0, + 0x2F, 0xA0, + 0x20, 0x20, + 0x60, 0x20, + 0x40, 0x10, + 0xC0, 0x1F, + 0x00, 0x00, +}; +static constexpr Bitmap bitmap_icon_options_touch { + { 16, 16 }, bitmap_icon_options_touch_data +}; + +static constexpr uint8_t bitmap_icon_options_ui_data[] = { + 0xFF, 0x1F, + 0xFF, 0x13, + 0xFF, 0x1F, + 0x01, 0x10, + 0x01, 0x10, + 0x01, 0x10, + 0x01, 0x04, + 0x01, 0x0C, + 0x01, 0x1C, + 0x01, 0x3C, + 0xFF, 0x7D, + 0x00, 0xFC, + 0x00, 0x34, + 0x00, 0x20, + 0x00, 0x60, + 0x00, 0x00, +}; +static constexpr Bitmap bitmap_icon_options_ui { + { 16, 16 }, bitmap_icon_options_ui_data +}; + static constexpr uint8_t bitmap_icon_peripherals_data[] = { 0x54, 0x01, 0x54, 0x01, @@ -1506,22 +1594,22 @@ static constexpr Bitmap bitmap_icon_sonde { }; static constexpr uint8_t bitmap_icon_soundboard_data[] = { - 0xFF, 0xAA, - 0x81, 0x00, - 0xA1, 0x42, - 0xB1, 0x20, - 0xBD, 0x52, - 0xBD, 0x28, - 0xBD, 0x52, - 0xB1, 0x20, - 0xA1, 0x42, - 0x81, 0x00, - 0xFF, 0xAA, - 0x00, 0x00, - 0xAA, 0xAA, - 0x01, 0x00, - 0xA0, 0x42, - 0x11, 0x20, + 0xF0, 0x0F, + 0x1C, 0x18, + 0x17, 0x38, + 0x15, 0x78, + 0x15, 0xF8, + 0x15, 0x82, + 0x15, 0x8B, + 0xD5, 0x83, + 0xD5, 0xBB, + 0xD5, 0x83, + 0x15, 0x8B, + 0x15, 0x92, + 0x15, 0xA0, + 0x17, 0x80, + 0x1C, 0x80, + 0xF0, 0xFF, }; static constexpr Bitmap bitmap_icon_soundboard { { 16, 16 }, bitmap_icon_soundboard_data @@ -1529,21 +1617,21 @@ static constexpr Bitmap bitmap_icon_soundboard { static constexpr uint8_t bitmap_icon_speaker_data[] = { 0x00, 0x00, - 0x00, 0x20, - 0x00, 0x30, - 0x00, 0x38, - 0x00, 0x3C, - 0xDC, 0x3E, - 0xDC, 0x3F, - 0xDC, 0x3F, - 0xDC, 0x3F, - 0xDC, 0x3F, - 0xDC, 0x3E, - 0x00, 0x3C, - 0x00, 0x38, - 0x00, 0x30, - 0x00, 0x20, - 0x00, 0x00, + 0x40, 0x10, + 0x60, 0x20, + 0x70, 0x44, + 0x78, 0x48, + 0x7F, 0x91, + 0x7F, 0x92, + 0x7F, 0x92, + 0x7F, 0x92, + 0x7F, 0x92, + 0x7F, 0x92, + 0x7F, 0x91, + 0x78, 0x48, + 0x70, 0x44, + 0x60, 0x20, + 0x40, 0x10, }; static constexpr Bitmap bitmap_icon_speaker { { 16, 16 }, bitmap_icon_speaker_data @@ -1637,6 +1725,50 @@ static constexpr Bitmap bitmap_icon_tetra { { 16, 16 }, bitmap_icon_tetra_data }; +static constexpr uint8_t bitmap_icon_tools_antenna_data[] = { + 0x38, 0x3E, + 0x10, 0x22, + 0x10, 0x26, + 0x10, 0x22, + 0x10, 0x2E, + 0x10, 0x22, + 0x10, 0x26, + 0x10, 0x22, + 0x38, 0x2E, + 0x38, 0x22, + 0x38, 0x26, + 0x38, 0x22, + 0x38, 0x2E, + 0x38, 0x22, + 0x38, 0x3E, + 0x00, 0x00, +}; +static constexpr Bitmap bitmap_icon_tools_antenna { + { 16, 16 }, bitmap_icon_tools_antenna_data +}; + +static constexpr uint8_t bitmap_icon_tools_wipesd_data[] = { + 0xF0, 0x3F, + 0x58, 0x35, + 0x5C, 0x35, + 0xFC, 0x3F, + 0xFC, 0x3F, + 0xFC, 0x3F, + 0x3C, 0x1C, + 0xBC, 0xC9, + 0xBC, 0xE3, + 0x2C, 0x77, + 0x5C, 0x3E, + 0xAC, 0x1C, + 0x5C, 0x3E, + 0x2C, 0x77, + 0x9C, 0xE3, + 0xAC, 0xC1, +}; +static constexpr Bitmap bitmap_icon_tools_wipesd { + { 16, 16 }, bitmap_icon_tools_wipesd_data +}; + static constexpr uint8_t bitmap_icon_tpms_data[] = { 0xC0, 0x03, 0xF0, 0x0F, diff --git a/firmware/application/ui_navigation.cpp b/firmware/application/ui_navigation.cpp index 937739f02..0db195132 100644 --- a/firmware/application/ui_navigation.cpp +++ b/firmware/application/ui_navigation.cpp @@ -402,15 +402,15 @@ TransmittersMenuView::TransmittersMenuView(NavigationView& nav) { UtilitiesMenuView::UtilitiesMenuView(NavigationView& nav) { add_items({ //{ "Test app", ui::Color::dark_grey(), nullptr, [&nav](){ nav.push(); } }, - //{ "..", ui::Color::light_grey(),&bitmap_icon_previous, [&nav](){ nav.pop(); } }, - { "Freq manager", ui::Color::green(), &bitmap_icon_freqman, [&nav](){ nav.push(); } }, - { "File manager", ui::Color::yellow(), &bitmap_icon_file, [&nav](){ nav.push(); } }, - //{ "Notepad", ui::Color::dark_grey(), &bitmap_icon_notepad, [&nav](){ nav.push(); } }, - { "Signal gen", ui::Color::green(), &bitmap_icon_cwgen, [&nav](){ nav.push(); } }, - //{ "Tone search", ui::Color::dark_grey(), nullptr, [&nav](){ nav.push(); } }, - { "Wave viewer", ui::Color::blue(), nullptr, [&nav](){ nav.push(); } }, - { "Antenna length", ui::Color::yellow(), nullptr, [&nav](){ nav.push(); } }, - { "Wipe SD card", ui::Color::red(), nullptr, [&nav](){ nav.push(); } }, + //{ "..", ui::Color::light_grey(),&bitmap_icon_previous, [&nav](){ nav.pop(); } }, + { "Freq manager", ui::Color::green(), &bitmap_icon_freqman, [&nav](){ nav.push(); } }, + { "File manager", ui::Color::yellow(), &bitmap_icon_dir, [&nav](){ nav.push(); } }, + //{ "Notepad", ui::Color::dark_grey(), &bitmap_icon_notepad, [&nav](){ nav.push(); } }, + { "Signal gen", ui::Color::green(), &bitmap_icon_cwgen, [&nav](){ nav.push(); } }, + //{ "Tone search", ui::Color::dark_grey(), nullptr, [&nav](){ nav.push(); } }, + { "Wave viewer", ui::Color::yellow(), &bitmap_icon_soundboard, [&nav](){ nav.push(); } }, + { "Antenna length", ui::Color::green(), &bitmap_icon_tools_antenna, [&nav](){ nav.push(); } }, + { "Wipe SD card", ui::Color::red(), &bitmap_icon_tools_wipesd, [&nav](){ nav.push(); } }, }); set_max_rows(2); // allow wider buttons } From cc75ed5eeed377fc9cf94cfd8170eb1a26374e04 Mon Sep 17 00:00:00 2001 From: Jonathan Elder Date: Sun, 7 Jun 2020 03:03:45 -0700 Subject: [PATCH 6/9] Scanner features (#55) - Added freq description to scanner display. --- firmware/application/apps/ui_scanner.cpp | 10 ++++++++++ firmware/application/apps/ui_scanner.hpp | 5 +++++ 2 files changed, 15 insertions(+) diff --git a/firmware/application/apps/ui_scanner.cpp b/firmware/application/apps/ui_scanner.cpp index 4ba63ffd7..b9e07a6ca 100644 --- a/firmware/application/apps/ui_scanner.cpp +++ b/firmware/application/apps/ui_scanner.cpp @@ -81,6 +81,7 @@ void ScannerView::handle_retune(uint32_t i) { text_cycle.set( to_string_dec_uint(i) + "/" + to_string_dec_uint(frequency_list.size()) + " : " + to_string_dec_uint(frequency_list[i]) ); + desc_cycle.set( description_list[i] ); } void ScannerView::focus() { @@ -109,6 +110,7 @@ ScannerView::ScannerView( &field_wait, //&record_view, &text_cycle, + &desc_cycle, //&waterfall, }); @@ -119,19 +121,27 @@ ScannerView::ScannerView( if (entry.type == RANGE) { for (uint32_t i=entry.frequency_a; i < entry.frequency_b; i+= 1000000) { frequency_list.push_back(i); + description_list.push_back("RNG " + to_string_dec_uint(entry.frequency_a) + ">" + to_string_dec_uint(entry.frequency_b)); } } else { frequency_list.push_back(entry.frequency_a); + description_list.push_back(entry.description); } } } else { // DEBUG frequency_list.push_back(466025000); + description_list.push_back("POCSAG-France"); frequency_list.push_back(466050000); + description_list.push_back("POCSAG-France"); frequency_list.push_back(466075000); + description_list.push_back("POCSAG-France"); frequency_list.push_back(466175000); + description_list.push_back("POCSAG-France"); frequency_list.push_back(466206250); + description_list.push_back("POCSAG-France"); frequency_list.push_back(466231250); + description_list.push_back("POCSAG-France"); } field_bw.set_selected_index(2); diff --git a/firmware/application/apps/ui_scanner.hpp b/firmware/application/apps/ui_scanner.hpp index 02abe1ace..b5d17c228 100644 --- a/firmware/application/apps/ui_scanner.hpp +++ b/firmware/application/apps/ui_scanner.hpp @@ -66,6 +66,7 @@ private: void handle_retune(uint32_t i); std::vector frequency_list { }; + std::vector description_list { }; int32_t trigger { 0 }; int32_t squelch { 0 }; uint32_t timer { 0 }; @@ -136,6 +137,10 @@ private: { 0, 5 * 16, 240, 16 }, "--/--" }; + Text desc_cycle { + {0, 6 * 16, 240, 16 }, + " " + }; std::unique_ptr scan_thread { }; From 4b4aab640a603f9ace210145593d16dc1eb24583 Mon Sep 17 00:00:00 2001 From: Erwin Ried <1091420+eried@users.noreply.github.com> Date: Sun, 7 Jun 2020 14:12:54 +0200 Subject: [PATCH 7/9] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index b83b7ad04..495d846d8 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ [![Build Status](https://travis-ci.com/eried/portapack-mayhem.svg?branch=master)](https://travis-ci.com/eried/portapack-mayhem) [![buddy pipeline](https://app.buddy.works/eried/portapack/pipelines/pipeline/252276/badge.svg?token=48cd59d53de0589a8fbe26bc751d77a59a011cf72581da049343879402991c34 "buddy pipeline")](https://app.buddy.works/eried/portapack/pipelines/pipeline/252276) [![CodeScene Code Health](https://codescene.io/projects/8381/status-badges/code-health)](https://codescene.io/projects/8381) [![Docker Hub Pulls](https://img.shields.io/docker/pulls/eried/portapack.svg)](https://hub.docker.com/r/eried/portapack) -This is a fork of the [Havoc](https://github.com/furrtek/portapack-havoc/), which was a fork of the [PortaPack](https://github.com/sharebrained/portapack-hackrf) firmware, which is an add-on for the [HackRF](http://greatscottgadgets.com/hackrf/). A fork means it is a derivated, so it is basically a clone that has extra features and fixes over the older versions. +This is a fork of the [Havoc](https://github.com/furrtek/portapack-havoc/), which was a fork of the [PortaPack](https://github.com/sharebrained/portapack-hackrf) firmware, an add-on for the [HackRF](http://greatscottgadgets.com/hackrf/). A fork means it is a derivated, so it is basically a clone that has extra features and fixes over the older versions. [](https://github.com/eried/portapack-mayhem/wiki/Hardware-overview) [](https://github.com/eried/portapack-mayhem/wiki/Hardware-overview#portapack-internals) From 64bc4d4068a94faaf0768a4802fcaba270cbc806 Mon Sep 17 00:00:00 2001 From: Erwin Ried <1091420+eried@users.noreply.github.com> Date: Sun, 7 Jun 2020 17:13:46 +0200 Subject: [PATCH 8/9] Update README.md --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 495d846d8..ebac6e65a 100644 --- a/README.md +++ b/README.md @@ -18,7 +18,7 @@ Yes, those are the [same](https://github.com/eried/portapack-mayhem/wiki/First-s ### Where is the latest firmware? -The current stable release is on the [Release](https://github.com/eried/portapack-mayhem/releases/latest) page. Follow the instructions on the description of the release itself to get it on your device. +The current stable release is on the [Release](https://github.com/eried/portapack-mayhem/releases/latest) page. Follow the instructions you can find in the release description. There is also [nightly builds](https://github.com/eried/portapack-mayhem/releases/tag/nightly) generated frequently, but these may contain incomplete functionality. @@ -45,6 +45,6 @@ As a last option, if you want to send money directly to me for getting more boar [![paypal](https://www.paypalobjects.com/en_US/i/btn/btn_donate_LG.gif)](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=CBPQA4HRRPJQ6&source=url) ### What if I need help? -First, check the [documentation](https://github.com/eried/portapack-mayhem/wiki). If you find a bug or you think the problem is related with the current repository, please open an [issue](https://github.com/eried/portapack-mayhem/issues/new/choose). +First, check the [documentation](https://github.com/eried/portapack-mayhem/wiki). If you find a bug or you think the problem is related to the current repository, please open an [issue](https://github.com/eried/portapack-mayhem/issues/new/choose). You can reach the [official community](https://www.facebook.com/groups/177623356165819) in Facebook. From a5721c54447e05052e1b4024830b0d175000a670 Mon Sep 17 00:00:00 2001 From: eried <1091420+eried@users.noreply.github.com> Date: Sun, 7 Jun 2020 19:16:54 +0200 Subject: [PATCH 9/9] Update ui_scanner.cpp --- firmware/application/apps/ui_scanner.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/firmware/application/apps/ui_scanner.cpp b/firmware/application/apps/ui_scanner.cpp index b9e07a6ca..26c007286 100644 --- a/firmware/application/apps/ui_scanner.cpp +++ b/firmware/application/apps/ui_scanner.cpp @@ -130,6 +130,7 @@ ScannerView::ScannerView( } } else { // DEBUG + // TODO: Clean this frequency_list.push_back(466025000); description_list.push_back("POCSAG-France"); frequency_list.push_back(466050000);