mirror of
https://github.com/eried/portapack-mayhem.git
synced 2025-07-21 22:19:12 -04:00
Added options for enabling CLKOUT.
- CLKOUT can be enabled in Radio settings and status bar. - Fixed a typo(I believe) in ui_navigation.
This commit is contained in:
parent
55783a60f5
commit
b15b781039
8 changed files with 80 additions and 9 deletions
|
@ -463,3 +463,17 @@ void ClockManager::stop_audio_pll() {
|
|||
cgu::pll0audio::power_down();
|
||||
while( cgu::pll0audio::is_locked() );
|
||||
}
|
||||
|
||||
void ClockManager::enable_clock_output(bool enable) {
|
||||
if(enable) {
|
||||
clock_generator.enable_output(clock_generator_output_clkout);
|
||||
clock_generator.set_ms_frequency(clock_generator_output_clkout, 10000000, si5351_vco_f, 0);
|
||||
} else {
|
||||
clock_generator.disable_output(clock_generator_output_clkout);
|
||||
}
|
||||
|
||||
if(enable)
|
||||
clock_generator.set_clock_control(clock_generator_output_clkout, si5351_clock_control_common[clock_generator_output_clkout].ms_src(get_reference_clock_generator_pll(reference.source)).clk_pdn(ClockControl::ClockPowerDown::Power_On));
|
||||
else
|
||||
clock_generator.set_clock_control(clock_generator_output_clkout, ClockControl::power_off());
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue