diff --git a/dmr/Slot.h b/dmr/Slot.h index d0650a82..67d3f393 100644 --- a/dmr/Slot.h +++ b/dmr/Slot.h @@ -82,7 +82,7 @@ namespace dmr /// Updates the slot processor. void clock(); - /// + /// Gets instance of the ControlPacket class. ControlPacket* control() { return m_control; } /// Helper to change the debug and verbose state. @@ -202,9 +202,9 @@ namespace dmr /// Helper to write network end of frame data. void writeEndNet(bool writeEnd = false); - /// + /// Helper to set the DMR short LC. static void setShortLC(uint32_t slotNo, uint32_t id, uint8_t flco = FLCO_GROUP, bool voice = true); - /// + /// Helper to set the DMR short LC for TSCC. static void setShortLC_TSCC(SiteData siteData, uint16_t counter); }; } // namespace dmr diff --git a/dmr/SlotType.h b/dmr/SlotType.h index 77ed0ac6..e1e3f1cd 100644 --- a/dmr/SlotType.h +++ b/dmr/SlotType.h @@ -55,7 +55,7 @@ namespace dmr /// DMR access color code. __PROPERTY(uint8_t, colorCode, ColorCode); - /// + /// Slot data type. __PROPERTY(uint8_t, dataType, DataType); }; } // namespace dmr diff --git a/dmr/data/Data.cpp b/dmr/data/Data.cpp index 18ceef01..992e85a9 100644 --- a/dmr/data/Data.cpp +++ b/dmr/data/Data.cpp @@ -107,8 +107,10 @@ Data& Data::operator=(const Data& data) return *this; } -/// -/// +/// +/// Sets raw data. +/// +/// Data buffer. void Data::setData(const uint8_t* buffer) { assert(buffer != NULL); @@ -116,8 +118,10 @@ void Data::setData(const uint8_t* buffer) ::memcpy(m_data, buffer, DMR_FRAME_LENGTH_BYTES); } -/// -/// +/// +/// Gets raw data. +/// +/// Data buffer. uint32_t Data::getData(uint8_t* buffer) const { assert(buffer != NULL); diff --git a/dmr/data/Data.h b/dmr/data/Data.h index 2bec603f..aba4325a 100644 --- a/dmr/data/Data.h +++ b/dmr/data/Data.h @@ -49,9 +49,9 @@ namespace dmr /// Equals operator. Data& operator=(const Data& data); - /// + /// Sets raw data. void setData(const uint8_t* buffer); - /// + /// Gets raw data. uint32_t getData(uint8_t* buffer) const; public: @@ -72,13 +72,13 @@ namespace dmr /// Sequence number. __PROPERTY(uint8_t, seqNo, SeqNo); - /// + /// Embedded data type. __PROPERTY(uint8_t, dataType, DataType); - /// + /// Bit Error Rate. __PROPERTY(uint8_t, ber, BER); - /// + /// Received Signal Strength Indicator. __PROPERTY(uint8_t, rssi, RSSI); private: diff --git a/dmr/data/EmbeddedData.h b/dmr/data/EmbeddedData.h index 2ce13bdd..ab4d9197 100644 --- a/dmr/data/EmbeddedData.h +++ b/dmr/data/EmbeddedData.h @@ -63,7 +63,7 @@ namespace dmr /// Add LC data (which may consist of 4 blocks) to the data store. bool addData(const uint8_t* data, uint8_t lcss); - /// + /// Get LC data from the data store. uint8_t getData(uint8_t* data, uint8_t n) const; /// Sets link control data. @@ -71,7 +71,7 @@ namespace dmr /// Gets link control data. lc::LC* getLC() const; - /// + /// Get raw embeded data buffer. bool getRawData(uint8_t* data) const; /// Helper to reset data values to defaults. diff --git a/dmr/edac/Trellis.cpp b/dmr/edac/Trellis.cpp index c1631590..108cadda 100644 --- a/dmr/edac/Trellis.cpp +++ b/dmr/edac/Trellis.cpp @@ -72,9 +72,9 @@ Trellis::~Trellis() /// /// Decodes 3/4 rate Trellis. /// -/// -/// -/// +/// Trellis symbol bytes. +/// Output bytes. +/// True, if decoded, otherwise false. bool Trellis::decode(const uint8_t* data, uint8_t* payload) { assert(data != NULL); @@ -112,8 +112,8 @@ bool Trellis::decode(const uint8_t* data, uint8_t* payload) /// /// Encodes 3/4 rate Trellis. /// -/// -/// +/// Input bytes. +/// Trellis symbol bytes. void Trellis::encode(const uint8_t* payload, uint8_t* data) { assert(payload != NULL); @@ -143,10 +143,10 @@ void Trellis::encode(const uint8_t* payload, uint8_t* data) // Private Class Members // --------------------------------------------------------------------------- /// -/// +/// Helper to deinterleave the input symbols into dibits. /// -/// -/// +/// Trellis symbol bytes. +/// Dibits. void Trellis::deinterleave(const uint8_t* data, int8_t* dibits) const { for (uint32_t i = 0U; i < 98U; i++) { @@ -174,10 +174,10 @@ void Trellis::deinterleave(const uint8_t* data, int8_t* dibits) const } /// -/// +/// Helper to interleave the input dibits into symbols. /// -/// -/// +/// Dibits. +/// Trellis symbol bytes. void Trellis::interleave(const int8_t* dibits, uint8_t* data) const { for (uint32_t i = 0U; i < 98U; i++) { @@ -214,10 +214,10 @@ void Trellis::interleave(const int8_t* dibits, uint8_t* data) const } /// -/// +/// Helper to map dibits to 4FSK constellation points. /// -/// -/// +/// Dibits. +/// 4FSK constellation points. void Trellis::dibitsToPoints(const int8_t* dibits, uint8_t* points) const { for (uint32_t i = 0U; i < 49U; i++) { @@ -257,10 +257,10 @@ void Trellis::dibitsToPoints(const int8_t* dibits, uint8_t* points) const } /// -/// +/// Helper to map 4FSK constellation points to dibits. /// -/// -/// +/// 4FSK Constellation points. +/// Dibits. void Trellis::pointsToDibits(const uint8_t* points, int8_t* dibits) const { for (uint32_t i = 0U; i < 49U; i++) { @@ -334,10 +334,10 @@ void Trellis::pointsToDibits(const uint8_t* points, int8_t* dibits) const } /// -/// +/// Helper to convert a byte payload into tribits. /// -/// -/// +/// Byte payload. +/// Tribits. void Trellis::bitsToTribits(const uint8_t* payload, uint8_t* tribits) const { for (uint32_t i = 0U; i < 48U; i++) { @@ -361,10 +361,10 @@ void Trellis::bitsToTribits(const uint8_t* payload, uint8_t* tribits) const } /// -/// +/// Helper to convert tribits into a byte payload. /// -/// -/// +/// Tribits. +/// Byte payload. void Trellis::tribitsToBits(const uint8_t* tribits, uint8_t* payload) const { for (uint32_t i = 0U; i < 48U; i++) { @@ -385,12 +385,12 @@ void Trellis::tribitsToBits(const uint8_t* tribits, uint8_t* payload) const } /// -/// +/// Helper to fix errors in Trellis coding. /// -/// +/// 4FSK constellation points. /// -/// -/// +/// Byte payload. +/// True, if error corrected, otherwise false. bool Trellis::fixCode(uint8_t* points, uint32_t failPos, uint8_t* payload) const { for (unsigned j = 0U; j < 20U; j++) { @@ -421,10 +421,10 @@ bool Trellis::fixCode(uint8_t* points, uint32_t failPos, uint8_t* payload) const } /// -/// +/// Helper to detect errors in Trellis coding. /// -/// -/// +/// 4FSK constellation points. +/// Tribits. /// uint32_t Trellis::checkCode(const uint8_t* points, uint8_t* tribits) const { diff --git a/dmr/edac/Trellis.h b/dmr/edac/Trellis.h index 528bdb21..6a494834 100644 --- a/dmr/edac/Trellis.h +++ b/dmr/edac/Trellis.h @@ -49,22 +49,22 @@ namespace dmr void encode(const uint8_t* payload, uint8_t* data); private: - /// + /// Helper to deinterleave the input symbols into dibits. void deinterleave(const uint8_t* in, int8_t* dibits) const; - /// + /// Helper to interleave the input dibits into symbols. void interleave(const int8_t* dibits, uint8_t* out) const; - /// + /// Helper to map dibits to C4FM constellation points. void dibitsToPoints(const int8_t* dibits, uint8_t* points) const; - /// + /// Helper to map C4FM constellation points to dibits. void pointsToDibits(const uint8_t* points, int8_t* dibits) const; - /// + /// Helper to convert a byte payload into tribits. void bitsToTribits(const uint8_t* payload, uint8_t* tribits) const; - /// + /// Helper to convert tribits into a byte payload. void tribitsToBits(const uint8_t* tribits, uint8_t* payload) const; - /// + /// Helper to fix errors in Trellis coding. bool fixCode(uint8_t* points, uint32_t failPos, uint8_t* payload) const; - /// + /// Helper to detect errors in Trellis coding. uint32_t checkCode(const uint8_t* points, uint8_t* tribits) const; }; } // namespace edac diff --git a/dmr/lc/CSBK.cpp b/dmr/lc/CSBK.cpp index e2e47f9d..260e239e 100644 --- a/dmr/lc/CSBK.cpp +++ b/dmr/lc/CSBK.cpp @@ -455,22 +455,28 @@ void CSBK::reset() } /** Local Site data */ -/// Sets local configured site data. -/// +/// +/// Sets local configured site data. +/// +/// Site data. void CSBK::setSiteData(SiteData siteData) { m_siteData = siteData; } -/// -/// +/// +/// Sets the identity lookup table entry. +/// +/// Identity table entry. void CSBK::setIdenTable(lookups::IdenTable entry) { m_siteIdenEntry = entry; } -/// Sets a flag indicating whether or not networking is active. -/// +/// +/// Sets a flag indicating whether or not networking is active. +/// +/// Network active flag. void CSBK::setNetActive(bool netActive) { m_siteNetActive = netActive; diff --git a/dmr/lc/CSBK.h b/dmr/lc/CSBK.h index e6a63ea4..904029d1 100644 --- a/dmr/lc/CSBK.h +++ b/dmr/lc/CSBK.h @@ -63,13 +63,13 @@ namespace dmr /** Local Site data */ /// Sets local configured site data. void setSiteData(SiteData siteData); - /// + /// Sets the identity lookup table entry. void setIdenTable(lookups::IdenTable entry); /// Sets a flag indicating whether or not networking is active. void setNetActive(bool netActive); public: - /// + /// Flag indicating verbose log output. __PROPERTY(bool, verbose, Verbose); // Generic fields diff --git a/dmr/lc/LC.h b/dmr/lc/LC.h index 2dcbe5b6..61a24f15 100644 --- a/dmr/lc/LC.h +++ b/dmr/lc/LC.h @@ -55,14 +55,14 @@ namespace dmr /// Finalizes a instance of the LC class. ~LC(); - /// + /// Gets LC data as bytes. void getData(uint8_t* bytes) const; - /// + /// Gets LC data as bits. void getData(bool* bits) const; - /// + /// Gets the OVCM flag. bool getOVCM() const; - /// + /// Sets the OVCM flag. void setOVCM(bool ovcm); public: /// Flag indicating whether link protection is enabled. @@ -74,9 +74,9 @@ namespace dmr /// CSBK feature ID. __PROPERTY(uint8_t, FID, FID); - /// Sets the source ID. + /// Source ID. __PROPERTY(uint32_t, srcId, SrcId); - /// Sets the destination ID. + /// Destination ID. __PROPERTY(uint32_t, dstId, DstId); private: diff --git a/host/Host.h b/host/Host.h index 42c6b324..2f3fc9e0 100644 --- a/host/Host.h +++ b/host/Host.h @@ -135,19 +135,19 @@ private: /// Initializes network connectivity. bool createNetwork(); - /// + /// Modem port open callback. bool rmtPortModemOpen(modem::Modem* modem); - /// + /// Modem port close callback. bool rmtPortModemClose(modem::Modem* modem); - /// + /// Modem clock callback. bool rmtPortModemHandler(modem::Modem* modem, uint32_t ms, modem::RESP_TYPE_DVM rspType, bool rspDblLen, const uint8_t* buffer, uint16_t len); /// Helper to set the host/modem running state. void setState(uint8_t mode); - /// - void createLockFile(const char* mode) const; - /// + /// Helper to create the state lock file. + void createLockFile(const char* state) const; + /// Helper to remove the state lock file. void removeLockFile() const; }; diff --git a/host/calibrate/HostCal.cpp b/host/calibrate/HostCal.cpp index aa478a16..313ec7e9 100644 --- a/host/calibrate/HostCal.cpp +++ b/host/calibrate/HostCal.cpp @@ -1677,9 +1677,9 @@ bool HostCal::writeSymbolAdjust() } /// -/// +/// Helper to sleep the calibration thread. /// -/// +/// Milliseconds to sleep. void HostCal::sleep(uint32_t ms) { #if defined(_WIN32) || defined(_WIN64) @@ -1690,7 +1690,7 @@ void HostCal::sleep(uint32_t ms) } /// -/// +/// Helper to clock the calibration BER timer. /// void HostCal::timerClock() { @@ -1712,7 +1712,7 @@ void HostCal::timerClock() } /// -/// +/// Helper to start the calibration BER timer. /// void HostCal::timerStart() { @@ -1721,7 +1721,7 @@ void HostCal::timerStart() } /// -/// +/// Helper to stop the calibration BER timer. /// void HostCal::timerStop() { @@ -1759,15 +1759,15 @@ void HostCal::printStatus() } /// -/// +/// Counts the total number of bit errors between bytes. /// /// /// /// -unsigned char HostCal::countErrs(unsigned char a, unsigned char b) +uint8_t HostCal::countErrs(uint8_t a, uint8_t b) { int cnt = 0; - unsigned char tmp = a ^ b; + uint8_t tmp = a ^ b; while (tmp) { if (tmp % 2 == 1) cnt++; diff --git a/host/calibrate/HostCal.h b/host/calibrate/HostCal.h index d7f97135..1ce54215 100644 --- a/host/calibrate/HostCal.h +++ b/host/calibrate/HostCal.h @@ -107,11 +107,11 @@ private: uint32_t m_timeout; uint32_t m_timer; - /// + /// Modem port open callback. bool portModemOpen(modem::Modem* modem); - /// + /// Modem port close callback. bool portModemClose(modem::Modem* modem); - /// + /// Modem clock callback. bool portModemHandler(modem::Modem* modem, uint32_t ms, modem::RESP_TYPE_DVM rspType, bool rspDblLen, const uint8_t* buffer, uint16_t len); /// Helper to print the calibration help to the console. @@ -152,21 +152,21 @@ private: bool writeConfig(uint8_t modeOverride); /// Write symbol level adjustments to the modem DSP. bool writeSymbolAdjust(); - /// + /// Helper to sleep the calibration thread. void sleep(uint32_t ms); - /// + /// Helper to clock the calibration BER timer. void timerClock(); - /// + /// Helper to start the calibration BER timer. void timerStart(); - /// + /// Helper to stop the calibration BER timer. void timerStop(); /// Prints the current status of the calibration. void printStatus(); - /// - unsigned char countErrs(unsigned char a, unsigned char b); + /// Counts the total number of bit errors between bytes. + uint8_t countErrs(uint8_t a, uint8_t b); }; #endif // __HOST_CAL_H__ diff --git a/lookups/RadioIdLookup.h b/lookups/RadioIdLookup.h index 0fb54a2e..a2250346 100644 --- a/lookups/RadioIdLookup.h +++ b/lookups/RadioIdLookup.h @@ -76,9 +76,9 @@ namespace lookups return *this; } - /// - /// - /// + /// Sets flag values. + /// Radio enabled. + /// Radio default. void set(bool radioEnabled, bool radioDefault) { m_radioEnabled = radioEnabled; @@ -86,9 +86,9 @@ namespace lookups } public: - /// + /// Flag indicating if the radio is enabled. __READONLY_PROPERTY_PLAIN(bool, radioEnabled, radioEnabled); - /// + /// Flag indicating if the radio is default. __READONLY_PROPERTY_PLAIN(bool, radioDefault, radioDefault); }; diff --git a/lookups/TalkgroupIdLookup.h b/lookups/TalkgroupIdLookup.h index 3666ec25..9126e07b 100644 --- a/lookups/TalkgroupIdLookup.h +++ b/lookups/TalkgroupIdLookup.h @@ -80,10 +80,10 @@ namespace lookups return *this; } - /// - /// - /// - /// + /// Sets talkgroup values. + /// Talkgroup Enabled. + /// Talkgroup DMR slot. + /// Talkgroup Default. void set(bool tgEnabled, uint8_t tgSlot, bool tgDefault) { m_tgEnabled = tgEnabled; @@ -92,11 +92,11 @@ namespace lookups } public: - /// + /// Flag indicating if the talkgroup is enabled. __READONLY_PROPERTY_PLAIN(bool, tgEnabled, tgEnabled); - /// + /// Talkgroup DMR slot. __READONLY_PROPERTY_PLAIN(uint8_t, tgSlot, tgSlot); - /// + /// Flag indicating if the talkgroup is default. __READONLY_PROPERTY_PLAIN(bool, tgDefault, tgDefault); }; diff --git a/modem/Modem.cpp b/modem/Modem.cpp index 03f6012d..6332295b 100644 --- a/modem/Modem.cpp +++ b/modem/Modem.cpp @@ -409,8 +409,10 @@ void Modem::clock(uint32_t ms) close(); Thread::sleep(2000U); // 2s - while (!open()) + while (!open()) { Thread::sleep(5000U); // 5s + close(); + } } bool forceModemReset = false; @@ -1440,7 +1442,7 @@ bool Modem::writeSymbolAdjust() } /// -/// +/// Print debug air interface messages to the host log. /// /// /// @@ -1496,9 +1498,9 @@ void Modem::printDebug(const uint8_t* buffer, uint16_t len) } /// -/// +/// Helper to get the raw response packet from modem. /// -/// +/// Response type from modem. RESP_TYPE_DVM Modem::getResponse() { RESP_STATE state = RESP_START; diff --git a/modem/Modem.h b/modem/Modem.h index e28b36da..313ff4f7 100644 --- a/modem/Modem.h +++ b/modem/Modem.h @@ -361,10 +361,10 @@ namespace modem /// Write symbol level adjustments to the air interface modem. bool writeSymbolAdjust(); - /// + /// Print debug air interface messages to the host log. void printDebug(const uint8_t* buffer, uint16_t len); - /// + /// Helper to get the raw response packet from modem. RESP_TYPE_DVM getResponse(); public: @@ -373,7 +373,7 @@ namespace modem /// Flag indicating if modem debugging is enabled. __READONLY_PROPERTY(bool, debug, Debug); - /// + /// Modem packet playout timer. __READONLY_PROPERTY(Timer, playoutTimer, PlayoutTimer); }; } // namespace modem diff --git a/modem/port/ModemNullPort.h b/modem/port/ModemNullPort.h index 987b4254..85e14cbe 100644 --- a/modem/port/ModemNullPort.h +++ b/modem/port/ModemNullPort.h @@ -66,11 +66,11 @@ namespace modem private: RingBuffer m_buffer; - /// + /// Helper to return a faked modem version. void getVersion(); - /// + /// Helper to return a faked modem status. void getStatus(); - /// + /// Helper to write a faked modem acknowledge. void writeAck(uint8_t type); }; } // namespace port diff --git a/p25/Control.h b/p25/Control.h index e8d6e9fc..92b794d1 100644 --- a/p25/Control.h +++ b/p25/Control.h @@ -101,9 +101,9 @@ namespace p25 /// Updates the processor by the passed number of milliseconds. void clock(uint32_t ms); - /// + /// Gets instance of the NID class. NID nid() { return m_nid; } - /// + /// Gets instance of the TrunkPacket class. TrunkPacket* trunk() { return m_trunk; } /// Helper to change the debug and verbose state. diff --git a/p25/TrunkPacket.cpp b/p25/TrunkPacket.cpp index ac5f7f82..cf8f2fed 100644 --- a/p25/TrunkPacket.cpp +++ b/p25/TrunkPacket.cpp @@ -1082,7 +1082,7 @@ void TrunkPacket::clearGrpAff(uint32_t dstId, bool releaseAll) } /// -/// +/// Resets the state of the status commands. /// void TrunkPacket::resetStatusCommand() { diff --git a/p25/TrunkPacket.h b/p25/TrunkPacket.h index bbba38be..da904913 100644 --- a/p25/TrunkPacket.h +++ b/p25/TrunkPacket.h @@ -105,13 +105,13 @@ namespace p25 /// Helper to release group affiliations. void clearGrpAff(uint32_t dstId, bool releaseAll); - /// + /// Resets the state of the status commands. void resetStatusCommand(); /// Updates the processor by the passed number of milliseconds. void clock(uint32_t ms); - /// + /// Helper to set the TSBK manufacturer ID. void setMFId(uint8_t val) { m_rfTSBK.setMFId(val); } /// Helper to write a call alert packet. void writeRF_TSDU_Call_Alrt(uint32_t srcId, uint32_t dstId); diff --git a/p25/data/DataHeader.cpp b/p25/data/DataHeader.cpp index bc836c5f..8e8025fc 100644 --- a/p25/data/DataHeader.cpp +++ b/p25/data/DataHeader.cpp @@ -227,7 +227,7 @@ uint8_t DataHeader::getBlocksToFollow() const return m_blocksToFollow; } -/// +/// Sets the count of block padding. /// void DataHeader::setPadCount(uint8_t padCount) { @@ -242,7 +242,7 @@ void DataHeader::setPadCount(uint8_t padCount) } } -/// +/// Gets the count of block padding. /// uint8_t DataHeader::getPadCount() const { diff --git a/p25/data/DataHeader.h b/p25/data/DataHeader.h index 0bf445b8..a04b27d9 100644 --- a/p25/data/DataHeader.h +++ b/p25/data/DataHeader.h @@ -67,9 +67,9 @@ namespace p25 void setBlocksToFollow(uint8_t blocksToFollow); /// Gets the total number of blocks to follow this header. uint8_t getBlocksToFollow() const; - /// + /// Sets the count of block padding. void setPadCount(uint8_t padCount); - /// + /// Gets the count of block padding. uint8_t getPadCount() const; public: @@ -93,7 +93,7 @@ namespace p25 __PROPERTY(uint8_t, n, N); /// Data packet sequence number. __PROPERTY(uint8_t, seqNo, SeqNo); - /// + /// Offset of the header. __PROPERTY(uint8_t, headerOffset, HeaderOffset); private: diff --git a/p25/edac/Trellis.cpp b/p25/edac/Trellis.cpp index e69d7246..8434b329 100644 --- a/p25/edac/Trellis.cpp +++ b/p25/edac/Trellis.cpp @@ -78,9 +78,9 @@ Trellis::~Trellis() /// /// Decodes 3/4 rate Trellis. /// -/// -/// -/// +/// Trellis symbol bytes. +/// Output bytes. +/// True, if decoded, otherwise false. bool Trellis::decode34(const uint8_t* data, uint8_t* payload) { assert(data != NULL); @@ -118,9 +118,8 @@ bool Trellis::decode34(const uint8_t* data, uint8_t* payload) /// /// Encodes 3/4 rate Trellis. /// -/// -/// -/// +/// Input bytes. +/// Trellis symbol bytes. void Trellis::encode34(const uint8_t* payload, uint8_t* data) { assert(payload != NULL); @@ -149,9 +148,9 @@ void Trellis::encode34(const uint8_t* payload, uint8_t* data) /// /// Decodes 1/2 rate Trellis. /// -/// -/// -/// +/// Trellis symbol bytes. +/// Output bytes. +/// True, if decoded, otherwise false. bool Trellis::decode12(const uint8_t* data, uint8_t* payload) { assert(data != NULL); @@ -189,9 +188,8 @@ bool Trellis::decode12(const uint8_t* data, uint8_t* payload) /// /// Encodes 1/2 rate Trellis. /// -/// -/// -/// +/// Input bytes. +/// Trellis symbol bytes. void Trellis::encode12(const uint8_t* payload, uint8_t* data) { assert(payload != NULL); @@ -221,10 +219,10 @@ void Trellis::encode12(const uint8_t* payload, uint8_t* data) // Private Class Members // --------------------------------------------------------------------------- /// -/// +/// Helper to deinterleave the input symbols into dibits. /// -/// -/// +/// Trellis symbol bytes. +/// Dibits. void Trellis::deinterleave(const uint8_t* data, int8_t* dibits) const { for (uint32_t i = 0U; i < 98U; i++) { @@ -250,10 +248,10 @@ void Trellis::deinterleave(const uint8_t* data, int8_t* dibits) const } /// -/// +/// Helper to interleave the input dibits into symbols. /// -/// -/// +/// Dibits. +/// Trellis symbol bytes. void Trellis::interleave(const int8_t* dibits, uint8_t* data) const { for (uint32_t i = 0U; i < 98U; i++) { @@ -288,10 +286,10 @@ void Trellis::interleave(const int8_t* dibits, uint8_t* data) const } /// -/// +/// Helper to map dibits to 4FSK constellation points. /// -/// -/// +/// Dibits. +/// 4FSK constellation points. void Trellis::dibitsToPoints(const int8_t* dibits, uint8_t* points) const { for (uint32_t i = 0U; i < 49U; i++) { @@ -331,10 +329,10 @@ void Trellis::dibitsToPoints(const int8_t* dibits, uint8_t* points) const } /// -/// +/// Helper to map 4FSK constellation points to dibits. /// -/// -/// +/// 4FSK Constellation points. +/// Dibits. void Trellis::pointsToDibits(const uint8_t* points, int8_t* dibits) const { for (uint32_t i = 0U; i < 49U; i++) { @@ -408,10 +406,10 @@ void Trellis::pointsToDibits(const uint8_t* points, int8_t* dibits) const } /// -/// +/// Helper to convert a byte payload into tribits. /// -/// -/// +/// Byte payload. +/// Tribits. void Trellis::bitsToTribits(const uint8_t* payload, uint8_t* tribits) const { for (uint32_t i = 0U; i < 48U; i++) { @@ -435,10 +433,10 @@ void Trellis::bitsToTribits(const uint8_t* payload, uint8_t* tribits) const } /// -/// +/// Helper to convert a byte payload into dibits. /// -/// -/// +/// Byte payload. +/// Dibits. void Trellis::bitsToDibits(const uint8_t* payload, uint8_t* dibits) const { for (uint32_t i = 0U; i < 48U; i++) { @@ -459,10 +457,10 @@ void Trellis::bitsToDibits(const uint8_t* payload, uint8_t* dibits) const } /// -/// +/// Helper to convert tribits into a byte payload. /// -/// -/// +/// Tribits. +/// Byte payload. void Trellis::tribitsToBits(const uint8_t* tribits, uint8_t* payload) const { for (uint32_t i = 0U; i < 48U; i++) { @@ -483,10 +481,10 @@ void Trellis::tribitsToBits(const uint8_t* tribits, uint8_t* payload) const } /// -/// +/// Helper to convert tribits into a byte payload. /// -/// -/// +/// Dibits. +/// Byte payload. void Trellis::dibitsToBits(const uint8_t* dibits, uint8_t* payload) const { for (uint32_t i = 0U; i < 48U; i++) { @@ -504,12 +502,12 @@ void Trellis::dibitsToBits(const uint8_t* dibits, uint8_t* payload) const } /// -/// +/// Helper to fix errors in Trellis coding. /// -/// +/// 4FSK constellation points. /// -/// -/// +/// Byte payload. +/// True, if error corrected, otherwise false. bool Trellis::fixCode34(uint8_t* points, uint32_t failPos, uint8_t* payload) const { for (unsigned j = 0U; j < 20U; j++) { @@ -540,10 +538,10 @@ bool Trellis::fixCode34(uint8_t* points, uint32_t failPos, uint8_t* payload) con } /// -/// +/// Helper to detect errors in Trellis coding. /// -/// -/// +/// 4FSK constellation points. +/// Tribits. /// uint32_t Trellis::checkCode34(const uint8_t* points, uint8_t* tribits) const { @@ -573,12 +571,12 @@ uint32_t Trellis::checkCode34(const uint8_t* points, uint8_t* tribits) const /// -/// +/// Helper to fix errors in Trellis coding. /// -/// +/// 4FSK constellation points. /// -/// -/// +/// Byte payload. +/// True, if error corrected, otherwise false. bool Trellis::fixCode12(uint8_t* points, uint32_t failPos, uint8_t* payload) const { for (unsigned j = 0U; j < 20U; j++) { @@ -609,10 +607,10 @@ bool Trellis::fixCode12(uint8_t* points, uint32_t failPos, uint8_t* payload) con } /// -/// +/// Helper to detect errors in Trellis coding. /// -/// -/// +/// 4FSK constellation points. +/// Dibits. /// uint32_t Trellis::checkCode12(const uint8_t* points, uint8_t* dibits) const { diff --git a/p25/edac/Trellis.h b/p25/edac/Trellis.h index a55edf7d..aa952745 100644 --- a/p25/edac/Trellis.h +++ b/p25/edac/Trellis.h @@ -54,31 +54,31 @@ namespace p25 void encode12(const uint8_t* payload, uint8_t* data); private: - /// + /// Helper to deinterleave the input symbols into dibits. void deinterleave(const uint8_t* in, int8_t* dibits) const; - /// + /// Helper to interleave the input dibits into symbols. void interleave(const int8_t* dibits, uint8_t* out) const; - /// + /// Helper to map dibits to C4FM constellation points. void dibitsToPoints(const int8_t* dibits, uint8_t* points) const; - /// + /// Helper to map C4FM constellation points to dibits. void pointsToDibits(const uint8_t* points, int8_t* dibits) const; - /// + /// Helper to convert a byte payload into tribits. void bitsToTribits(const uint8_t* payload, uint8_t* tribits) const; - /// + /// Helper to convert a byte payload into dibits. void bitsToDibits(const uint8_t* payload, uint8_t* dibits) const; - /// + /// Helper to convert tribits into a byte payload. void tribitsToBits(const uint8_t* tribits, uint8_t* payload) const; - /// + /// Helper to convert dibits into a byte payload. void dibitsToBits(const uint8_t* dibits, uint8_t* payload) const; - /// + /// Helper to fix errors in Trellis coding. bool fixCode34(uint8_t* points, uint32_t failPos, uint8_t* payload) const; - /// + /// Helper to detect errors in Trellis coding. uint32_t checkCode34(const uint8_t* points, uint8_t* tribits) const; - /// + /// Helper to fix errors in Trellis coding. bool fixCode12(uint8_t* points, uint32_t failPos, uint8_t* payload) const; - /// + /// Helper to detect errors in Trellis coding. uint32_t checkCode12(const uint8_t* points, uint8_t* dibits) const; }; } // namespace edac diff --git a/p25/lc/TDULC.cpp b/p25/lc/TDULC.cpp index 43428f92..dd1a80de 100644 --- a/p25/lc/TDULC.cpp +++ b/p25/lc/TDULC.cpp @@ -181,22 +181,28 @@ void TDULC::reset() } /** Local Site data */ -/// Sets local configured site data. -/// +/// +/// Sets local configured site data. +/// +/// Site data. void TDULC::setSiteData(SiteData siteData) { m_siteData = siteData; } -/// -/// +/// +/// Sets the identity lookup table entry. +/// +/// Identity table entry. void TDULC::setIdenTable(lookups::IdenTable entry) { m_siteIdenEntry = entry; } -/// Sets a flag indicating whether or not networking is active. -/// +/// +/// Sets a flag indicating whether or not networking is active. +/// +/// Network active flag. void TDULC::setNetActive(bool netActive) { m_siteNetActive = netActive; diff --git a/p25/lc/TDULC.h b/p25/lc/TDULC.h index f01acd77..04dcaffa 100644 --- a/p25/lc/TDULC.h +++ b/p25/lc/TDULC.h @@ -74,13 +74,13 @@ namespace p25 /** Local Site data */ /// Sets local configured site data. void setSiteData(SiteData siteData); - /// + /// Sets the identity lookup table entry. void setIdenTable(lookups::IdenTable entry); /// Sets a flag indicating whether or not networking is active. void setNetActive(bool netActive); public: - /// + /// Flag indicating verbose log output. __PROPERTY(bool, verbose, Verbose); /** Common Data */ diff --git a/p25/lc/TSBK.cpp b/p25/lc/TSBK.cpp index ca2679c1..97f1ef95 100644 --- a/p25/lc/TSBK.cpp +++ b/p25/lc/TSBK.cpp @@ -805,23 +805,29 @@ void TSBK::reset() m_group = true; } -/// -/// +/// +/// Sets the flag to skip vendor opcode processing. +/// +/// Flag indicating to skip vendor opcode processing. void TSBK::setVendorSkip(bool skip) { m_vendorSkip = skip; } /** Local Site data */ -/// Sets local configured site data. -/// +/// +/// Sets local configured site data. +/// +/// Site data. void TSBK::setSiteData(SiteData siteData) { m_siteData = siteData; } -/// Sets local configured site callsign. -/// +/// +/// Sets local configured site callsign. +/// +/// Callsign. void TSBK::setCallsign(std::string callsign) { uint32_t idLength = callsign.length(); @@ -835,22 +841,28 @@ void TSBK::setCallsign(std::string callsign) } } -/// -/// +/// +/// Sets the identity lookup table entry. +/// +/// Identity table entry. void TSBK::setIdenTable(lookups::IdenTable entry) { m_siteIdenEntry = entry; } -/// Sets a flag indicating whether or not networking is active. -/// +/// +/// Sets a flag indicating whether or not networking is active. +/// +/// Network active flag. void TSBK::setNetActive(bool netActive) { m_siteNetActive = netActive; } -/// Sets the total number of channels at the site. -/// +/// +/// Sets the total number of channels at the site. +/// +/// Channel count. void TSBK::setSiteChCnt(uint8_t chCnt) { m_siteChCnt = chCnt; diff --git a/p25/lc/TSBK.h b/p25/lc/TSBK.h index 86920cf8..785efd27 100644 --- a/p25/lc/TSBK.h +++ b/p25/lc/TSBK.h @@ -71,7 +71,7 @@ namespace p25 /// Helper to reset data values to defaults. void reset(); - /// + /// Sets the flag to skip vendor opcode processing. void setVendorSkip(bool skip); /** Local Site data */ @@ -79,7 +79,7 @@ namespace p25 void setSiteData(SiteData siteData); /// Sets local configured site callsign. void setCallsign(std::string callsign); - /// + /// Sets the identity lookup table entry. void setIdenTable(lookups::IdenTable entry); /// Sets a flag indicating whether or not networking is active. void setNetActive(bool netActive); @@ -87,7 +87,7 @@ namespace p25 void setSiteChCnt(uint8_t chCnt); public: - /// + /// Flag indicating verbose log output. __PROPERTY(bool, verbose, Verbose); /** Common Data */