WSJT-X/widgets/astro.cpp

334 lines
11 KiB
C++
Raw Normal View History

#include "astro.h"
#include <stdio.h>
#include <QApplication>
#include <QFile>
#include <QTextStream>
#include <QSettings>
#include <QDateTime>
#include <QTimeZone>
#include <QDir>
#include <QCloseEvent>
#include <QDebug>
#include <math.h>
#include "commons.h"
#include "MessageBox.hpp"
#include "Configuration.hpp"
#include "SettingsGroup.hpp"
#include "qt_helpers.hpp"
#include "ui_astro.h"
#include "moc_astro.cpp"
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
extern "C" {
void astrosub(int nyear, int month, int nday, double uth, double freqMoon,
const char * mygrid, const char * hisgrid,
double * azsun, double * elsun, double * azmoon,
double * elmoon, double * azmoondx, double * elmoondx, int * ntsky,
int * ndop, int * ndop00, double * ramoon, double * decmoon, double * dgrd,
double * poloffset, double * xnr, double * techo, double * width1,
double * width2, bool bTx, const char * AzElFileName,
const char * jpleph);
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
}
Astro::Astro(QSettings * settings, Configuration const * configuration, QWidget * parent)
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
: QDialog {parent, Qt::WindowTitleHint}
, settings_ {settings}
, configuration_ {configuration}
, ui_ {new Ui::Astro}
, m_DopplerMethod {0}
, m_dop {0}
, m_dop00 {0}
//, m_dx_two_way_dop {0}
{
ui_->setupUi (this);
setWindowTitle (QApplication::applicationName () + " - " + tr ("Astronomical Data"));
setBackgroundRole (QPalette::Base);
setAutoFillBackground (true);
connect (ui_->cbDopplerTracking, &QAbstractButton::toggled, ui_->doppler_widget, &QWidget::setVisible);
read_settings ();
ui_->text_label->clear ();
}
Astro::~Astro ()
{
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
ui_->cbDopplerTracking->setChecked (false);
Q_EMIT tracking_update ();
if (isVisible ()) write_settings ();
}
void Astro::closeEvent (QCloseEvent * e)
{
write_settings ();
e->ignore (); // do not allow closure by the window system
}
void Astro::read_settings ()
{
SettingsGroup g (settings_, "Astro");
ui_->doppler_widget->setVisible (ui_->cbDopplerTracking->isChecked ());
m_DopplerMethod=settings_->value("DopplerMethod",0).toInt();
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
switch (m_DopplerMethod)
{
case 0: ui_->rbNoDoppler->setChecked (true); break;
case 1: ui_->rbFullTrack->setChecked (true); break;
case 2: ui_->rbConstFreqOnMoon->setChecked (true); break;
case 3: ui_->rbOwnEcho->setChecked (true); break;
case 4: ui_->rbOnDxEcho->setChecked (true); break;
case 5: ui_->rbCallDx->setChecked (true); break;
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
}
move (settings_->value ("window/pos", pos ()).toPoint ());
}
void Astro::write_settings ()
{
SettingsGroup g (settings_, "Astro");
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
//settings_->setValue ("DopplerTracking", ui_->cbDopplerTracking->isChecked ());
settings_->setValue ("DopplerMethod",m_DopplerMethod);
settings_->setValue ("window/pos", pos ());
}
auto Astro::astroUpdate(QDateTime const& t, QString const& mygrid, QString const& hisgrid, Frequency freq,
bool dx_is_self, bool bTx, bool no_tx_QSY, double TR_period) -> Correction
{
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
Frequency freq_moon {freq};
double azsun,elsun,azmoon,elmoon,azmoondx,elmoondx;
double ramoon,decmoon,dgrd,poloffset,xnr,techo,width1,width2;
int ntsky;
QString date {t.date().toString("yyyy MMM dd").trimmed ()};
QString utc {t.time().toString().trimmed ()};
int nyear {t.date().year()};
int month {t.date().month()};
int nday {t.date().day()};
int nhr {t.time().hour()};
int nmin {t.time().minute()};
double sec {t.time().second() + 0.001*t.time().msec()};
double uth {nhr + nmin/60.0 + sec/3600.0};
if(freq_moon < 1) freq_moon = 144000000;
auto const& AzElFileName = QDir::toNativeSeparators (configuration_->azel_directory ().absoluteFilePath ("azel.dat"));
auto const& jpleph = configuration_->data_dir ().absoluteFilePath ("JPLEPH");
astrosub(nyear, month, nday, uth, static_cast<double> (freq_moon),
mygrid.toLatin1 ().data (),
hisgrid.toLatin1().data(),
&azsun, &elsun, &azmoon, &elmoon,
&azmoondx, &elmoondx, &ntsky, &m_dop, &m_dop00, &ramoon, &decmoon,
&dgrd, &poloffset, &xnr, &techo, &width1, &width2,
bTx,
AzElFileName.toLocal8Bit ().constData (),
jpleph.toLocal8Bit ().constData ());
QString message;
{
QTextStream out {&message};
out << " " << date << "\n"
"UTC: " << utc << "\n"
2020-06-13 11:04:41 -04:00
#if QT_VERSION >= QT_VERSION_CHECK(5, 15, 0)
<< Qt::fixed
#else
<< fixed
2020-06-13 11:04:41 -04:00
#endif
<< qSetFieldWidth (6)
<< qSetRealNumberPrecision (1)
<< "Az: " << azmoon << "\n"
"El: " << elmoon << "\n"
"SelfDop:" << m_dop00 << "\n"
"Width: " << int(width1) << "\n"
<< qSetRealNumberPrecision (2)
<< "Delay: " << techo << "\n"
<< qSetRealNumberPrecision (1)
<< "DxAz: " << azmoondx << "\n"
"DxEl: " << elmoondx << "\n"
"DxDop: " << m_dop << "\n"
"DxWid: " << int(width2) << "\n"
"Dec: " << decmoon << "\n"
"SunAz: " << azsun << "\n"
"SunEl: " << elsun << "\n"
"Freq: " << freq / 1.e6 << "\n";
if(freq>=5000000ull) { //Suppress data not relevant below VHF
out << "Tsky: " << ntsky << "\n"
"Dpol: " << poloffset << "\n"
"MNR: " << xnr << "\n"
"Dist: " << int((techo*149896)) << "\n" //wdg
"Dgrd: " << dgrd;
}
}
ui_->text_label->setText(message);
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
Correction correction;
if (ui_->cbDopplerTracking->isChecked ()) {
switch (m_DopplerMethod)
{
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
case 1: // All Doppler correction done here; DX station stays at nominal dial frequency.
correction.rx = m_dop;
break;
case 4: // All Doppler correction done here; DX station stays at nominal dial frequency. (Trial for OnDxEcho)
correction.rx = m_dop;
break;
//case 5: // All Doppler correction done here; DX station stays at nominal dial frequency.
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
case 3: // Both stations do full correction on Rx and none on Tx
//correction.rx = dx_is_self ? m_dop00 : m_dop;
correction.rx = m_dop00; // Now always sets RX to *own* echo freq
break;
case 2:
// Doppler correction to constant frequency on Moon
correction.rx = m_dop00 / 2;
break;
}
switch (m_DopplerMethod)
{
case 1: correction.tx = -correction.rx;
break;
case 2: correction.tx = -correction.rx;
break;
case 3: correction.tx = 0;
break;
case 4: // correction.tx = m_dop - m_dop00;
correction.tx = (2 * (m_dop - (m_dop00/2))) - m_dop;
//qDebug () << "correction.tx:" << correction.tx;
break;
case 5: correction.tx = - m_dop00;
break;
}
//if (3 != m_DopplerMethod || 4 != m_DopplerMethod) correction.tx = -correction.rx;
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
if(dx_is_self && m_DopplerMethod == 1) correction.rx = 0;
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
if (no_tx_QSY && 3 != m_DopplerMethod && 0 != m_DopplerMethod)
{
// calculate a single correction for transmit half way through
// the period as a compromise for rigs that can't CAT QSY
// while transmitting
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
//
// use a base time of (secs-since-epoch + 2) so as to be sure
// we do the next period if we calculate just before it starts
auto sec_since_epoch = t.toMSecsSinceEpoch ()/1000 + 2;
auto target_sec = sec_since_epoch - fmod(double(sec_since_epoch),TR_period) + 0.5*TR_period;
auto target_date_time = QDateTime::fromMSecsSinceEpoch (target_sec * 1000, Qt::UTC);
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
int nyear {target_date_time.date().year()};
int month {target_date_time.date().month()};
int nday {target_date_time.date().day()};
int nhr {target_date_time.time().hour()};
int nmin {target_date_time.time().minute()};
double sec {target_date_time.time().second() + 0.001*target_date_time.time().msec()};
double uth {nhr + nmin/60.0 + sec/3600.0};
astrosub(nyear, month, nday, uth, static_cast<double> (freq_moon),
mygrid.toLatin1 ().data (),
hisgrid.toLatin1().data(),
&azsun, &elsun, &azmoon, &elmoon,
&azmoondx, &elmoondx, &ntsky, &m_dop, &m_dop00, &ramoon, &decmoon,
&dgrd, &poloffset, &xnr, &techo, &width1, &width2,
bTx,
nullptr, // don't overwrite azel.dat
jpleph.toLocal8Bit ().constData ());
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
FrequencyDelta offset {0};
switch (m_DopplerMethod)
{
case 1:
// All Doppler correction done here; DX station stays at nominal dial frequency.
offset = dx_is_self ? m_dop00 : m_dop;
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
break;
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
case 2:
// Doppler correction to constant frequency on Moon
offset = m_dop00 / 2;
break;
case 4:
// Doppler correction for OnDxEcho
offset = m_dop - (2 * (m_dop - (m_dop00/2)));
break;
//case 5: correction.tx = - m_dop00;
case 5: offset = m_dop00;// version for _7
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
break;
}
correction.tx = -offset;
//qDebug () << "correction.tx (no tx qsy):" << correction.tx;
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
}
}
return correction;
}
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
void Astro::check_split ()
{
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
if (doppler_tracking () && !configuration_->split_mode ())
{
MessageBox::warning_message (this, tr ("Doppler Tracking Error"),
tr ("Split operating is required for Doppler tracking"),
tr ("Go to \"Menu->File->Settings->Radio\" to enable split operation"));
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
ui_->rbNoDoppler->click ();
}
}
void Astro::on_rbFullTrack_clicked(bool)
{
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
m_DopplerMethod = 1;
check_split ();
Q_EMIT tracking_update ();
}
void Astro::on_rbOnDxEcho_clicked(bool)
{
m_DopplerMethod = 4;
check_split ();
//if (checked) {
// m_dx_two_way_dop = 2 * (m_dop - (m_dop00/2));
// qDebug () << "Starting Doppler:" << m_dx_two_way_dop;
//}
Q_EMIT tracking_update ();
}
void Astro::on_rbOwnEcho_clicked(bool)
{
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
m_DopplerMethod = 3;
check_split ();
Q_EMIT tracking_update ();
}
void Astro::on_rbCallDx_clicked(bool)
{
m_DopplerMethod = 5;
check_split ();
Q_EMIT tracking_update ();
}
void Astro::on_rbConstFreqOnMoon_clicked(bool)
{
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
m_DopplerMethod = 2;
check_split ();
Q_EMIT tracking_update ();
}
void Astro::on_rbNoDoppler_clicked(bool)
{
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
m_DopplerMethod = 0;
Q_EMIT tracking_update ();
}
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
bool Astro::doppler_tracking () const
{
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
return ui_->cbDopplerTracking->isChecked () && m_DopplerMethod;
}
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
void Astro::on_cbDopplerTracking_toggled(bool)
{
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
check_split ();
Q_EMIT tracking_update ();
}
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
void Astro::nominal_frequency (Frequency rx, Frequency tx)
{
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
ui_->sked_frequency_label->setText (Radio::pretty_frequency_MHz_string (rx));
ui_->sked_tx_frequency_label->setText (Radio::pretty_frequency_MHz_string (tx));
}
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
void Astro::hideEvent (QHideEvent * e)
{
Rig control overhaul to implement generic Doppler shift tracking The concept of a nominal receive and transmit frequency has been introduced. This is used as a base frequency for Doppler correction, frequency setting and reporting. The start up frequency is now zero which is updated by the first rig control status report. This needs more work to accommodate calling frequency plus working frequency operation as is used for random MS operation etc.. The main window frequency display now shows the transmit dial frequency while transmitting. The mode changing logic sequence has been changed such that the rig is correctly put into and taken out of split mode as required by the target mode. This also avoids the "other" VFO having its frequency changed when entering a mode that does not use split operating like WSPR. The main window band combo box edit may now be used to input an kHz offset from the current MHz dial frequency. This is intended for setting a sked or working frequency on the VHF and up bands. For example the working frequency for 23cms might be set to 1296MHz and a working frequency of 1296.3MHz would be selected by selecting the 23cms band with the combo box drop down list and then entering 300k into the band combo box edit widget. When using JT4 modes a CTRL+Click on the waterfall adjusts the nominal frequency such that the frequency clicked on becomes the Tx and Rx frequency using the fixed 1000Hz DF that JT4 modes use. This will probably be extended to all QSO modes when used in VHF & up mode. This assumes that 1000Hz is an optimal DF for both Tx and Rx and therefore one can "net" to an off frequency, but visible on the waterfall, caller with one click. Improvements to OmniRig rig control including use of the serial port control lines RTS or DTR, on the CAT serial port used by OmniRig, for PTT control. Incrementing transaction sequence numbers added to messages to and from the rig control thread. This enables round trip status to be tracked and associated with a request. For example a command that might cause several asynchronous status updates can now be tracked in the originating thread such that it is clear which updates are caused by executing the request. This in turn allows updates to be held until the request is complete i.e. the state is consistent with the results of the request. Messages to the rig control thread are now posted as a new state (Transceiver::TransceiverState) object. The rig control thread tracks requests and actions any differences between the prior requests and the new state. The rig control thread is now stored on the heap so that it can be closed down and released as needed. Along with this the rig control close down semantics are better defined avoiding some potential deadlock situations. If the rig is placed into split mode it will be reverted to simplex mode when the rig connection is closed. When using direct rig control via Hamlib, rigs that have A/B VFO arrangements and no method to query the current VFO like many Icoms and the Yaesu FT-817/857/897(D) series now have smarted frequency updating requiring no VFO changes when changing the frequency. This is particularly important when doing Tx Doppler correction to avoid glitches. The implementation of emulated split operating mode ("Fake It") is simplified and improved. A dummy Hamlib transceiver for PTT control on a separate port is no long instantiated if CAT or VOX PTT control is selected. The resolution and any rounding of the rig CAT frequency set and get commands is determined automatically upon opening the rig connection. This is needed to determine the rate of frequency updates for Doppler tracking. It also allows the rig to be more accurately controlled. Frequency calibration is calculated separately for the receive and transmit frequencies. Whether the rig modulation mode should be controlled is now a constructor argument rather than being passed with individual rig control requests. Doppler shift correction is considerably enhanced with simpler controls and much better rig control. A new mode of tracking called "receive only" is introduced for those with rigs that cannot be QSY:ed via CAT when transmitting. Such rigs have a Doppler correction calculated for the middle of the next transmit period just before transmission starts. While using Doppler tracking it is now possible to adjust the sked frequency either using the new kHz offset feature of the main window band combo box or by directly tuning the rig VFO knob while holding down the CTRL key. The astronomical data window that includes Doppler tracking control is now opened and closed using a checkable menu item to avoid it being accidentally closed. Debug configuration rig control diagnostic messages now have a facility argument for clearer and more standardized trace messages. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6590 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
2016-04-06 13:11:58 -04:00
Q_EMIT tracking_update ();
QWidget::hideEvent (e);
}