Improved spectrum analyzer mode

- Faster sweeps by changing 2.LO only when necessary and using 400kHz I2C frequency
- Added FPGA settings for selectable ADC samplerate
- Additional measurement with different ADC samplerate when signal ID is on to remove ADC images
This commit is contained in:
Jan Käberich 2020-09-17 19:54:03 +02:00
parent 38e73365df
commit fc3ce7a828
22 changed files with 118 additions and 86 deletions

View file

@ -119,6 +119,10 @@ bool HW::Init(WorkRequest wr) {
return false;
}
// Set default ADC samplerate
FPGA::WriteRegister(FPGA::Reg::ADCPrescaler, 112);
FPGA::WriteRegister(FPGA::Reg::PhaseIncrement, 1120);
// Enable new data and sweep halt interrupt
FPGA::EnableInterrupt(FPGA::Interrupt::NewData);
FPGA::EnableInterrupt(FPGA::Interrupt::SweepHalted);
@ -211,6 +215,7 @@ void HW::SetIdle() {
FPGA::Enable(FPGA::Periphery::Port1Mixer, false);
FPGA::Enable(FPGA::Periphery::Port2Mixer, false);
FPGA::Enable(FPGA::Periphery::RefMixer, false);
FPGA::Enable(FPGA::Periphery::PortSwitch, false);
}
void HW::fillDeviceInfo(Protocol::DeviceInfo *info) {