mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2024-11-26 22:28:41 -05:00
424ed88645
V12.2.6 of teh DX Lab Suite Commander finally has a way to suppress mode rationalization when setting the split Tx frequency. This now means that we can now honor the radio setting to not change the rig modulation mode. This should help with a number of rigs that require different modes on teh Tx and Rx VFOs for optimal wide band digital operation. This will also help with some rig and interface combinations that lock up or otherwise misbehave when setting the Tx VFO mode at certain times with respect to other rig control commands. This change also improves mode setting in general hopefully closing a few corner case issues when starting up and when transmitting for the first time in a session. Included is the latest DX Lab Suite Commander TCP/IP commands documentation correct for v12.2.6. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@7030 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
59 lines
1.8 KiB
C++
59 lines
1.8 KiB
C++
#ifndef DX_LAB_SUITE_COMMANDER_TRANSCEIVER_HPP__
|
|
#define DX_LAB_SUITE_COMMANDER_TRANSCEIVER_HPP__
|
|
|
|
#include <memory>
|
|
|
|
#include "TransceiverFactory.hpp"
|
|
#include "PollingTransceiver.hpp"
|
|
|
|
class QTcpSocket;
|
|
class QByteArray;
|
|
class QString;
|
|
|
|
//
|
|
// DX Lab Suite Commander Interface
|
|
//
|
|
// Implemented as a Transceiver decorator because we may want the PTT
|
|
// services of another Transceiver type such as the HamlibTransceiver
|
|
// which can be enabled by wrapping a HamlibTransceiver instantiated
|
|
// as a "Hamlib Dummy" transceiver in the Transceiver factory method.
|
|
//
|
|
class DXLabSuiteCommanderTransceiver final
|
|
: public PollingTransceiver
|
|
{
|
|
Q_OBJECT; // for translation context
|
|
|
|
public:
|
|
static void register_transceivers (TransceiverFactory::Transceivers *, int id);
|
|
|
|
// takes ownership of wrapped Transceiver
|
|
explicit DXLabSuiteCommanderTransceiver (std::unique_ptr<TransceiverBase> wrapped,
|
|
QString const& address, bool use_for_ptt,
|
|
int poll_interval, QObject * parent = nullptr);
|
|
|
|
protected:
|
|
int do_start () override;
|
|
void do_stop () override;
|
|
void do_frequency (Frequency, MODE, bool no_ignore) override;
|
|
void do_tx_frequency (Frequency, MODE, bool no_ignore) override;
|
|
void do_mode (MODE) override;
|
|
void do_ptt (bool on) override;
|
|
|
|
void poll () override;
|
|
|
|
private:
|
|
void simple_command (QString const&, bool no_debug = false);
|
|
QString command_with_reply (QString const&, bool no_debug = false);
|
|
bool write_to_port (QString const&);
|
|
QString frequency_to_string (Frequency) const;
|
|
Frequency string_to_frequency (QString) const;
|
|
|
|
std::unique_ptr<TransceiverBase> wrapped_; // may be null
|
|
bool use_for_ptt_;
|
|
QString server_;
|
|
QTcpSocket * commander_;
|
|
QLocale locale_;
|
|
};
|
|
|
|
#endif
|