2020-08-25 01:06:50 +08:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include <cstdint>
|
|
|
|
#include "Protocol.hpp"
|
2020-09-12 05:08:30 +08:00
|
|
|
#include "FPGA/FPGA.hpp"
|
2020-08-25 01:06:50 +08:00
|
|
|
|
|
|
|
namespace VNA {
|
|
|
|
|
|
|
|
using SweepCallback = void(*)(Protocol::Datapoint);
|
|
|
|
using StatusCallback = void(*)(FPGA::SamplingResult);
|
|
|
|
|
|
|
|
bool Init();
|
|
|
|
bool ConfigureSweep(Protocol::SweepSettings s, SweepCallback cb);
|
|
|
|
bool ConfigureManual(Protocol::ManualControl m, StatusCallback cb);
|
2020-09-12 18:17:35 +08:00
|
|
|
|
|
|
|
// Only call the following function when the sweep is inactive
|
2020-08-25 01:06:50 +08:00
|
|
|
bool GetTemps(uint8_t *source, uint8_t *lo);
|
2020-09-12 18:17:35 +08:00
|
|
|
void fillDeviceInfo(Protocol::DeviceInfo *info);
|
|
|
|
namespace Ref {
|
|
|
|
bool available();
|
|
|
|
bool applySettings(Protocol::ReferenceSettings s);
|
|
|
|
}
|
2020-08-25 01:06:50 +08:00
|
|
|
|
|
|
|
}
|
|
|
|
|