mirror of
https://github.com/portapack-mayhem/mayhem-firmware.git
synced 2025-08-13 19:56:40 +00:00
Added HamItUp option (#840)
* Added HamItUp option to allow quick offset of the tuned frequency * New HamItUp icon for top bar * HamItUp checkbox status and frequency persistent settings in Settings/Radio
This commit is contained in:
@@ -40,6 +40,7 @@ using namespace hackrf::one;
|
||||
#include "cpld_update.hpp"
|
||||
|
||||
#include "portapack.hpp"
|
||||
#include "portapack_persistent_memory.hpp"
|
||||
|
||||
namespace radio {
|
||||
|
||||
@@ -168,7 +169,11 @@ void set_direction(const rf::Direction new_direction) {
|
||||
}
|
||||
|
||||
bool set_tuning_frequency(const rf::Frequency frequency) {
|
||||
const auto tuning_config = tuning::config::create(frequency);
|
||||
rf::Frequency final_frequency = frequency ;
|
||||
if( portapack::persistent_memory::config_hamitup() ) {
|
||||
final_frequency = frequency + portapack::persistent_memory::config_hamitup_freq();
|
||||
}
|
||||
const auto tuning_config = tuning::config::create(final_frequency);
|
||||
if( tuning_config.is_valid() ) {
|
||||
first_if.disable();
|
||||
|
||||
|
Reference in New Issue
Block a user