Added logging for device opening in LimeDriver

The LimeDriver now outputs a message to standard output when attempting
to open a device, offering real-time feedback on which device is being
accessed. This aids in debugging and provides users with immediate
visibility into driver actions.
This commit is contained in:
Kumi 2024-02-17 18:10:52 +01:00
parent 017742f56d
commit a50192b675
Signed by: kumi
GPG key ID: ECBCC9082395383F

View file

@ -15,6 +15,7 @@ h5c++ -shlib limedriver.cpp -std=c++11 -lLimeSuite -o limedriver
#include "limedriver.h" #include "limedriver.h"
#include <H5PredType.h> #include <H5PredType.h>
#include <iostream>
#include <lime/LimeSuite.h> #include <lime/LimeSuite.h>
#include <vector> #include <vector>
@ -129,6 +130,8 @@ lms_device_t *openDevice(const std::string &info) {
info_string = deviceList[0]; info_string = deviceList[0];
} }
cout << "Opening device: " << info_string << endl;
lms_device_t *dev = NULL; lms_device_t *dev = NULL;
if (LMS_Open(&dev, info.c_str(), NULL)) { if (LMS_Open(&dev, info.c_str(), NULL)) {
error(); error();