diff --git a/src/uas/UAS.cc b/src/uas/UAS.cc index 19f31d74107e7d2064475e9028b7d1c2fedc1702..2509502badf3bbfef30d371d871ca818af0c2123 100644 --- a/src/uas/UAS.cc +++ b/src/uas/UAS.cc @@ -142,39 +142,6 @@ int UAS::getUASID() const void UAS::receiveMessage(mavlink_message_t message) { - if (!components.contains(message.compid)) - { - QString componentName; - - switch (message.compid) - { - case MAV_COMP_ID_ALL: - { - componentName = "ANONYMOUS"; - break; - } - case MAV_COMP_ID_IMU: - { - componentName = "IMU #1"; - break; - } - case MAV_COMP_ID_CAMERA: - { - componentName = "CAMERA"; - break; - } - case MAV_COMP_ID_MISSIONPLANNER: - { - componentName = "MISSIONPLANNER"; - break; - } - } - - components.insert(message.compid, componentName); - } - - // qDebug() << "UAS RECEIVED from" << message.sysid << "component" << message.compid << "msg id" << message.msgid << "seq no" << message.seq; - // Only accept messages from this system (condition 1) // and only then if a) attitudeStamped is disabled OR b) attitudeStamped is enabled // and we already got one attitude packet @@ -1466,14 +1433,6 @@ void UAS::stopHil() } #endif -/** -* @rerturn the map of the components -*/ -QMap UAS::getComponents() -{ - return components; -} - void UAS::sendMapRCToParam(QString param_id, float scale, float value0, quint8 param_rc_channel_index, float valueMin, float valueMax) { if (!_vehicle) { diff --git a/src/uas/UAS.h b/src/uas/UAS.h index 39d842e2c262f3735ad34250b95c1632b517d1b1..159fb1c44edf2ff1894f74e1ac3cbb20987166e6 100644 --- a/src/uas/UAS.h +++ b/src/uas/UAS.h @@ -52,8 +52,6 @@ public: /** @brief Get the unique system id */ int getUASID() const; - /** @brief Get the components */ - QMap getComponents(); /** @brief The time interval the robot is switched on */ quint64 getUptime() const; @@ -118,10 +116,9 @@ public: friend class FileManager; #endif -protected: //COMMENTS FOR TEST UNIT +protected: /// LINK ID AND STATUS int uasId; ///< Unique system ID - QMap components;///< IDs and names of all detected onboard components QList unknownPackets; ///< Packet IDs which are unknown and have been received MAVLinkProtocol* mavlink; ///< Reference to the MAVLink instance diff --git a/src/uas/UASInterface.h b/src/uas/UASInterface.h index f47b3355daa70a6929d44ae7e9f6eb677dd74258..c18b1485761ef51c3557a9422682bb6e0db0d793 100644 --- a/src/uas/UASInterface.h +++ b/src/uas/UASInterface.h @@ -48,8 +48,6 @@ public: virtual FileManager* getFileManager() = 0; #endif - virtual QMap getComponents() = 0; - enum StartCalibrationType { StartCalibrationRadio, StartCalibrationGyro, @@ -110,21 +108,6 @@ public slots: virtual void unsetRCToParameterMap() = 0; signals: - /** - * @brief Update the error count of a device - * - * The error count indicates how many errors occurred during the use of a device. - * Usually a random error from time to time is acceptable, e.g. through electromagnetic - * interferences on device lines like I2C and SPI. A constantly and rapidly increasing - * error count however can help to identify broken cables or misbehaving drivers. - * - * @param uasid System ID - * @param component Name of the component, e.g. "IMU" - * @param device Name of the device, e.g. "SPI0" or "I2C1" - * @param count Errors occurred since system startup - */ - void errCountChanged(int uasid, QString component, QString device, int count); - /** @brief The robot is connected **/ void connected(); /** @brief The robot is disconnected **/