Modificato il modo di colorare le label per nodi ROS

This commit is contained in:
2019-11-18 11:25:51 +01:00
parent 069fa97b40
commit 2f59630197
4 changed files with 20 additions and 20 deletions

View File

@@ -16,10 +16,10 @@ RoboGlue_SHARED::~RoboGlue_SHARED(){
void RoboGlue_SHARED::on_statusTimer(void){
double curTime = static_cast<double>(std::time(NULL));
commonStatus.relayTime = fabs(commonStatus.relayLast - curTime);
commonStatus.followerTime = fabs(commonStatus.followerLast - curTime);
commonStatus.recorderTime = fabs(commonStatus.recorderLast - curTime);
commonStatus.broadcasterTime = fabs(commonStatus.broadcasterLast - curTime);
commonStatus.relayRunning = (commonStatus.relayTime = fabs(commonStatus.relayLast - curTime)) < comSettings.deadTime;
commonStatus.followerRunning = (commonStatus.followerTime = fabs(commonStatus.followerLast - curTime)) < comSettings.deadTime;
commonStatus.recorderRunning = (commonStatus.recorderTime = fabs(commonStatus.recorderLast - curTime)) < comSettings.deadTime;
commonStatus.broadcasterRunning = (commonStatus.broadcasterTime = fabs(commonStatus.broadcasterLast - curTime)) < comSettings.deadTime;
emit this->commonStatusChange();
}
////////////////////////////////////////////////////////////////