4#include "configobject.hh"
18 Q_CLASSINFO(
"description",
"Settings for MD-390, RT8, MD-UV390, RT3S, MD-2017, RT82, DM-1701, RT84.")
19 Q_CLASSINFO(
"longDescription",
"Device specific channel settings for TyT and Retevis devices."
20 "Including TyT MD-390, MD-UV390, MD-2017, Retevis RT8, RT3S and RT82"
21 " as well as Baofeng DM-1701.")
49 Q_CLASSINFO(
"dmrSquelchDescription",
"Sets the squelch level for DMR channels. "
50 "Only applicable for MD-UV390 and MD-2017")
55 Low=0, Medium=1, High=2
61 Tone259_2Hz=0, Tone55_2Hz=1, Off=3
67 Always = 0, AdmitCriterion=1, TXInterrupt=2
278 ButtonAction sideButton1Short()
const;
280 void setSideButton1Short(ButtonAction action);
282 ButtonAction sideButton1Long()
const;
284 void setSideButton1Long(ButtonAction action);
287 ButtonAction sideButton2Short()
const;
289 void setSideButton2Short(ButtonAction action);
291 ButtonAction sideButton2Long()
const;
293 void setSideButton2Long(ButtonAction action);
296 ButtonAction sideButton3Short()
const;
298 void setSideButton3Short(ButtonAction action);
300 ButtonAction sideButton3Long()
const;
302 void setSideButton3Long(ButtonAction action);
305 ButtonAction progButton1Short()
const;
307 void setProgButton1Short(ButtonAction action);
309 ButtonAction progButton1Long()
const;
311 void setProgButton1Long(ButtonAction action);
314 ButtonAction progButton2Short()
const;
316 void setProgButton2Short(ButtonAction action);
318 ButtonAction progButton2Long()
const;
320 void setProgButton2Long(ButtonAction action);
323 unsigned longPressDuration()
const;
325 void setLongPressDuration(
unsigned dur);
649 Q_CLASSINFO(
"powerSaveModeDescription",
"Puts the radio into sleep-mode when idle.")
650 Q_CLASSINFO(
"powerSaveModeLongDescription",
651 "When enabled, the radio enters a sleep mode when idle. That is, when on receive and "
652 "there is no activity on the current channel. However, the radio may need some time "
653 "to wake up from this mode. Hence, the 'wakeupPreamble' need to be enabled by all "
654 "radios in the network to provide this wake-up delay.")
657 Q_CLASSINFO(
"wakeupPreambleDescription",
"If enabled, the radio will transmit a short wake-up "
658 "preamble before each call.")
702 Q_CLASSINFO(
"description",
"Settings for MD-390, RT8, MD-UV390, RT3S, MD-2017, RT82.")
703 Q_CLASSINFO(
"longDescription",
"Device specific radio settings for TyT and Retevis devices."
704 "Including TyT MD-390, MD-UV390, MD-2017 as well as Retevis RT8, "
709 enum class MonitorType {
721 MonitorType monitorType()
const;
723 void setMonitorType(MonitorType type);
726 bool allLEDsDisabled()
const;
728 void disableAllLEDs(
bool disable);
731 bool talkPermitToneDigital()
const;
733 void enableTalkPermitToneDigital(
bool enable);
736 bool talkPermitToneAnalog()
const;
738 void enableTalkPermitToneAnalog(
bool enable);
741 bool passwordAndLock()
const;
743 void enablePasswordAndLock(
bool enable);
746 bool channelFreeIndicationTone()
const;
748 void enableChannelFreeIndicationTone(
bool enable);
751 bool allTonesDisabled()
const;
753 void disableAllTones(
bool disable);
756 bool powerSaveMode()
const;
758 void enablePowerSaveMode(
bool enable);
761 bool wakeupPreamble()
const;
763 void enableWakeupPreamble(
bool enable);
766 bool bootPicture()
const;
768 void enableBootPicture(
bool enable);
771 bool channelMode()
const;
773 void enableChannelMode(
bool enable);
775 bool channelModeA()
const;
777 void enableChannelModeA(
bool enable);
779 bool channelModeB()
const;
781 void enableChannelModeB(
bool enable);
784 unsigned lowBatteryWarnInterval()
const;
786 void setLowBatteryWarnInterval(
unsigned sec);
789 bool callAlertToneContinuous()
const;
791 void enableCallAlertToneContinuous(
bool enable);
793 unsigned callAlertToneDuration()
const;
795 void setCallAlertToneDuration(
unsigned sec);
798 unsigned loneWorkerResponseTime()
const;
800 void setLoneWorkerResponseTime(
unsigned min);
803 unsigned loneWorkerReminderTime()
const;
805 void setLoneWorkerReminderTime(
unsigned sec);
808 unsigned digitalScanHangTime()
const;
810 void setDigitalScanHangTime(
unsigned ms);
813 unsigned analogScanHangTime()
const;
815 void setAnalogScanHangTime(
unsigned ms);
818 bool backlightAlwaysOn()
const;
820 void enableBacklightAlwaysOn(
bool enable);
822 unsigned backlightDuration()
const;
824 void setBacklightDuration(
unsigned sec);
827 bool keypadLockManual()
const;
829 void enableKeypadLockManual(
bool enable);
831 unsigned keypadLockTime()
const;
833 void setKeypadLockTime(
unsigned sec);
836 bool powerOnPasswordEnabled()
const;
838 void enablePowerOnPassword(
bool enable);
840 unsigned powerOnPassword()
const;
842 void setPowerOnPassword(
unsigned passwd);
845 bool radioProgPasswordEnabled()
const;
847 void enableRadioProgPassword(
bool enable);
849 unsigned radioProgPassword()
const;
851 void setRadioProgPassword(
unsigned passwd);
854 const QString &pcProgPassword()
const;
856 void setPCProgPassword(
const QString &passwd);
859 unsigned channelHangTime()
const;
861 void setChannelHangTime(
unsigned ms);
ConfigExtension(QObject *parent=nullptr)
Hidden constructor.
Definition configobject.cc:1234
Base class for all configuration objects (channels, zones, contacts, etc).
Definition configobject.hh:35
ConfigItem(QObject *parent=nullptr)
Hidden constructor.
Definition configobject.cc:158
Some simple class implementing a [1-10] level setting.
Definition level.hh:15
void setRXRefFrequency(RefFrequency ref)
Sets the reference frequency setting for RX.
Definition tyt_extensions.cc:76
RefFrequency txRefFrequency() const
Returns the reference frequency setting for TX.
Definition tyt_extensions.cc:85
void enableDCDMLeader(bool enable)
Enables/disables this radio to be the leader on a DCDM simplex channel.
Definition tyt_extensions.cc:188
Level _dmrSquelch
The squelch level [0-10] for DMR channels.
Definition tyt_extensions.hh:161
bool dcdmLeader() const
Returns true if this radio is the leader for a DCDM simplex channel.
Definition tyt_extensions.cc:183
void enableEmergencyAlarmConfirmed(bool enable)
Enables/disables emergency-call confirmation.
Definition tyt_extensions.cc:48
bool _autoScan
Holds the auto-scan flag.
Definition tyt_extensions.hh:135
void setKillTone(KillTone tone)
Sets the kill-tone frequency.
Definition tyt_extensions.cc:146
KillTone killTone() const
Returns the kill tone frequency.
Definition tyt_extensions.cc:141
bool _displayPTTId
Holds the display PTT ID flag.
Definition tyt_extensions.hh:139
bool _tightSquelch
Holds the tightSquelch flag.
Definition tyt_extensions.hh:147
void enableDisplayPTTId(bool enable)
Enables/disables analog PTT ID display.
Definition tyt_extensions.cc:62
void setInCallCriterion(InCallCriterion crit)
Sets the in-call criterion.
Definition tyt_extensions.cc:160
bool emergencyAlarmConfirmed() const
Returns true if emergency calls are confirmed.
Definition tyt_extensions.cc:43
Q_INVOKABLE TyTChannelExtension(QObject *parent=nullptr)
Default constructor.
Definition tyt_extensions.cc:7
bool tightSquelch() const
Returns true if the tight squelch is enabled.
Definition tyt_extensions.cc:113
void enableAutoScan(bool enable)
Enables/disables the auto-scan feature.
Definition tyt_extensions.cc:34
RefFrequency
Possible reference frequency settings for RX & TX.
Definition tyt_extensions.hh:54
void enableTightSquelch(bool enable)
Enables/disables the tight squelch.
Definition tyt_extensions.cc:118
bool autoScan() const
Returns true if the auto scan feature is enabled.
Definition tyt_extensions.cc:29
bool _allowInterrupt
Holds the interrupt flag.
Definition tyt_extensions.hh:157
bool _dcdmLeader
Holds the DCDM-leader flag.
Definition tyt_extensions.hh:159
InCallCriterion
Possible in-call criterions.
Definition tyt_extensions.hh:66
ConfigItem * clone() const
Clones this item.
Definition tyt_extensions.cc:18
RefFrequency _rxRefFrequency
Holds the reference frequency setting for RX.
Definition tyt_extensions.hh:141
bool displayPTTId() const
Returns true if analog PTT IDs are shown.
Definition tyt_extensions.cc:57
Level dmrSquelch() const
Squelch level for DMR channels.
Definition tyt_extensions.cc:99
InCallCriterion _inCallCriterion
Holds the in-call criterion.
Definition tyt_extensions.hh:155
void enableAllowInterrupt(bool enable)
Enables/disables interrupt.
Definition tyt_extensions.cc:174
bool compressedUDPHeader() const
Returns true if the compressed UDP header is enabled.
Definition tyt_extensions.cc:127
RefFrequency _txRefFrequency
Holds the reference frequency setting for TX.
Definition tyt_extensions.hh:143
bool _emergencyAlarmConfirmed
Holds the emergency-call confirmation flag.
Definition tyt_extensions.hh:137
void setTXRefFrequency(RefFrequency ref)
Sets the reference frequency setting for TX.
Definition tyt_extensions.cc:90
KillTone _killTone
Holds the kill tone setting.
Definition tyt_extensions.hh:153
bool allowInterrupt() const
Returns true if interrupt is allowed.
Definition tyt_extensions.cc:169
void enableCompressedUDPHeader(bool enable)
Enables/disables the compressed UDP header.
Definition tyt_extensions.cc:132
KillTone
Possible kill-tone settings.
Definition tyt_extensions.hh:60
InCallCriterion inCallCriterion() const
Returns the in-call criterion.
Definition tyt_extensions.cc:155
bool _compressedUDPHeader
Holds the compressed UDP header flag.
Definition tyt_extensions.hh:149
RefFrequency rxRefFrequency() const
Returns the reference frequency setting for RX.
Definition tyt_extensions.cc:71
void setDMRSquelch(Level sq)
Sets the squelch-level for DMR channels.
Definition tyt_extensions.cc:104
TyTButtonSettings * buttonSettings
The button settings for TyT devices.
Definition tyt_extensions.hh:947
Q_INVOKABLE TyTConfigExtension(QObject *parent=nullptr)
Constructor.
Definition tyt_extensions.cc:1177
TyTButtonSettings * _buttonSettings
Owns the button settings extension.
Definition tyt_extensions.hh:969
ConfigItem * clone() const
Clones this item.
Definition tyt_extensions.cc:1185
TyTMenuSettings * menuSettings
The menu settings for TyT devices.
Definition tyt_extensions.hh:949
TyTMenuSettings * _menuSettings
Owns the menu settings extension.
Definition tyt_extensions.hh:971
unsigned _prioritySampleTime
The sample time for priority channels in ms.
Definition tyt_extensions.hh:199
Q_INVOKABLE TyTScanListExtension(QObject *parent=nullptr)
Default constructor.
Definition tyt_extensions.cc:199
ConfigItem * clone() const
Clones this item.
Definition tyt_extensions.cc:206
void setHoldTime(unsigned ms)
Sets the hold time im ms.
Definition tyt_extensions.cc:220
unsigned holdTime
Holds the hold time in ms.
Definition tyt_extensions.hh:172
unsigned _holdTime
The hold time in ms.
Definition tyt_extensions.hh:197
unsigned prioritySampleTime
Holds the sample time in ms for priority channels.
Definition tyt_extensions.hh:174
void setPrioritySampleTime(unsigned ms)
Sets the sample time for priority channels in ms.
Definition tyt_extensions.cc:232
Represents the TyT general settings extension.
Definition tyt_extensions.hh:630
void enableChannelMode(bool enable)
Enables/disables channel mode for the radio.
Definition tyt_extensions.cc:938
bool _privateCallMatch
If true, the private call IDs must match.
Definition tyt_extensions.hh:932
unsigned radioProgPassword
If radioProgPasswordEnabled is true, specifies the radio programming password.
Definition tyt_extensions.hh:696
unsigned _powerOnPassword
Holds the power-on password.
Definition tyt_extensions.hh:924
unsigned analogScanHangTime
The analog channel scan hang time in ms.
Definition tyt_extensions.hh:680
bool _channelMode
If true, the radio is in channel (memory) mode.
Definition tyt_extensions.hh:892
bool channelFreeIndicationTone
If true, the channel free tone is enabled.
Definition tyt_extensions.hh:644
unsigned _lowBatteryWarnInterval
Holds the low-battery warn interval.
Definition tyt_extensions.hh:900
unsigned channelHangTime
Holds the channel hang time in ms.
Definition tyt_extensions.hh:700
unsigned lowBatteryWarnInterval
The low battery warn interval in seconds.
Definition tyt_extensions.hh:668
unsigned _txPreambleDuration
Holds the TX preamble duration.
Definition tyt_extensions.hh:894
void setMonitorType(MonitorType type)
Sets the monitor type.
Definition tyt_extensions.cc:817
void enableBootPicture(bool enable)
Enables the boot picture.
Definition tyt_extensions.cc:925
unsigned _groupCallHangTime
Holds the group-call hang time.
Definition tyt_extensions.hh:896
bool channelModeA
If true or channelMode is true, the VFO A is in channel mode.
Definition tyt_extensions.hh:664
bool channelModeB
If true or channelMode is true, the VFO B is in channel mode.
Definition tyt_extensions.hh:666
void enableRadioProgPassword(bool enable)
Enables the radio programming password.
Definition tyt_extensions.cc:1124
MonitorType monitorType
The monitor type setting.
Definition tyt_extensions.hh:634
void setLowBatteryWarnInterval(unsigned sec)
Sets the low-battery warn interval in seconds.
Definition tyt_extensions.cc:972
void setRadioProgPassword(unsigned passwd)
Sets the radio programming password.
Definition tyt_extensions.cc:1135
void enableChannelFreeIndicationTone(bool enable)
Enables channel-free indication tone.
Definition tyt_extensions.cc:877
bool _channelModeB
If true or channelMode is true, the VFO B is in channel (memory) mode.
Definition tyt_extensions.hh:890
void setCallAlertToneDuration(unsigned sec)
Sets the call alert-tone duration in seconds.
Definition tyt_extensions.cc:995
callbool bootPicture
If true, a picture is shown during boot.
Definition tyt_extensions.hh:660
unsigned _backlightDuration
Holds the backlight duration.
Definition tyt_extensions.hh:916
void setPCProgPassword(const QString &passwd)
Sets PC programming password.
Definition tyt_extensions.cc:1147
bool allLEDsDisabled
If true, all LEDs are disabled.
Definition tyt_extensions.hh:636
bool radioProgPasswordEnabled
If true the radio programming password is enabled.
Definition tyt_extensions.hh:694
unsigned loneWorkerResponseTime
The lone-worker response time in minutes.
Definition tyt_extensions.hh:674
unsigned callAlertToneDuration
The call alert duration in seconds.
Definition tyt_extensions.hh:672
void enableKeypadLockManual(bool enable)
Sets the keypad lock to manual.
Definition tyt_extensions.cc:1078
bool powerSaveMode
If true, the power save mode is enabled.
Definition tyt_extensions.hh:648
bool powerOnPasswordEnabled
If true the power-on password is enabled.
Definition tyt_extensions.hh:690
bool _powerOnPasswordEnabled
If true, the power-on password is enabled.
Definition tyt_extensions.hh:922
bool _allTonesDisabled
If true, all tones are disabled.
Definition tyt_extensions.hh:880
unsigned _digitalScanHangTime
Holds the scan hang-time for digital channels.
Definition tyt_extensions.hh:910
bool backlightAlwaysOn
If true, the backlight is always on.
Definition tyt_extensions.hh:682
bool callAlertToneContinuous
If true, the call alert-tone is continuous.
Definition tyt_extensions.hh:670
QString _pcProgPassword
Holds the PC programming password.
Definition tyt_extensions.hh:930
unsigned digitalScanHangTime
The digital channel scan hang time in ms.
Definition tyt_extensions.hh:678
void disableAllLEDs(bool disable)
Disables all LEDs.
Definition tyt_extensions.cc:829
bool allTonesDisabled
If true, all tones are disabled.
Definition tyt_extensions.hh:646
void enableWakeupPreamble(bool enable)
Enables transmission of wakeup preamble.
Definition tyt_extensions.cc:913
unsigned backlightDuration
If backlightAlwaysOn is false, specifies the backlight duration in seconds.
Definition tyt_extensions.hh:684
bool talkPermitToneDigital
If true, the talk permit tone for digital channels is enabled.
Definition tyt_extensions.hh:638
void enableChannelModeA(bool enable)
Enables/disables channel mode for the VFO A.
Definition tyt_extensions.cc:949
bool talkPermitToneAnalog
If true, the talk permit tone for analog channels is enabled.
Definition tyt_extensions.hh:640
bool passwordAndLock
If true, the password and lock is enabled.
Definition tyt_extensions.hh:642
void setLoneWorkerReminderTime(unsigned sec)
Sets the lone-worker reminder timer in seconds.
Definition tyt_extensions.cc:1019
unsigned _privateCallHangTime
Holds the private-call hang time.
Definition tyt_extensions.hh:898
unsigned powerOnPassword
If powerOnPasswordEnabled is true, specifies the power-on password.
Definition tyt_extensions.hh:692
bool _channelModeA
If true or channelMode is true, the VFO A is in channel (memory) mode.
Definition tyt_extensions.hh:888
unsigned keypadLockTime
If keypadLockManual is false, specifies the keypad lock time.
Definition tyt_extensions.hh:688
bool _channelFreeIndicationTone
If true, the channel free indication tone is enabled.
Definition tyt_extensions.hh:878
unsigned _loneWorkerReminderTime
Holds the lone-worker reminder time.
Definition tyt_extensions.hh:908
Q_INVOKABLE TyTSettingsExtension(QObject *parent=nullptr)
Possible monitor types.
Definition tyt_extensions.cc:784
bool _talkPermitToneDigital
If true the talk-permit tone is enabled for digital channels.
Definition tyt_extensions.hh:872
void setKeypadLockTime(unsigned sec)
Sets the keypad lock time in seconds.
Definition tyt_extensions.cc:1089
bool _wakeupPreamble
If true, the wake-up preamble is sent.
Definition tyt_extensions.hh:884
bool _groupCallMatch
If true, the group call IDs must match.
Definition tyt_extensions.hh:934
void enablePowerSaveMode(bool enable)
Enables the power save mode.
Definition tyt_extensions.cc:901
bool _radioProgPasswordEnabled
If true, the radio programming password is enabled.
Definition tyt_extensions.hh:926
void enableTalkPermitToneDigital(bool enable)
Enables the talk permit tone for digital channels.
Definition tyt_extensions.cc:841
void enableChannelModeB(bool enable)
Enables/disables channel mode for the VFO B.
Definition tyt_extensions.cc:960
bool keypadLockManual
If true, the keypad is locked manually.
Definition tyt_extensions.hh:686
unsigned _analogScanHangTime
Holds the scan hang-time for analog channels.
Definition tyt_extensions.hh:912
void enableTalkPermitToneAnalog(bool enable)
Enables the talk permit tone for analog channels.
Definition tyt_extensions.cc:853
unsigned _keypadLockTime
Holds the keypad lock time.
Definition tyt_extensions.hh:920
unsigned loneWorkerReminderTime
The lone-worker reminder time in seconds.
Definition tyt_extensions.hh:676
bool wakeupPreamble() const
Returns true if the wake-up preamble is sent.
Definition tyt_extensions.cc:909
void setChannelHangTime(unsigned ms)
Sets the channel hang time in ms.
Definition tyt_extensions.cc:1159
bool _powerSaveMode
If true, the power save mode is enabled.
Definition tyt_extensions.hh:882
bool _talkPermitToneAnalog
If true the talk-permit tone is enabled for analog channels.
Definition tyt_extensions.hh:874
bool _passwdAndLock
If true the password and lock is enabled.
Definition tyt_extensions.hh:876
void enableBacklightAlwaysOn(bool enable)
Enables the backlight continuously.
Definition tyt_extensions.cc:1055
bool _keypadLockManual
If true, the keypad lock is manual.
Definition tyt_extensions.hh:918
unsigned _callAlertToneDuration
Holds the call alert-tone duration.
Definition tyt_extensions.hh:904
void setAnalogScanHangTime(unsigned ms)
Sets the scan hang-time for analog channels.
Definition tyt_extensions.cc:1043
void setDigitalScanHangTime(unsigned ms)
Sets the scan hang-time for digital channels.
Definition tyt_extensions.cc:1031
void enablePasswordAndLock(bool enable)
Enables the password and lock.
Definition tyt_extensions.cc:865
bool _callAlertToneContinuous
If true, the call alert-tone is continuous.
Definition tyt_extensions.hh:902
MonitorType _monitorType
Holds the monitor type.
Definition tyt_extensions.hh:868
void enableCallAlertToneContinuous(bool enable)
Sets the call alert-tone continuous.
Definition tyt_extensions.cc:984
bool _allLEDsDisabled
If true all LEDs are disabled.
Definition tyt_extensions.hh:870
void enablePowerOnPassword(bool enable)
Enables the power on password.
Definition tyt_extensions.cc:1101
void setPowerOnPassword(unsigned passwd)
Sets the power-on password.
Definition tyt_extensions.cc:1112
unsigned _channelHangTime
Holds the channel hang time in ms.
Definition tyt_extensions.hh:936
void setBacklightDuration(unsigned sec)
Sets the backlight duration in seconds.
Definition tyt_extensions.cc:1066
bool _backlightAlwaysOn
If true, the backlight is always on.
Definition tyt_extensions.hh:914
bool channelMode
If true, the radio is in channel mode.
Definition tyt_extensions.hh:662
unsigned _radioProgPassword
Holds the radio programming password.
Definition tyt_extensions.hh:928
bool _bootPicture
If true the boot picture is enabled.
Definition tyt_extensions.hh:886
unsigned _loneWorkerResponseTime
Holds the lone-worker response time.
Definition tyt_extensions.hh:906
QString pcProgPassword
Specifies the PC programming password.
Definition tyt_extensions.hh:698
void setLoneWorkerResponseTime(unsigned min)
Sets the lone-worker response time in minutes.
Definition tyt_extensions.cc:1007
void disableAllTones(bool disable)
Disables all tones.
Definition tyt_extensions.cc:889