SDRAngel
4.11.5
Developer docs for <a href="https://github.com/f4exb/sdrangel">SDRangel<\a>, an Open Source Qt5 / OpenGL 3.0+ SDR and signal analyzer frontend to various hardware.
|
#include <ambeengine.h>
Inherits QObject.
Classes | |
struct | AMBEController |
Public Member Functions | |
AMBEEngine () | |
~AMBEEngine () | |
void | scan (std::vector< QString > &ambeDevices) |
void | releaseAll () |
int | getNbDevices () const |
number of devices used More... | |
void | getDeviceRefs (std::vector< QString > &devicesRefs) |
reference of the devices used (device path or url) More... | |
bool | registerController (const std::string &deviceRef) |
create a new controller for the device in reference More... | |
void | releaseController (const std::string &deviceRef) |
release controller resources for the device in reference More... | |
void | pushMbeFrame (const unsigned char *mbeFrame, int mbeRateIndex, int mbeVolumeIndex, unsigned char channels, bool useHP, int upsampling, AudioFifo *audioFifo) |
QByteArray | serialize () const |
bool | deserialize (const QByteArray &data) |
Private Member Functions | |
void | getComList () |
Static Private Member Functions | |
static std::string | get_driver (const std::string &tty) |
static void | register_comport (std::vector< std::string > &comList, std::vector< std::string > &comList8250, const std::string &dir) |
static void | probe_serial8250_comports (std::vector< std::string > &comList, std::vector< std::string > comList8250) |
Private Attributes | |
std::vector< AMBEController > | m_controllers |
std::vector< std::string > | m_comList |
std::vector< std::string > | m_comList8250 |
QMutex | m_mutex |
Definition at line 36 of file ambeengine.h.
AMBEEngine::AMBEEngine | ( | ) |
Definition at line 46 of file ambeengine.cpp.
AMBEEngine::~AMBEEngine | ( | ) |
Definition at line 49 of file ambeengine.cpp.
References getComList(), i, m_comList, m_comList8250, m_controllers, and scan().
bool AMBEEngine::deserialize | ( | const QByteArray & | data | ) |
Definition at line 355 of file ambeengine.cpp.
References i, registerController(), and releaseAll().
Referenced by MainSettings::load().
|
staticprivate |
Definition at line 168 of file ambeengine.cpp.
Referenced by register_comport().
|
private |
Definition at line 74 of file ambeengine.cpp.
References m_comList, m_comList8250, probe_serial8250_comports(), and register_comport().
Referenced by scan(), and ~AMBEEngine().
void AMBEEngine::getDeviceRefs | ( | std::vector< QString > & | devicesRefs | ) |
reference of the devices used (device path or url)
Definition at line 279 of file ambeengine.cpp.
References m_controllers.
Referenced by DSPEngine::getDVSerialNames(), and AMBEDevicesDialog::refreshInUseList().
|
inline |
number of devices used
Definition at line 46 of file ambeengine.h.
Referenced by DSPEngine::hasDVSerialSupport().
|
staticprivate |
Definition at line 137 of file ambeengine.cpp.
Referenced by getComList().
void AMBEEngine::pushMbeFrame | ( | const unsigned char * | mbeFrame, |
int | mbeRateIndex, | ||
int | mbeVolumeIndex, | ||
unsigned char | channels, | ||
bool | useHP, | ||
int | upsampling, | ||
AudioFifo * | audioFifo | ||
) |
Definition at line 290 of file ambeengine.cpp.
References m_controllers, and m_mutex.
Referenced by DSPEngine::pushMbeFrame().
|
staticprivate |
Definition at line 114 of file ambeengine.cpp.
References get_driver().
Referenced by getComList().
bool AMBEEngine::registerController | ( | const std::string & | deviceRef | ) |
create a new controller for the device in reference
Definition at line 214 of file ambeengine.cpp.
References m_controllers, and AMBEWorker::open().
Referenced by deserialize(), WebAPIAdapterSrv::instanceAMBEDevicesPatch(), WebAPIAdapterGUI::instanceAMBEDevicesPatch(), WebAPIAdapterGUI::instanceAMBEDevicesPut(), WebAPIAdapterSrv::instanceAMBEDevicesPut(), AMBEDevicesDialog::on_importAddress_clicked(), AMBEDevicesDialog::on_importAllSerial_clicked(), and AMBEDevicesDialog::on_importSerial_clicked().
void AMBEEngine::releaseAll | ( | ) |
Definition at line 261 of file ambeengine.cpp.
References m_controllers.
Referenced by deserialize(), WebAPIAdapterSrv::instanceAMBEDevicesDelete(), WebAPIAdapterGUI::instanceAMBEDevicesDelete(), WebAPIAdapterSrv::instanceAMBEDevicesPut(), WebAPIAdapterGUI::instanceAMBEDevicesPut(), and AMBEDevicesDialog::on_clearAmbeList_clicked().
void AMBEEngine::releaseController | ( | const std::string & | deviceRef | ) |
release controller resources for the device in reference
Definition at line 239 of file ambeengine.cpp.
References m_controllers.
Referenced by WebAPIAdapterGUI::instanceAMBEDevicesPatch(), WebAPIAdapterSrv::instanceAMBEDevicesPatch(), and AMBEDevicesDialog::on_removeAmbeDevice_clicked().
void AMBEEngine::scan | ( | std::vector< QString > & | ambeDevices | ) |
Definition at line 191 of file ambeengine.cpp.
References AMBEWorker::close(), getComList(), m_comList, and AMBEWorker::open().
Referenced by WebAPIAdapterGUI::instanceAMBESerialGet(), WebAPIAdapterSrv::instanceAMBESerialGet(), AMBEDevicesDialog::populateSerialList(), MainBench::testAMBE(), and ~AMBEEngine().
QByteArray AMBEEngine::serialize | ( | ) | const |
Definition at line 335 of file ambeengine.cpp.
References m_controllers.
Referenced by MainSettings::save().
|
private |
Definition at line 84 of file ambeengine.h.
Referenced by getComList(), scan(), and ~AMBEEngine().
|
private |
Definition at line 85 of file ambeengine.h.
Referenced by getComList(), and ~AMBEEngine().
|
private |
Definition at line 83 of file ambeengine.h.
Referenced by getDeviceRefs(), pushMbeFrame(), registerController(), releaseAll(), releaseController(), serialize(), and ~AMBEEngine().
|
private |
Definition at line 86 of file ambeengine.h.
Referenced by pushMbeFrame().