| libdrmconf
    0.12.0
    A library to program DMR radios. | 
Implements an interface to the Baofeng/Radioddity RD-5R VHF/UHF 5W DMR (Tier I/II) radio. More...
#include <rd5r.hh>


| Public Member Functions | |
| RD5R (RadioddityInterface *device=nullptr, QObject *parent=nullptr) | |
| Constructor.  More... | |
| const QString & | name () const | 
| Returns the name of the radio (e.g., device identifier). | |
| const RadioLimits & | limits () const | 
| Returns the limits for this radio.  More... | |
| const Codeplug & | codeplug () const | 
| Returns the codeplug instance. | |
| Codeplug & | codeplug () | 
| Returns the codeplug instance. | |
|  Public Member Functions inherited from RadioddityRadio | |
| RadioddityRadio (RadioddityInterface *device=nullptr, QObject *parent=nullptr) | |
| Do not construct this class directly, rather use Radio::detect. | |
|  Public Member Functions inherited from Radio | |
| Radio (QObject *parent=nullptr) | |
| Default constructor. | |
| virtual const CallsignDB * | callsignDB () const | 
| Returns the call-sign DB instance. | |
| virtual CallsignDB * | callsignDB () | 
| Returns the call-sign DB instance. | |
| Status | status () const | 
| Returns the current status. | |
| const ErrorStack & | errorStack () const | 
| Returns the error stack, passed to startDownload,startUploadorstartUploadCallsignDB.  More... | |
| Static Public Member Functions | |
| static RadioInfo | defaultRadioInfo () | 
| Returns the default info about the radio. | |
|  Static Public Member Functions inherited from Radio | |
| static Radio * | detect (const USBDeviceDescriptor &descr, const RadioInfo &force=RadioInfo(), const ErrorStack &err=ErrorStack()) | 
| Tries to detect the radio connected to the specified interface or constructs the specified radio using the RadioInfopassed byforce. | |
| Additional Inherited Members | |
|  Public Types inherited from Radio | |
| enum | Status { StatusIdle , StatusDownload , StatusUpload , StatusUploadCallsigns , StatusError } | 
| Possible states of the radio object.  More... | |
|  Public Slots inherited from RadioddityRadio | |
| bool | startDownload (bool blocking=false, const ErrorStack &err=ErrorStack()) | 
| Starts the download of the codeplug and derives the generic configuration from it. | |
| bool | startUpload (Config *config, bool blocking=false, const Codeplug::Flags &flags=Codeplug::Flags(), const ErrorStack &err=ErrorStack()) | 
| Derives the device-specific codeplug from the generic configuration and uploads that codeplug to the radio. | |
| bool | startUploadCallsignDB (UserDatabase *db, bool blocking=false, const CallsignDB::Selection &selection=CallsignDB::Selection(), const ErrorStack &err=ErrorStack()) | 
| Encodes the given user-database and uploades it to the device. | |
|  Public Slots inherited from Radio | |
| virtual bool | startDownload (bool blocking=false, const ErrorStack &err=ErrorStack())=0 | 
| Starts the download of the codeplug.  More... | |
| virtual bool | startUpload (Config *config, bool blocking=false, const Codeplug::Flags &flags=Codeplug::Flags(), const ErrorStack &err=ErrorStack())=0 | 
| Derives the device-specific codeplug from the generic configuration and uploads that codeplug to the radio. | |
| virtual bool | startUploadCallsignDB (UserDatabase *db, bool blocking=false, const CallsignDB::Selection &selection=CallsignDB::Selection(), const ErrorStack &err=ErrorStack())=0 | 
| Assembles the callsign DB from the given one and uploads it to the device. | |
|  Signals inherited from Radio | |
| void | downloadStarted () | 
| Gets emitted once the codeplug download has been started. | |
| void | downloadProgress (int percent) | 
| Gets emitted on download progress (e.g., for progress bars). | |
| void | downloadFinished (Radio *radio, Codeplug *codeplug) | 
| Gets emitted once the codeplug download has been finished. | |
| void | downloadError (Radio *radio) | 
| Gets emitted if there was an error during the codeplug download. | |
| void | uploadStarted () | 
| Gets emitted once the codeplug upload has been started. | |
| void | uploadProgress (int percent) | 
| Gets emitted on upload progress (e.g., for progress bars). | |
| void | uploadError (Radio *radio) | 
| Gets emitted if there was an error during the upload. | |
| void | uploadComplete (Radio *radio) | 
| Gets emitted once the codeplug upload has been completed successfully. | |
|  Protected Member Functions inherited from RadioddityRadio | |
| void | run () | 
| Thread main routine, performs all blocking IO operations for codeplug up- and download. | |
|  Protected Attributes inherited from RadioddityRadio | |
| RadioddityInterface * | _dev | 
| The interface to the radio. | |
| Codeplug::Flags | _codeplugFlags | 
| Holds the flags to control assembly and upload of code-plugs. | |
| Config * | _config | 
| The generic configuration. | |
| UserDatabase * | _userDB | 
| A weak reference to the user-database. | |
|  Protected Attributes inherited from Radio | |
| Status | _task | 
| The current state/task. | |
| ErrorStack | _errorStack | 
| The error stack. | |
Implements an interface to the Baofeng/Radioddity RD-5R VHF/UHF 5W DMR (Tier I/II) radio.
The Baofeng/Radioddity RD-5R radio uses a weird HID (human-interface device, see HID and HIDevice) protocol for communication. This class implements the communication details with the radio to read and write codeplugs on the device. 
| RD5R::RD5R | ( | RadioddityInterface * | device = nullptr, | 
| QObject * | parent = nullptr | ||
| ) | 
Constructor.
Do not call this constructor directly. Consider using the factory method Radio::detect. 
| 
 | virtual | 
Returns the limits for this radio.
Call RadioLimits::verifyConfig to verify a codeplug with respect to a radio.
Implements Radio.