diagnostics.hpp
Go to the documentation of this file.
00001 /*
00002  * Copyright 2016 SoftBank Robotics Europe
00003  *
00004  * Licensed under the Apache License, Version 2.0 (the "License");
00005  * you may not use this file except in compliance with the License.
00006  * You may obtain a copy of the License at
00007  *
00008  *     http://www.apache.org/licenses/LICENSE-2.0
00009  *
00010  * Unless required by applicable law or agreed to in writing, software
00011  * distributed under the License is distributed on an "AS IS" BASIS,
00012  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00013  * See the License for the specific language governing permissions and
00014  * limitations under the License.
00015  *
00016 */
00017 
00018 #ifndef DIAGNOSTICS_H
00019 #define DIAGNOSTICS_H
00020 
00021 // NAOqi Headers
00022 #include <qi/session.hpp>
00023 
00024 #include <diagnostic_updater/DiagnosticStatusWrapper.h>
00025 
00030 class Diagnostics
00031 {
00032 public:
00040   Diagnostics(const qi::SessionPtr& session,
00041               ros::Publisher *pub,
00042               const std::vector<std::string> &joints_all_names,
00043               const std::string &robot);
00044 
00046   virtual ~Diagnostics() {}
00047 
00049   bool publish();
00050 
00052   void setMessageFromStatus(diagnostic_updater::DiagnosticStatusWrapper &status);
00053 
00055   void setAggregatedMessage(diagnostic_updater::DiagnosticStatusWrapper &status);
00056 
00058   std::string getStatusMsg();
00059 
00060 private:
00062   ros::Publisher *pub_;
00063 
00065   qi::AnyObject memory_proxy_;
00066 
00068   std::vector <std::string> joints_all_names_;
00069 
00071   std::vector <float> joints_current_;
00072 
00075   std::vector <std::string> keys_tocheck_;
00076 
00078   float temperature_warn_level_;
00079 
00081   float temperature_error_level_;
00082 
00084   diagnostic_updater::DiagnosticStatusWrapper status_;
00085 };
00086 
00087 #endif // DIAGNOSTICS_H


naoqi_dcm_driver
Author(s): Konstantinos Chatzilygeroudis , Mikael Arguedas , Karsten Knese , Natalia Lyubova
autogenerated on Thu Jun 6 2019 20:50:49