Commit 6c6d79cb authored by Mariano Lizarraga's avatar Mariano Lizarraga

Minor changes. Looking for extreme processor overload on OSX

parent ab7869ce
......@@ -407,31 +407,22 @@ void MainWindow::buildSlugsWidgets()
// linechartWidget = new Linecharts(this);
// addToCentralWidgetsMenu(linechartWidget, "Line Plots", SLOT(showCentralWidget()), CENTRAL_LINECHART);
// Dock widgets
headUpDockWidget = new QDockWidget(tr("Control Indicator"), this);
headUpDockWidget->setWidget( new HUD(320, 240, this));
addToToolsMenu (headUpDockWidget, tr("HUD"), SLOT(showToolWidget()), MENU_HUD, Qt::LeftDockWidgetArea);
// // Dock widgets
// headUpDockWidget = new QDockWidget(tr("Control Indicator"), this);
// headUpDockWidget->setWidget( new HUD(320, 240, this));
// addToToolsMenu (headUpDockWidget, tr("HUD"), SLOT(showToolWidget()), MENU_HUD, Qt::LeftDockWidgetArea);
rcViewDockWidget = new QDockWidget(tr("Radio Control"), this);
rcViewDockWidget->setWidget( new QGCRemoteControlView(this) );
addToToolsMenu (rcViewDockWidget, tr("Radio Control"), SLOT(showToolWidget()), MENU_RC_VIEW, Qt::BottomDockWidgetArea);
// Dialog widgets
slugsDataWidget = new QDockWidget(tr("Slugs Data"), this);
slugsDataWidget->setWidget( new SlugsDataSensorView(this));
addToToolsMenu (slugsDataWidget, tr("Telemetry Data"), SLOT(showToolWidget()), MENU_SLUGS_DATA, Qt::RightDockWidgetArea);
// rcViewDockWidget = new QDockWidget(tr("Radio Control"), this);
// rcViewDockWidget->setWidget( new QGCRemoteControlView(this) );
// addToToolsMenu (rcViewDockWidget, tr("Radio Control"), SLOT(showToolWidget()), MENU_RC_VIEW, Qt::BottomDockWidgetArea);
//=======
// this->addDockWidget(Qt::LeftDockWidgetArea, headUpDockWidget);
// // SLUGS
// // Dialog widgets
// slugsDataWidget = new QDockWidget(tr("Slugs Data"), this);
// slugsDataWidget->setWidget( new SlugsDataSensorView(this));
// addDockWidget(Qt::LeftDockWidgetArea, slugsDataWidget);
// slugsDataWidget->hide();
//>>>>>>> master
// addToToolsMenu (slugsDataWidget, tr("Telemetry Data"), SLOT(showToolWidget()), MENU_SLUGS_DATA, Qt::RightDockWidgetArea);
slugsPIDControlWidget = new QDockWidget(tr("Slugs PID Control"), this);
slugsPIDControlWidget->setWidget(new SlugsPIDControl(this));
......@@ -440,15 +431,6 @@ void MainWindow::buildSlugsWidgets()
slugsHilSimWidget = new QDockWidget(tr("Slugs Hil Sim"), this);
slugsHilSimWidget->setWidget( new SlugsHilSim(this));
addToToolsMenu (slugsHilSimWidget, tr("HIL Sim Configuration"), SLOT(showToolWidget()), MENU_SLUGS_HIL, Qt::LeftDockWidgetArea);
//=======
// addDockWidget(Qt::BottomDockWidgetArea, slugsPIDControlWidget);
// slugsPIDControlWidget->hide();
// slugsHilSimWidget = new QDockWidget(tr("Slugs Hil Sim"), this);
// slugsHilSimWidget->setWidget( new SlugsHilSim(this));
// addDockWidget(Qt::BottomDockWidgetArea, slugsHilSimWidget);
// slugsHilSimWidget->hide();
//>>>>>>> master
slugsCamControlWidget = new QDockWidget(tr("Slugs Video Camera Control"), this);
slugsCamControlWidget->setWidget(new SlugsVideoCamControl(this));
......
......@@ -23,7 +23,7 @@ SlugsPIDControl::SlugsPIDControl(QWidget *parent) :
setGreenColorStyle();
refreshTimerGet = new QTimer(this);
refreshTimerGet->setInterval(100); // 20 Hz
refreshTimerGet->setInterval(100); // 10 Hz
connect(refreshTimerGet, SIGNAL(timeout()), this, SLOT(slugsGetGeneral()));
......@@ -47,9 +47,9 @@ SlugsPIDControl::SlugsPIDControl(QWidget *parent) :
void SlugsPIDControl::activeUasSet(UASInterface* uas)
{
#ifdef MAVLINK_ENABLED_SLUGS
SlugsMAV* slugsMav = dynamic_cast<SlugsMAV*>(uas);
SlugsMAV* slugsMav = qobject_cast<SlugsMAV*>(uas);
if (slugsMav != NULL)
if (slugsMav)
{
connect(slugsMav,SIGNAL(slugsActionAck(int,const mavlink_action_ack_t&)),this,SLOT(recibeMensaje(int,mavlink_action_ack_t)));
connect(slugsMav,SIGNAL(slugsPidValues(int,mavlink_pid_t)),this, SLOT(receivePidValues(int,mavlink_pid_t)) );
......@@ -58,15 +58,14 @@ void SlugsPIDControl::activeUasSet(UASInterface* uas)
connect(ui->getGeneral_pushButton,SIGNAL(clicked()),this,SLOT(slugsTimerStartGet()));
}
#endif // MAVLINK_ENABLED_SLUG
#endif // MAVLINK_ENABLED_SLUG
// Set this UAS as active if it is the first one
if(activeUAS == 0)
if(!activeUAS)
{
activeUAS = uas;
systemId = activeUAS->getUASID();
connect_editLinesPDIvalues();
//qDebug()<<"------------------->Active UAS ID: "<<uas->getUASID();
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment