From 459e8d0b24a3bdea1ea5c4ffb4e65891355a7ae8 Mon Sep 17 00:00:00 2001 From: Mark Thompson <129641948+NotherNgineer@users.noreply.github.com> Date: Sun, 24 Dec 2023 10:28:22 -0600 Subject: [PATCH] Disallow CLKOUT freq changes on r9 (#1672) --- firmware/application/apps/ui_settings.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/firmware/application/apps/ui_settings.cpp b/firmware/application/apps/ui_settings.cpp index c2642b04..58ce5a12 100644 --- a/firmware/application/apps/ui_settings.cpp +++ b/firmware/application/apps/ui_settings.cpp @@ -184,6 +184,14 @@ SetRadioView::SetRadioView( send_system_refresh(); }; + // Disallow CLKOUT freq change on hackrf_r9 due to dependencies on GP_CLKIN (same Si5351A clock); + // see comments in ClockManager::enable_clock_output() + if (hackrf_r9) { + if (pmem::clkout_freq() != 10000) + pmem::set_clkout_freq(10000); + field_clkout_freq.set_focusable(false); + } + field_clkout_freq.set_value(pmem::clkout_freq()); field_clkout_freq.on_change = [this](SymField&) { if (field_clkout_freq.to_integer() < 10)