From 7f1c0f6f7e7bb75800afa936cdaf38d115c8bc36 Mon Sep 17 00:00:00 2001 From: Kyle Reed <3761006+kallanreed@users.noreply.github.com> Date: Sat, 17 Jun 2023 10:15:46 -0700 Subject: [PATCH] Explicitly set tx_model to make MicTX happy (#1162) Co-authored-by: kallanreed --- firmware/application/apps/ui_mictx.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/firmware/application/apps/ui_mictx.cpp b/firmware/application/apps/ui_mictx.cpp index 7dedbbdd9..e9beb0018 100644 --- a/firmware/application/apps/ui_mictx.cpp +++ b/firmware/application/apps/ui_mictx.cpp @@ -162,7 +162,7 @@ void MicTXView::rxaudio(bool is_on) { // receiver_model.set_nbfm_configuration(n); is called above , depending user's selection (8k5, 11k, 16k). } } - // receiver_model.set_target_frequency(field_frequency.value()); //probably this too can be commented out. + if (bool_same_F_tx_rx_enabled) // when stop TX ,define to which freq RX we return receiver_model.set_target_frequency(tx_frequency); // Update freq also for RX = TX else @@ -595,6 +595,12 @@ MicTXView::MicTXView( } }; + // These shouldn't be necessary, but because + // this app uses both transmitter_model and directly + // configures the baseband, these end up being required. + transmitter_model.set_sampling_rate(sampling_rate); + transmitter_model.set_baseband_bandwidth(1750000); + set_tx(false); audio::set_rate(audio::Rate::Hz_24000);