libdrmconf 0.14.1
A library to program DMR radios.
Loading...
Searching...
No Matches
channel.hh
1#ifndef CHANNEL_HH
2#define CHANNEL_HH
3
4#include <QObject>
5#include <QAbstractTableModel>
6
7#include "configobject.hh"
8#include "configreference.hh"
9#include "signaling.hh"
10#include "interval.hh"
11#include "level.hh"
12
13#include "channel_extension.hh"
14#include "opengd77_extension.hh"
15#include "tyt_extensions.hh"
16#include "opengd77_extension.hh"
17#include "anytone_extension.hh"
18#include "commercial_extension.hh"
19
20class Config;
21class RXGroupList;
22class DMRContact;
23class ScanList;
24class FMAPRSSystem;
26class RoamingZone;
27class DMRRadioID;
28
29
36class Channel: public ConfigObject
37{
38 Q_OBJECT
39
45 Q_PROPERTY(Power power READ power WRITE setPower SCRIPTABLE false)
47 Q_PROPERTY(Interval timeout READ timeout WRITE setTimeout)
49 Q_PROPERTY(bool rxOnly READ rxOnly WRITE setRXOnly)
53 Q_PROPERTY(Level vox READ vox WRITE setVOX)
58
60 Q_CLASSINFO("IdPrefix", "ch")
61
62public:
64 enum class Power {
70 };
71 Q_ENUM(Power)
72
78 Q_ENUM(OffsetShift)
79
80protected:
83 explicit Channel(QObject *parent=nullptr);
85 Channel(const Channel &other, QObject *parent=nullptr);
86
87public:
88 bool copy(const ConfigItem &other);
89 void clear();
90
92 Frequency rxFrequency() const;
94 bool setRXFrequency(Frequency freq);
96 Frequency txFrequency() const;
98 bool setTXFrequency(Frequency freq);
102 OffsetShift offsetShift() const;
103
105 bool defaultPower() const;
107 Power power() const;
109 void setPower(Power power);
111 void setDefaultPower();
112
114 bool defaultTimeout() const;
116 bool timeoutDisabled() const;
118 Interval timeout() const;
120 bool setTimeout(const Interval &dur);
122 void disableTimeout();
124 void setDefaultTimeout();
125
127 bool rxOnly() const;
129 bool setRXOnly(bool enable);
130
132 bool voxDisabled() const;
134 bool defaultVOX() const;
136 Level vox() const;
138 void setVOX(Level level);
140 void setVOXDefault();
142 void disableVOX();
143
145 const ScanListReference *scanListRef() const;
149 ScanList *scanList() const;
151 bool setScanList(ScanList *list);
152
158
164
165public:
166 bool parse(const YAML::Node &node, Context &ctx, const ErrorStack &err=ErrorStack());
167 bool link(const YAML::Node &node, const Context &ctx, const ErrorStack &err=ErrorStack());
168
169protected:
170 bool populate(YAML::Node &node, const Context &context, const ErrorStack &err=ErrorStack());
171
172protected slots:
174 void onReferenceModified();
175
176protected:
198};
199
200
201
206{
207 Q_OBJECT
208
210 Q_PROPERTY(Level squelch READ squelch WRITE setSquelch FINAL)
211
212protected:
214 explicit AnalogChannel(QObject *parent=nullptr);
215
216public:
218 AnalogChannel(const AnalogChannel &other, QObject *parent=nullptr);
219
220
222 bool defaultSquelch() const;
224 bool squelchDisabled() const;
226 Level squelch() const;
230 void disableSquelch();
232 void setSquelchDefault();
233
234
235protected:
238};
239
240
241
249{
250 Q_OBJECT
251
253 Q_PROPERTY(Admit admit READ admit WRITE setAdmit)
255 Q_PROPERTY(SelectiveCall rxTone READ rxTone WRITE setRXTone)
257 Q_PROPERTY(SelectiveCall txTone READ txTone WRITE setTXTone)
262
267
268
269public:
271 enum class Admit {
275 };
276 Q_ENUM(Admit)
277
278
279 enum class Bandwidth {
282 };
283 Q_ENUM(Bandwidth)
284
285public:
287 Q_INVOKABLE explicit FMChannel(QObject *parent=nullptr);
288
289 bool copy(const ConfigItem &other);
290 ConfigItem *clone() const;
291 void clear();
292
294 Admit admit() const;
296 void setAdmit(Admit admit);
297
299 SelectiveCall rxTone() const;
301 bool setRXTone(SelectiveCall code);
303 SelectiveCall txTone() const;
305 bool setTXTone(SelectiveCall code);
306
308 Bandwidth bandwidth() const;
310 bool setBandwidth(Bandwidth bw);
311
313 const FMAPRSSystemReference *aprsRef() const;
317 FMAPRSSystem *aprs() const;
319 void setAPRS(FMAPRSSystem *sys);
320
323
329
330public:
331 YAML::Node serialize(const Context &context, const ErrorStack &err=ErrorStack());
332 bool parse(const YAML::Node &node, Context &ctx, const ErrorStack &err=ErrorStack());
333
334protected:
349};
350
351
352
360{
361 Q_OBJECT
362
363public:
365 Q_INVOKABLE explicit AMChannel(QObject *parent=nullptr);
366
367 bool copy(const ConfigItem &other) override;
368 ConfigItem *clone() const override;
369 void clear() override;
370
371public:
372 YAML::Node serialize(const Context &context, const ErrorStack &err=ErrorStack()) override;
373 bool parse(const YAML::Node &node, Context &ctx, const ErrorStack &err=ErrorStack()) override;
374};
375
376
377
382{
383 Q_OBJECT
384
385protected:
387 explicit DigitalChannel(QObject *parent=nullptr);
388
389public:
391 DigitalChannel(const DigitalChannel &other, QObject *parent=nullptr);
392};
393
394
395
402{
403 Q_OBJECT
404
406 Q_PROPERTY(Admit admit READ admit WRITE setAdmit)
408 Q_PROPERTY(unsigned colorCode READ colorCode WRITE setColorCode)
410 Q_PROPERTY(TimeSlot timeSlot READ timeSlot WRITE setTimeSlot)
421
428
429public:
431 enum class Admit {
435 };
436 Q_ENUM(Admit)
437
438
439 enum class TimeSlot {
442 };
443 Q_ENUM(TimeSlot)
444
445public:
447 Q_INVOKABLE explicit DMRChannel(QObject *parent=nullptr);
448
449 ConfigItem *clone() const;
450 void clear();
451
453 Admit admit() const;
455 void setAdmit(Admit admit);
456
458 unsigned colorCode() const;
460 bool setColorCode(unsigned cc);
461
463 TimeSlot timeSlot() const;
465 bool setTimeSlot(TimeSlot ts);
466
468 const GroupListReference *groupListRef() const;
472 RXGroupList *groupList() const;
474 bool setGroupList(RXGroupList *rxg);
475
477 const DMRContactReference *contactRef() const;
481 DMRContact *contact() const;
483 bool setContact(DMRContact *c);
484
486 const PositioningSystemReference *aprsRef() const;
493
495 const RoamingZoneReference *roamingRef() const;
499 RoamingZone *roaming() const;
501 bool setRoaming(RoamingZone *zone);
502
504 const DMRRadioIDReference *radioIdRef() const;
508 DMRRadioID *radioId() const;
510 bool setRadioId(DMRRadioID *id);
511
514
519
525
526public:
527 YAML::Node serialize(const Context &context, const ErrorStack &err=ErrorStack());
528
529protected:
533 unsigned _colorCode;
546
553};
554
555
556
560{
561 Q_OBJECT
562
563protected:
566 explicit SelectedChannel();
567
568public:
570 virtual ~SelectedChannel();
571
572 bool copy(const ConfigItem &other);
573 ConfigItem *clone() const;
574
576 static SelectedChannel *get();
577
578protected:
581};
582
583
584
593{
594 Q_OBJECT
595
596public:
598 explicit ChannelList(QObject *parent=nullptr);
599
600 int add(ConfigObject *obj, int row=-1, bool unique=true);
601
603 Channel *channel(int idx) const;
605 DMRChannel *findDMRChannel(Frequency rx, Frequency tx, DMRChannel::TimeSlot ts, unsigned cc) const;
608
609public:
610 ConfigItem *allocateChild(const YAML::Node &node, ConfigItem::Context &ctx, const ErrorStack &err=ErrorStack());
611};
612
613
614#endif // CHANNEL_HH
void clear() override
Clears the config object.
Definition channel.cc:589
bool copy(const ConfigItem &other) override
Copies the given item into this one.
Definition channel.cc:571
Q_INVOKABLE AMChannel(QObject *parent=nullptr)
Constructs a new empty AM channel.
Definition channel.cc:563
ConfigItem * clone() const override
Clones this item.
Definition channel.cc:579
bool parse(const YAML::Node &node, Context &ctx, const ErrorStack &err=ErrorStack()) override
Parses the given YAML node, updates the given object and updates the given context (IDs).
Definition channel.cc:606
YAML::Node serialize(const Context &context, const ErrorStack &err=ErrorStack()) override
Recursively serializes the configuration to YAML nodes.
Definition channel.cc:595
bool squelchDisabled() const
Returns true if the squelch is disabled.
Definition channel.cc:370
Level _squelch
Squelch.
Definition channel.hh:237
Level squelch
Specifies the squelch level for the channel.
Definition channel.hh:210
AnalogChannel(QObject *parent=nullptr)
Hidden constructor.
Definition channel.cc:351
void disableSquelch()
Disables the quelch.
Definition channel.cc:386
bool defaultSquelch() const
Returns true if the global default squelch level is used.
Definition channel.cc:366
void setSquelchDefault()
Sets the squelch to the global default value.
Definition channel.cc:390
bool setSquelch(Level squelch)
(Re-)Sets the squelch level [0,10].
Definition channel.cc:378
Implements the settings extension for DMR channels on AnyTone devices.
Definition anytone_extension.hh:204
Implements the settings extension for FM channels on AnyTone devices.
Definition anytone_extension.hh:133
ChannelList(QObject *parent=nullptr)
Constructs an empty channel list.
Definition channel.cc:930
int add(ConfigObject *obj, int row=-1, bool unique=true)
Adds an element to the list.
Definition channel.cc:937
ConfigItem * allocateChild(const YAML::Node &node, ConfigItem::Context &ctx, const ErrorStack &err=ErrorStack())
Allocates a member objects for the given YAML node.
Definition channel.cc:982
Channel * channel(int idx) const
Gets the channel at the specified index.
Definition channel.cc:946
DMRChannel * findDMRChannel(Frequency rx, Frequency tx, DMRChannel::TimeSlot ts, unsigned cc) const
Finds a digital channel with the given frequencies, time slot and color code.
Definition channel.cc:953
FMChannel * findFMChannelByTxFreq(Frequency freq) const
Finds an analog channel with the given frequency.
Definition channel.cc:971
The base class of all channels (analog and digital) of a codeplug configuration.
Definition channel.hh:37
ScanList * scanList() const
Returns the default scan list for the channel.
Definition channel.cc:246
bool link(const YAML::Node &node, const Context &ctx, const ErrorStack &err=ErrorStack())
Links the given object to the rest of the codeplug using the given context.
Definition channel.cc:334
void setDefaultTimeout()
Sets the timeout to the global default timeout.
Definition channel.cc:182
Interval timeout
The transmit timeout in seconds.
Definition channel.hh:47
FrequencyOffset offsetFrequency() const
Returns the offset between tx and rx frequency of the channel in Hz.
Definition channel.cc:110
bool defaultTimeout() const
Returns true if the transmit timeout is specified by the global default value.
Definition channel.cc:156
ScanListReference * scanListRef
The scan list.
Definition channel.hh:51
TyTChannelExtension * tyt
The TyT channel extension.
Definition channel.hh:57
bool _defaultPower
If true, the channel uses the global power setting.
Definition channel.hh:182
Frequency _txFreq
The TX frequency in Hz.
Definition channel.hh:180
void setPower(Power power)
(Re-)Sets the power setting of the channel, overrides default power.
Definition channel.cc:137
Power power
The transmit power.
Definition channel.hh:45
OffsetShift offsetShift() const
Returns direction of offset if any.
Definition channel.cc:116
Power
Specifies the prefix for every ID assigned to every channel during serialization.
Definition channel.hh:64
@ Low
Low power setting (e.g., 1W).
Definition channel.hh:68
@ Mid
Medium power setting (e.g., 2W, if available).
Definition channel.hh:67
@ High
High power setting (e.g, 5W).
Definition channel.hh:66
@ Max
Highest power setting (e.g. > 5W, if available).
Definition channel.hh:65
@ Min
Lowest power setting (e.g., <1W, if available).
Definition channel.hh:69
OffsetShift
Definition channel.hh:73
@ Positive
Positive offset between TX/RX frequencies.
Definition channel.hh:75
@ None
No Offset between TX/RX frequencies.
Definition channel.hh:74
@ Negative
Negative offset between TX/RX frequencies.
Definition channel.hh:76
TyTChannelExtension * tytChannelExtension() const
Returns the channel extension for TyT devices.
Definition channel.cc:277
void setTyTChannelExtension(TyTChannelExtension *ext)
Sets the TyT channel extension.
Definition channel.cc:281
void clear()
Clears the config object.
Definition channel.cc:61
bool voxDisabled() const
Returns true if the VOX is disabled.
Definition channel.cc:208
bool populate(YAML::Node &node, const Context &context, const ErrorStack &err=ErrorStack())
Recursively serializes the configuration to YAML nodes.
Definition channel.cc:294
TyTChannelExtension * _tytChannelExtension
Owns the TyT channel extension object.
Definition channel.hh:197
OpenGD77ChannelExtension * _openGD77ChannelExtension
Owns the OpenGD77 channel extension object.
Definition channel.hh:195
void setDefaultPower()
Sets the channel to use the default power setting.
Definition channel.cc:146
Interval _txTimeOut
Transmit timeout.
Definition channel.hh:187
bool copy(const ConfigItem &other)
Copies the given item into this one.
Definition channel.cc:45
void disableTimeout()
Disables the transmit timeout.
Definition channel.cc:191
bool _rxOnly
RX only flag.
Definition channel.hh:189
bool rxOnly
If true, the channel is receive only.
Definition channel.hh:49
bool timeoutDisabled() const
Returns true if the transmit timeout is disabled.
Definition channel.cc:161
void setVOX(Level level)
Sets the VOX level [0-10].
Definition channel.cc:220
Channel(QObject *parent=nullptr)
Hidden constructor.
Definition channel.cc:18
ScanListReference * scanListRef()
Returns the reference to the scan list.
bool setRXOnly(bool enable)
Set, whether the channel is RX only.
Definition channel.cc:201
bool defaultVOX() const
Returns true if the VOX is specified by the global default value.
Definition channel.cc:212
bool defaultPower() const
Returns true if the channel uses the global default power setting.
Definition channel.cc:127
Frequency rxFrequency
The receive frequency of the channel in Hz.
Definition channel.hh:41
OpenGD77ChannelExtension * openGD77ChannelExtension() const
Returns the channel extension for the OpenGD77 firmware.
Definition channel.cc:260
bool setTXFrequency(Frequency freq)
(Re-)Sets the TX frequency of the channel in Hz.
Definition channel.cc:99
Level vox
The VOX setting.
Definition channel.hh:53
bool parse(const YAML::Node &node, Context &ctx, const ErrorStack &err=ErrorStack())
Parses the given YAML node, updates the given object and updates the given context (IDs).
Definition channel.cc:310
void disableVOX()
Disables the VOX.
Definition channel.cc:231
void onReferenceModified()
Gets called whenever a referenced object is changed or deleted.
Definition channel.cc:255
Frequency _rxFreq
The RX frequency in Hz.
Definition channel.hh:178
void setOpenGD77ChannelExtension(OpenGD77ChannelExtension *ext)
Sets the OpenGD77 channel extension.
Definition channel.cc:264
bool setScanList(ScanList *list)
(Re-) Sets the default scan list for the channel.
Definition channel.cc:250
bool setTimeout(const Interval &dur)
(Re-)Sets the TX timeout (TOT) in seconds.
Definition channel.cc:171
Level _vox
Holds the VOX level.
Definition channel.hh:191
bool setRXFrequency(Frequency freq)
(Re-)Sets the RX frequency of the channel in Hz.
Definition channel.cc:83
void setVOXDefault()
Sets the VOX level to the default value.
Definition channel.cc:227
ScanListReference _scanlist
Default scan list of the channel.
Definition channel.hh:193
OpenGD77ChannelExtension * openGD77
The OpenGD77 channel extension.
Definition channel.hh:55
Frequency txFrequency
The transmit frequency of the channel in Hz.
Definition channel.hh:43
Power _power
The transmit power setting.
Definition channel.hh:184
Implements the generic extension for all channels configuring commercial features of DMR.
Definition commercial_extension.hh:35
Parse context for config objects.
Definition configobject.hh:43
Base class for all configuration objects (channels, zones, contacts, etc).
Definition configobject.hh:35
ConfigItem(QObject *parent=nullptr)
Hidden constructor.
Definition configobject.cc:158
ConfigObjectList(const QMetaObject &elementTypes=ConfigItem::staticMetaObject, QObject *parent=nullptr)
Hidden constructor.
Definition configobject.cc:1511
Base class of all labeled and named objects.
Definition configobject.hh:192
ConfigObject(QObject *parent=nullptr)
Specifies the prefix for every ID assigned to every object during serialization.
Definition configobject.cc:1141
The config class, representing the codeplug configuration.
Definition config.hh:70
Common DMR channel extended settings.
Definition channel_extension.hh:64
Extension to the DigitalChannel class to implement an DMR channel.
Definition channel.hh:402
DMRChannelExtension * extended
The extended dmr channel settings.
Definition channel.hh:423
ConfigItem * clone() const
Clones this item.
Definition channel.cc:682
CommercialChannelExtension * commercial
The commercial channel extension.
Definition channel.hh:425
void setAnytoneChannelExtension(AnytoneDMRChannelExtension *ext)
Sets the AnyTone DMR channel extension.
Definition channel.cc:870
TimeSlot
Possible timeslots for digital channels.
Definition channel.hh:439
@ TS2
Time/repeater slot 2.
Definition channel.hh:441
@ TS1
Time/repeater slot 1.
Definition channel.hh:440
const GroupListReference * groupListRef() const
Returns a reference to the group list.
Definition channel.cc:728
void setAdmit(Admit admit)
(Re-)Sets the admit criterion for the channel.
Definition channel.cc:696
bool setTimeSlot(TimeSlot ts)
(Re-)Sets the time slot for the channel.
Definition channel.cc:721
const RoamingZoneReference * roamingRef() const
Returns a reference to the roamingRef zone.
Definition channel.cc:797
const DMRContactReference * contactRef() const
Returns a reference to the transmit contactRef.
Definition channel.cc:751
bool setRadioId(DMRRadioID *id)
Associates the given radio ID with this channel.
Definition channel.cc:834
bool setContact(DMRContact *c)
(Re-) Sets the default TX contact for this channel.
Definition channel.cc:766
TimeSlot timeSlot
The time slot of the channel.
Definition channel.hh:410
bool setColorCode(unsigned cc)
(Re-)Sets the color code for the channel.
Definition channel.cc:706
PositioningSystemReference * aprs
The positioning system.
Definition channel.hh:418
unsigned _colorCode
The channel color code.
Definition channel.hh:533
AnytoneDMRChannelExtension * _anytoneExtension
Owns the AnyTone DMR channel extension.
Definition channel.hh:552
Admit
Possible admit criteria of digital channels.
Definition channel.hh:431
@ Always
No admit criteria, allows one to transmit any time.
Definition channel.hh:432
@ Free
Transmit only if channel is free.
Definition channel.hh:433
@ ColorCode
Transmit if channel is free or differs given color code.
Definition channel.hh:434
void setCommercialExtension(CommercialChannelExtension *ext)
Sets the commercial channel extension.
Definition channel.cc:853
AnytoneDMRChannelExtension * anytoneChannelExtension() const
Returns the DMR channel extension for AnyTone devices.
Definition channel.cc:866
DMRRadioIDReference _radioId
Radio ID to use on this channel.
Definition channel.hh:545
Admit _admit
The admit criterion.
Definition channel.hh:531
const DMRRadioIDReference * radioIdRef() const
Returns the reference to the radio ID.
Definition channel.cc:819
PositioningSystemReference _posSystem
The GPS system.
Definition channel.hh:541
DMRChannelExtension * _extended
Owns the extended channel extension.
Definition channel.hh:548
GroupListReference * groupList
The rx group list.
Definition channel.hh:414
RoamingZoneReference * roaming
The roaming zone.
Definition channel.hh:420
DMRContactReference * contact
The tx contact.
Definition channel.hh:416
unsigned colorCode
The color code of the channel.
Definition channel.hh:408
CommercialChannelExtension * commercialExtension() const
Returns the extension for commercial features.
Definition channel.cc:849
void clear()
Clears the config object.
Definition channel.cc:668
Admit admit
The admit criterion of the channel.
Definition channel.hh:406
TimeSlot _timeSlot
The time slot for the channel.
Definition channel.hh:535
GroupListReference _rxGroup
The RX group list for this channel.
Definition channel.hh:537
bool setAPRS(PositionReportingSystem *sys)
Associates the GPS System with this channel.
Definition channel.cc:789
bool setRoaming(RoamingZone *zone)
Associates the given roaming zone with this channel.
Definition channel.cc:812
CommercialChannelExtension * _commercialExtension
Owns the commercial channel extension.
Definition channel.hh:550
const PositioningSystemReference * aprsRef() const
Returns a reference to the positioning system.
Definition channel.cc:774
DMRContactReference _txContact
The default TX contact.
Definition channel.hh:539
Q_INVOKABLE DMRChannel(QObject *parent=nullptr)
Constructs a new empty digital (DMR) channel.
Definition channel.cc:642
RoamingZoneReference _roaming
Roaming zone for the channel.
Definition channel.hh:543
bool setGroupList(RXGroupList *rxg)
(Re-)Sets the RX group list for the channel.
Definition channel.cc:743
DMRRadioIDReference * radioId
The radio ID.
Definition channel.hh:412
AnytoneDMRChannelExtension * anytone
The AnyTone DMR channel extension.
Definition channel.hh:427
YAML::Node serialize(const Context &context, const ErrorStack &err=ErrorStack())
Recursively serializes the configuration to YAML nodes.
Definition channel.cc:883
Represents a reference to a DMR contact.
Definition configreference.hh:99
Represents a digital contact, that is a DMR number.
Definition contact.hh:141
Implements a reference to a radio ID.
Definition configreference.hh:251
Represents a DMR radio ID within the abstract config.
Definition radioid.hh:33
DigitalChannel(QObject *parent=nullptr)
Hidden constructor.
Definition channel.cc:626
Implements a stack of error messages to provide a pretty formatted error traceback.
Definition errorstack.hh:43
Implements a reference to an APRS system.
Definition configreference.hh:229
Represents an APRS system within the generic config.
Definition gpssystem.hh:136
Common FM channel extended settings.
Definition channel_extension.hh:37
Extension to the AnalogChannel class to implement an analog FM channel.
Definition channel.hh:249
FMChannelExtension * _extended
Owns the extended settings.
Definition channel.hh:346
Bandwidth bandwidth
The band width of the channel.
Definition channel.hh:259
AnytoneFMChannelExtension * anytoneChannelExtension() const
Returns the FM channel extension for AnyTone devices.
Definition channel.cc:515
AnytoneFMChannelExtension * anytone
The AnyTone FM channel extension.
Definition channel.hh:266
bool setBandwidth(Bandwidth bw)
(Re-)Sets the bandwidth of the analog channel.
Definition channel.cc:482
SelectiveCall txTone
The TX tone (CTCSS/DSC).
Definition channel.hh:257
Admit _admit
Holds the admit criterion.
Definition channel.hh:336
Admit admit
The admit criterion of the channel.
Definition channel.hh:253
SelectiveCall rxTone
The RX tone (CTCSS/DSC).
Definition channel.hh:255
Bandwidth _bw
The channel bandwidth.
Definition channel.hh:342
bool copy(const ConfigItem &other)
Copies the given item into this one.
Definition channel.cc:412
Admit
Admit criteria of analog channel.
Definition channel.hh:271
@ Always
Allow always.
Definition channel.hh:272
@ Free
Allow when channel free.
Definition channel.hh:273
@ Tone
Allow when free or wrong ctcss/dcs tone is present.
Definition channel.hh:274
void setAdmit(Admit admit)
(Re-)Sets the admit criterion for the analog channel.
Definition channel.cc:450
ConfigItem * clone() const
Clones this item.
Definition channel.cc:424
SelectiveCall _rxTone
The RX CTCSS/DCS setting.
Definition channel.hh:338
const FMAPRSSystemReference * aprsRef() const
Returns the reference to the APRS system.
Definition channel.cc:489
Q_INVOKABLE FMChannel(QObject *parent=nullptr)
Constructs a new empty analog channel.
Definition channel.cc:400
bool setTXTone(SelectiveCall code)
(Re-)Sets the CTCSS/DCS TX tone, SIGNALING_NONE disables the TX tone.
Definition channel.cc:471
bool parse(const YAML::Node &node, Context &ctx, const ErrorStack &err=ErrorStack())
Parses the given YAML node, updates the given object and updates the given context (IDs).
Definition channel.cc:543
SelectiveCall _txTone
The TX CTCSS/DCS setting.
Definition channel.hh:340
YAML::Node serialize(const Context &context, const ErrorStack &err=ErrorStack())
Recursively serializes the configuration to YAML nodes.
Definition channel.cc:532
void setAPRS(FMAPRSSystem *sys)
Sets the APRS system.
Definition channel.cc:503
AnytoneFMChannelExtension * _anytoneExtension
Owns the AnyTone FM channel extension.
Definition channel.hh:348
Bandwidth
Possible bandwidth of an analog channel.
Definition channel.hh:279
@ Narrow
Narrow bandwidth (12.5kHz).
Definition channel.hh:280
@ Wide
Wide bandwidth (25kHz).
Definition channel.hh:281
bool setRXTone(SelectiveCall code)
(Re-)Sets the CTCSS/DCS RX tone, SIGNALING_NONE disables the RX tone.
Definition channel.cc:460
FMChannelExtension * extended
Common extended channel settings.
Definition channel.hh:264
void clear()
Clears the config object.
Definition channel.cc:434
FMAPRSSystemReference _aprsSystem
A reference to the APRS system used on the channel or nullptr if disabled.
Definition channel.hh:344
void setAnytoneChannelExtension(AnytoneFMChannelExtension *ext)
Sets the AnyTone FM channel extension.
Definition channel.cc:519
FMAPRSSystemReference * aprs
The APRS system.
Definition channel.hh:261
Implements a reference to a group list.
Definition configreference.hh:262
Represents a time interval.
Definition interval.hh:11
Some simple class implementing a [1-10] level setting.
Definition level.hh:15
Implements the channel extensions for the OpenGD77 radios.
Definition opengd77_extension.hh:17
Base class of the position reporting systems, that is APRS and DMR position reporting system.
Definition gpssystem.hh:17
Implements a reference to a positioning system.
Definition configreference.hh:214
Generic representation of a RX group list.
Definition rxgrouplist.hh:14
Implements a reference to a roaming zone.
Definition configreference.hh:273
Represents a RoamingZone within the abstract device configuration.
Definition roamingzone.hh:15
Implements a reference to a scan list.
Definition configreference.hh:203
Generic representation of a scan list.
Definition scanlist.hh:15
static SelectedChannel * _instance
Holds the channel singleton instance.
Definition channel.hh:580
virtual ~SelectedChannel()
Destructor.
Definition channel.cc:905
ConfigItem * clone() const
Clones this item.
Definition channel.cc:915
bool copy(const ConfigItem &other)
Copies the given item into this one.
Definition channel.cc:910
static SelectedChannel * get()
Constructs/gets the singleton instance.
Definition channel.cc:920
SelectedChannel()
Constructs the "selected" channel.
Definition channel.cc:899
Represents the TyT channel extension.
Definition tyt_extensions.hh:15
Helper type to represent frequency differences aka offsets.
Definition frequency.hh:69
Helper type to encode frequencies without any rounding error.
Definition frequency.hh:107
Encodes a selective call.
Definition signaling.hh:13