aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthias P. Braendli <matthias.braendli@mpb.li>2024-06-11 15:54:33 +0200
committerMatthias P. Braendli <matthias.braendli@mpb.li>2024-06-11 15:54:33 +0200
commitbe19dda79c659ce71fbbad087dd81a5a4bc8a2f5 (patch)
treee023c3dc372094903aad907eb03f52d1cade7d50
parent2784f199bce0455cc56b1eda9cbf3fbbba1b136e (diff)
downloaddabmod-be19dda79c659ce71fbbad087dd81a5a4bc8a2f5.tar.gz
dabmod-be19dda79c659ce71fbbad087dd81a5a4bc8a2f5.tar.bz2
dabmod-be19dda79c659ce71fbbad087dd81a5a4bc8a2f5.zip
Write DEXTER ad9957 freq as integer
-rw-r--r--src/output/Dexter.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/output/Dexter.cpp b/src/output/Dexter.cpp
index 0cd21ca..41e131a 100644
--- a/src/output/Dexter.cpp
+++ b/src/output/Dexter.cpp
@@ -361,8 +361,8 @@ void Dexter::tune(double lo_offset, double frequency)
int r = 0;
- const double freq = frequency - lo_offset;
- if ((r = iio_device_attr_write_double(m_ad9957, "center_frequency", freq)) != 0) {
+ const long long freq = frequency - lo_offset;
+ if ((r = iio_device_attr_write_longlong(m_ad9957, "center_frequency", freq)) != 0) {
etiLog.level(warn) << "Failed to set ad9957.center_frequency = " << freq << " : " << get_iio_error(r);
}