aboutsummaryrefslogtreecommitdiffstats
path: root/mpm/lib/mykonos/ad937x_ctrl.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'mpm/lib/mykonos/ad937x_ctrl.cpp')
-rw-r--r--mpm/lib/mykonos/ad937x_ctrl.cpp21
1 files changed, 21 insertions, 0 deletions
diff --git a/mpm/lib/mykonos/ad937x_ctrl.cpp b/mpm/lib/mykonos/ad937x_ctrl.cpp
index 55479fb1d..d859195bc 100644
--- a/mpm/lib/mykonos/ad937x_ctrl.cpp
+++ b/mpm/lib/mykonos/ad937x_ctrl.cpp
@@ -157,6 +157,18 @@ public:
device.start_jesd_tx();
}
+ virtual void start_radio()
+ {
+ std::lock_guard<std::mutex> lock(*spi_mutex);
+ device.start_radio();
+ }
+
+ virtual void stop_radio()
+ {
+ std::lock_guard<std::mutex> lock(*spi_mutex);
+ device.stop_radio();
+ }
+
virtual uint8_t get_multichip_sync_status()
{
std::lock_guard<std::mutex> lock(*spi_mutex);
@@ -236,6 +248,15 @@ public:
return device.set_gain(dir, chain, value);
}
+ virtual double get_gain(const std::string &which)
+ {
+ auto dir = _get_direction_from_antenna(which);
+ auto chain = _get_chain_from_antenna(which);
+
+ std::lock_guard<std::mutex> lock(*spi_mutex);
+ return device.get_gain(dir, chain);
+ }
+
// TODO: does agc mode need to have a which parameter?
// this affects all RX channels on the device
virtual void set_agc_mode(const std::string &which, const std::string &mode)