22 changed files with 1620 additions and 166 deletions
@ -0,0 +1,76 @@
@@ -0,0 +1,76 @@
|
||||
<ParameterList version="0.1"> |
||||
|
||||
<!-- Parameters in the top level block --> |
||||
<Block name="TopLevel"> |
||||
<Parameter> |
||||
|
||||
</Parameter> |
||||
</Block> |
||||
|
||||
<!--Parameters related to the navigation block --> |
||||
<Block name="Navigation"> |
||||
<Parameter |
||||
SimulinkPath="avionics_src/sm_avionics/Navigation_Filter/NAV_FILT_INIT/" |
||||
SimulinkParameterName="Value" |
||||
QGCParamID="NAV_FILT_INIT" |
||||
/> |
||||
</Block> |
||||
|
||||
<!--Parameters related to the controller block --> |
||||
<Block name="Controller"> |
||||
|
||||
</Block> |
||||
|
||||
<!-- Paremters for the Pilot Input/Raw RC block --> |
||||
<Block name="ServoInputs"> |
||||
|
||||
</Block> |
||||
|
||||
<!-- Parameters for the servo output block --> |
||||
<Block name="ServoOutputs"> |
||||
|
||||
<!-- Settings for Aileron Servo --> |
||||
<Parameter |
||||
SimulinkPath="avionics_src/sm_avionics/Servo_Outputs/AileronOutput/" |
||||
SimulinkParameterName="Low" |
||||
QGCParamID="AIL_LOW_OUT" |
||||
/> |
||||
<Parameter |
||||
SimulinkPath="avionics_src/sm_avionics/Servo_Outputs/AileronOutput/" |
||||
SimulinkParameterName="Center" |
||||
QGCParamID="AIL_CENTER_OUT" |
||||
/> |
||||
<Parameter |
||||
SimulinkPath="avionics_src/sm_avionics/Servo_Outputs/AileronOutput/" |
||||
SimulinkParameterName="High" |
||||
QGCParamID="AIL_HIGH_OUT" |
||||
/> |
||||
<Parameter |
||||
SimulinkPath="avionics_src/sm_avionics/Servo_Outputs/AileronOutput/" |
||||
SimulinkParameterName="Reverse" |
||||
QGCParamID="AIL_REV_OUT" |
||||
/> |
||||
|
||||
<!-- Settings for Elevator Servo --> |
||||
<Parameter |
||||
SimulinkPath="avionics_src/sm_avionics/Servo_Outputs/ElevatorOutput/" |
||||
SimulinkParameterName="Low" |
||||
QGCParamID="ELE_LOW_OUT" |
||||
/> |
||||
<Parameter |
||||
SimulinkPath="avionics_src/sm_avionics/Servo_Outputs/ElevatorOutput/" |
||||
SimulinkParameterName="Center" |
||||
QGCParamID="ELE_CENTER_OUT" |
||||
/> |
||||
<Parameter |
||||
SimulinkPath="avionics_src/sm_avionics/Servo_Outputs/ElevatorOutput/" |
||||
SimulinkParameterName="High" |
||||
QGCParamID="ELE_HIGH_OUT" |
||||
/> |
||||
<Parameter |
||||
SimulinkPath="avionics_src/sm_avionics/Servo_Outputs/ElevatorOutput/" |
||||
SimulinkParameterName="Reverse" |
||||
QGCParamID="ELE_REV_OUT" |
||||
/> |
||||
</Block> |
||||
</ParameterList> |
@ -0,0 +1,26 @@
@@ -0,0 +1,26 @@
|
||||
#include "OpalRT.h" |
||||
|
||||
namespace OpalRT |
||||
{ |
||||
// lastErrorMsg = QString();
|
||||
void OpalErrorMsg::displayLastErrorMsg() |
||||
{ |
||||
static QString lastErrorMsg; |
||||
setLastErrorMsg(); |
||||
QMessageBox msgBox; |
||||
msgBox.setIcon(QMessageBox::Critical); |
||||
msgBox.setText(lastErrorMsg); |
||||
msgBox.exec(); |
||||
} |
||||
|
||||
void OpalErrorMsg::setLastErrorMsg() |
||||
{ |
||||
char* buf = new char[512]; |
||||
unsigned short len; |
||||
static QString lastErrorMsg; |
||||
OpalGetLastErrMsg(buf, sizeof(buf), &len); |
||||
lastErrorMsg.clear(); |
||||
lastErrorMsg.append(buf); |
||||
delete buf; |
||||
} |
||||
} |
@ -0,0 +1,130 @@
@@ -0,0 +1,130 @@
|
||||
/*=====================================================================
|
||||
|
||||
QGroundControl Open Source Ground Control Station |
||||
|
||||
(c) 2009, 2010 QGROUNDCONTROL PROJECT <http://www.qgroundcontrol.org>
|
||||
|
||||
This file is part of the QGROUNDCONTROL project |
||||
|
||||
QGROUNDCONTROL is free software: you can redistribute it and/or modify |
||||
it under the terms of the GNU General Public License as published by |
||||
the Free Software Foundation, either version 3 of the License, or |
||||
(at your option) any later version. |
||||
|
||||
QGROUNDCONTROL is distributed in the hope that it will be useful, |
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of |
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
||||
GNU General Public License for more details. |
||||
|
||||
You should have received a copy of the GNU General Public License |
||||
along with QGROUNDCONTROL. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
======================================================================*/ |
||||
|
||||
/**
|
||||
* @file |
||||
* @brief Types used for Opal-RT interface configuration |
||||
* @author Bryan Godbolt <godbolt@ualberta.ca> |
||||
*/ |
||||
|
||||
#ifndef OPALRT_H |
||||
#define OPALRT_H |
||||
|
||||
#include <QString> |
||||
#include <QMessageBox> |
||||
|
||||
#include "OpalApi.h" |
||||
|
||||
namespace OpalRT |
||||
{ |
||||
/**
|
||||
Configuration info for the model |
||||
*/ |
||||
|
||||
const unsigned short NUM_OUTPUT_SIGNALS=57; |
||||
|
||||
/* ------------------------------ Outputs ------------------------------
|
||||
* |
||||
* Port 1: Navigation state estimates |
||||
* 1 t [s] time elapsed since INS mode started |
||||
* 2-4 p^n [m] navigation frame position (N,E,D) |
||||
* 5-7 v^n [m/s] navigation frame velocity (N,E,D) |
||||
* 8-10 Euler angles [rad] (roll, pitch, yaw) |
||||
* 11-13 Angular rates |
||||
* 14-16 b_f [m/s^2] accelerometer biases |
||||
* 17-19 b_w [rad/s] gyro biases |
||||
* |
||||
* Port 2: Navigation system status |
||||
* 1 mode (0: initialization, 1: INS) |
||||
* 2 t_GPS time elapsed since last valid GPS measurement |
||||
* 3 solution status (0: SOL_COMPUTED, 1: INSUFFICIENT_OBS) |
||||
* 4 position solution type ( 0: NONE, 34: NARROW_FLOAT, |
||||
* 49: WIDE_INT, 50: NARROW_INT) |
||||
* 5 # obs (number of visible satellites) |
||||
* |
||||
* Port 3: Covariance matrix diagonal |
||||
* 1-15 diagonal elements of estimation error covariance matrix P |
||||
*/ |
||||
enum SignalPort |
||||
{ |
||||
T_ELAPSED, |
||||
X_POS, |
||||
Y_POS, |
||||
Z_POS, |
||||
X_VEL, |
||||
Y_VEL, |
||||
Z_VEL, |
||||
ROLL, |
||||
PITCH, |
||||
YAW, |
||||
ROLL_SPEED, |
||||
PITCH_SPEED, |
||||
YAW_SPEED, |
||||
B_F_0, |
||||
B_F_1, |
||||
B_F_2, |
||||
B_W_0, |
||||
B_W_1, |
||||
B_W_2, |
||||
RAW_CHANNEL_1 = 39, |
||||
RAW_CHANNEL_2, |
||||
RAW_CHANNEL_3, |
||||
RAW_CHANNEL_4, |
||||
RAW_CHANNEL_5, |
||||
RAW_CHANNEL_6, |
||||
RAW_CHANNEL_7, |
||||
RAW_CHANNEL_8, |
||||
NORM_CHANNEL_1, |
||||
NORM_CHANNEL_2, |
||||
NORM_CHANNEL_3, |
||||
NORM_CHANNEL_4, |
||||
NORM_CHANNEL_5, |
||||
NORM_CHANNEL_6, |
||||
NORM_CHANNEL_7, |
||||
NORM_CHANNEL_8, |
||||
CONTROLLER_AILERON, |
||||
CONTROLLER_ELEVATOR |
||||
};
|
||||
|
||||
/** Component IDs of the parameters. Currently they are all 1 becuase there is no advantage
|
||||
to dividing them between component ids. However this syntax is used so that this can |
||||
easily be changed in the future. |
||||
*/ |
||||
enum SubsystemIds |
||||
{ |
||||
NAV_ID = 1, |
||||
LOG_ID, |
||||
CONTROLLER_ID, |
||||
SERVO_OUTPUTS, |
||||
SERVO_INPUTS |
||||
}; |
||||
|
||||
class OpalErrorMsg |
||||
{ |
||||
static QString lastErrorMsg; |
||||
public: |
||||
static void displayLastErrorMsg(); |
||||
static void setLastErrorMsg(); |
||||
}; |
||||
} |
||||
#endif // OPALRT_H
|
@ -0,0 +1,120 @@
@@ -0,0 +1,120 @@
|
||||
/*=====================================================================
|
||||
|
||||
QGroundControl Open Source Ground Control Station |
||||
|
||||
(c) 2009, 2010 QGROUNDCONTROL PROJECT <http://www.qgroundcontrol.org>
|
||||
|
||||
This file is part of the QGROUNDCONTROL project |
||||
|
||||
QGROUNDCONTROL is free software: you can redistribute it and/or modify |
||||
it under the terms of the GNU General Public License as published by |
||||
the Free Software Foundation, either version 3 of the License, or |
||||
(at your option) any later version. |
||||
|
||||
QGROUNDCONTROL is distributed in the hope that it will be useful, |
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of |
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
||||
GNU General Public License for more details. |
||||
|
||||
You should have received a copy of the GNU General Public License |
||||
along with QGROUNDCONTROL. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
======================================================================*/ |
||||
|
||||
/**
|
||||
* @file |
||||
* @brief Implementation of class OpalRT::Parameter |
||||
* @author Bryan Godbolt <godbolt@ualberta.ca> |
||||
*/ |
||||
#include "Parameter.h" |
||||
using namespace OpalRT; |
||||
|
||||
//Parameter::Parameter(char *simulinkPath, char *simulinkName, uint8_t componentID,
|
||||
// QGCParamID paramID, unsigned short opalID)
|
||||
// : simulinkPath(new QString(simulinkPath)),
|
||||
// simulinkName(new QString(simulinkName)),
|
||||
// componentID(componentID),
|
||||
// paramID(new QGCParamID(paramID)),
|
||||
// opalID(opalID)
|
||||
//
|
||||
//{
|
||||
//}
|
||||
Parameter::Parameter(QString simulinkPath, QString simulinkName, uint8_t componentID, |
||||
QGCParamID paramID, unsigned short opalID) |
||||
: simulinkPath(new QString(simulinkPath)), |
||||
simulinkName(new QString(simulinkName)), |
||||
componentID(componentID), |
||||
paramID(new QGCParamID(paramID)), |
||||
opalID(opalID) |
||||
|
||||
{ |
||||
} |
||||
Parameter::Parameter(const Parameter &other) |
||||
: componentID(other.componentID), |
||||
opalID(other.opalID) |
||||
{ |
||||
simulinkPath = new QString(*other.simulinkPath); |
||||
simulinkName = new QString(*other.simulinkName); |
||||
paramID = new QGCParamID(*other.paramID); |
||||
} |
||||
|
||||
Parameter::~Parameter() |
||||
{ |
||||
delete simulinkPath; |
||||
delete simulinkName; |
||||
delete paramID; |
||||
} |
||||
|
||||
bool Parameter::operator ==(const Parameter& other) const |
||||
{ |
||||
return |
||||
(*simulinkPath) == *(other.simulinkPath) |
||||
&& *simulinkName == *(other.simulinkName) |
||||
&& componentID == other.componentID |
||||
&& *paramID == *(other.paramID) |
||||
&& opalID == other.opalID; |
||||
|
||||
} |
||||
|
||||
float Parameter::getValue() |
||||
{ |
||||
unsigned short allocatedParams = 1; |
||||
unsigned short numParams; |
||||
unsigned short numValues = 1; |
||||
unsigned short returnedNumValues; |
||||
double value; |
||||
|
||||
int returnVal = OpalGetParameters(allocatedParams, &numParams, &opalID, |
||||
numValues, &returnedNumValues, &value); |
||||
|
||||
if (returnVal != EOK) |
||||
{ |
||||
OpalRT::OpalErrorMsg::displayLastErrorMsg(); |
||||
return FLT_MAX; |
||||
} |
||||
|
||||
return static_cast<float>(value); |
||||
} |
||||
|
||||
void Parameter::setValue(float val) |
||||
{ |
||||
unsigned short allocatedParams = 1; |
||||
unsigned short numParams; |
||||
unsigned short numValues = 1; |
||||
unsigned short returnedNumValues; |
||||
double value = static_cast<double>(val); |
||||
|
||||
int returnVal = OpalSetParameters(allocatedParams, &numParams, &opalID, |
||||
numValues, &returnedNumValues, &value); |
||||
if (returnVal != EOK) |
||||
{ |
||||
//qDebug() << __FILE__ << ":" << __LINE__ << ": Error numer: " << QString::number(returnVal);
|
||||
OpalErrorMsg::displayLastErrorMsg(); |
||||
} |
||||
} |
||||
|
||||
Parameter::operator QString() const |
||||
{ |
||||
return *simulinkPath + *simulinkName + " " + QString::number(componentID) |
||||
+ " " + *paramID + " " + QString::number(opalID); |
||||
} |
@ -0,0 +1,82 @@
@@ -0,0 +1,82 @@
|
||||
/*=====================================================================
|
||||
|
||||
QGroundControl Open Source Ground Control Station |
||||
|
||||
(c) 2009, 2010 QGROUNDCONTROL PROJECT <http://www.qgroundcontrol.org>
|
||||
|
||||
This file is part of the QGROUNDCONTROL project |
||||
|
||||
QGROUNDCONTROL is free software: you can redistribute it and/or modify |
||||
it under the terms of the GNU General Public License as published by |
||||
the Free Software Foundation, either version 3 of the License, or |
||||
(at your option) any later version. |
||||
|
||||
QGROUNDCONTROL is distributed in the hope that it will be useful, |
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of |
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
||||
GNU General Public License for more details. |
||||
|
||||
You should have received a copy of the GNU General Public License |
||||
along with QGROUNDCONTROL. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
======================================================================*/ |
||||
|
||||
/**
|
||||
* @file |
||||
* @brief Parameter Object used to intefrace with an OpalRT Simulink Parameter |
||||
\see OpalLink |
||||
\see OpalRT::ParameterList |
||||
* @author Bryan Godbolt <godbolt@ualberta.ca> |
||||
*/ |
||||
|
||||
#ifndef PARAMETER_H |
||||
#define PARAMETER_H |
||||
|
||||
#include <QString> |
||||
#include <QDebug> |
||||
|
||||
#include "mavlink_types.h" |
||||
#include "QGCParamID.h" |
||||
#include "OpalApi.h" |
||||
#include "OpalRT.h" |
||||
#include <cfloat> |
||||
|
||||
namespace OpalRT |
||||
{ |
||||
class Parameter |
||||
{ |
||||
public: |
||||
// Parameter(char *simulinkPath = "",
|
||||
// char *simulinkName = "",
|
||||
// uint8_t componentID = 0,
|
||||
// QGCParamID paramID = QGCParamID(),
|
||||
// unsigned short opalID = 0);
|
||||
Parameter(QString simulinkPath = QString(), |
||||
QString simulinkName = QString(), |
||||
uint8_t componentID = 0, |
||||
QGCParamID paramID = QGCParamID(), |
||||
unsigned short opalID = 0); |
||||
Parameter(const Parameter& other); |
||||
~Parameter(); |
||||
|
||||
const QGCParamID& getParamID() const {return *paramID;} |
||||
void setOpalID(unsigned short opalID) {this->opalID = opalID;} |
||||
const QString& getSimulinkPath() {return *simulinkPath;} |
||||
const QString& getSimulinkName() {return *simulinkName;} |
||||
uint8_t getComponentID() const {return componentID;} |
||||
float getValue(); |
||||
void setValue(float value); |
||||
|
||||
bool operator==(const Parameter& other) const; |
||||
operator QString() const; |
||||
|
||||
protected: |
||||
QString *simulinkPath; |
||||
QString *simulinkName; |
||||
uint8_t componentID; |
||||
QGCParamID *paramID; |
||||
unsigned short opalID; |
||||
}; |
||||
} |
||||
|
||||
#endif // PARAMETER_H
|
@ -0,0 +1,347 @@
@@ -0,0 +1,347 @@
|
||||
/*=====================================================================
|
||||
|
||||
QGroundControl Open Source Ground Control Station |
||||
|
||||
(c) 2009, 2010 QGROUNDCONTROL PROJECT <http://www.qgroundcontrol.org>
|
||||
|
||||
This file is part of the QGROUNDCONTROL project |
||||
|
||||
QGROUNDCONTROL is free software: you can redistribute it and/or modify |
||||
it under the terms of the GNU General Public License as published by |
||||
the Free Software Foundation, either version 3 of the License, or |
||||
(at your option) any later version. |
||||
|
||||
QGROUNDCONTROL is distributed in the hope that it will be useful, |
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of |
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
||||
GNU General Public License for more details. |
||||
|
||||
You should have received a copy of the GNU General Public License |
||||
along with QGROUNDCONTROL. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
======================================================================*/ |
||||
|
||||
/**
|
||||
* @file |
||||
* @brief Implementation of class OpalRT::ParameterList |
||||
* @author Bryan Godbolt <godbolt@ualberta.ca> |
||||
*/ |
||||
|
||||
#include "ParameterList.h" |
||||
using namespace OpalRT; |
||||
|
||||
ParameterList::ParameterList() |
||||
:params(new QMap<int, QMap<QGCParamID, Parameter> >), |
||||
paramList(new QList<QList<Parameter*> >()) |
||||
{ |
||||
|
||||
QDir settingsDir = QDir(qApp->applicationDirPath()); |
||||
if (settingsDir.dirName() == "bin") |
||||
settingsDir.cdUp(); |
||||
settingsDir.cd("settings"); |
||||
|
||||
QString filename(settingsDir.path() + "/ParameterList.xml"); |
||||
if ((QFile::exists(filename)) && open(filename)) |
||||
{ |
||||
/* Populate the map with parameter names. There is no elegant way of doing this so all
|
||||
parameter paths and names must be known at compile time and defined here. |
||||
Note: This function is written in a way that calls a lot of copy constructors and is |
||||
therefore not particularly efficient. However since it is only called once memory |
||||
and computation time are sacrificed for code clarity when adding and modifying |
||||
parameters. |
||||
When defining the path, the trailing slash is necessary |
||||
*/ |
||||
// Parameter *p;
|
||||
// /* Component: Navigation Filter */
|
||||
// p = new Parameter("avionics_src/sm_ampro/NAV_FILT_INIT/",
|
||||
// "Value",
|
||||
// OpalRT::NAV_ID,
|
||||
// QGCParamID("NAV_FILT_INIT"));
|
||||
// (*params)[OpalRT::NAV_ID].insert(p->getParamID(), *p);
|
||||
// delete p;
|
||||
//
|
||||
// p = new Parameter("avionics_src/sm_ampro/Gain/",
|
||||
// "Gain",
|
||||
// OpalRT::NAV_ID,
|
||||
// QGCParamID("TEST_OUTP_GAIN"));
|
||||
// (*params)[OpalRT::NAV_ID].insert(p->getParamID(), *p);
|
||||
// delete p;
|
||||
//
|
||||
// /* Component: Log Facility */
|
||||
// p = new Parameter("avionics_src/sm_ampro/LOG_FILE_ON/",
|
||||
// "Value",
|
||||
// OpalRT::LOG_ID,
|
||||
// QGCParamID("LOG_FILE_ON"));
|
||||
// (*params)[OpalRT::LOG_ID].insert(p->getParamID(), *p);
|
||||
// delete p;
|
||||
|
||||
/* Get a list of the available parameters from opal-rt */ |
||||
QMap<QString, unsigned short> *opalParams = new QMap<QString, unsigned short>; |
||||
getParameterList(opalParams); |
||||
|
||||
/* Iterate over the parameters we want to use in qgc and populate their ids */ |
||||
QMap<int, QMap<QGCParamID, Parameter> >::iterator componentIter; |
||||
QMap<QGCParamID, Parameter>::iterator paramIter; |
||||
QString s; |
||||
for (componentIter = params->begin(); componentIter != params->end(); ++componentIter) |
||||
{ |
||||
paramList->append(QList<Parameter*>()); |
||||
for (paramIter = (*componentIter).begin(); paramIter != (*componentIter).end(); ++paramIter) |
||||
{ |
||||
paramList->last().append(paramIter.operator ->()); |
||||
s = (*paramIter).getSimulinkPath() + (*paramIter).getSimulinkName(); |
||||
if (opalParams->contains(s)) |
||||
{ |
||||
(*paramIter).setOpalID(opalParams->value(s)); |
||||
// qDebug() << __FILE__ << " Line:" << __LINE__ << ": Successfully added " << s;
|
||||
} |
||||
else |
||||
{ |
||||
qWarning() << __FILE__ << " Line:" << __LINE__ << ": " << s << " was not found in param list"; |
||||
} |
||||
} |
||||
} |
||||
delete opalParams; |
||||
} |
||||
} |
||||
|
||||
ParameterList::~ParameterList() |
||||
{ |
||||
delete params; |
||||
delete paramList; |
||||
} |
||||
|
||||
/**
|
||||
Get the list of parameters in the simulink model. This function does not require |
||||
any prior knowlege of the parameters. It works by first calling OpalGetParameterList to |
||||
get the number of paramters, then allocates the required amount of memory and then gets |
||||
the paramter list using a second call to OpalGetParameterList. |
||||
*/ |
||||
void ParameterList::getParameterList(QMap<QString, unsigned short> *opalParams) |
||||
{ |
||||
/* inputs */ |
||||
unsigned short allocatedParams=0; |
||||
unsigned short allocatedPathLen=0; |
||||
unsigned short allocatedNameLen=0; |
||||
unsigned short allocatedVarLen=0; |
||||
|
||||
/* outputs */ |
||||
unsigned short numParams; |
||||
unsigned short *idParam=NULL; |
||||
unsigned short maxPathLen; |
||||
char **paths=NULL; |
||||
unsigned short maxNameLen; |
||||
char **names=NULL; |
||||
unsigned short maxVarLen; |
||||
char **var=NULL; |
||||
|
||||
int returnValue; |
||||
|
||||
returnValue = OpalGetParameterList(allocatedParams, &numParams, idParam, |
||||
allocatedPathLen, &maxPathLen, paths, |
||||
allocatedNameLen, &maxNameLen, names, |
||||
allocatedVarLen, &maxVarLen, var); |
||||
if (returnValue!=E2BIG) |
||||
{ |
||||
// OpalRT::setLastErrorMsg();
|
||||
OpalRT::OpalErrorMsg::displayLastErrorMsg(); |
||||
return; |
||||
} |
||||
|
||||
// allocate memory for parameter list
|
||||
|
||||
idParam = new unsigned short[numParams]; |
||||
allocatedParams = numParams; |
||||
|
||||
paths = new char*[numParams]; |
||||
for (int i=0; i<numParams; i++) |
||||
paths[i]=new char[maxPathLen]; |
||||
allocatedPathLen = maxPathLen; |
||||
|
||||
names = new char*[numParams]; |
||||
for (int i=0; i<numParams; i++) |
||||
names[i] = new char[maxNameLen]; |
||||
allocatedNameLen = maxNameLen; |
||||
|
||||
var = new char*[numParams]; |
||||
for (int i=0; i<numParams; i++) |
||||
var[i] = new char[maxVarLen]; |
||||
allocatedVarLen = maxVarLen; |
||||
|
||||
returnValue = OpalGetParameterList(allocatedParams, &numParams, idParam, |
||||
allocatedPathLen, &maxPathLen, paths, |
||||
allocatedNameLen, &maxNameLen, names, |
||||
allocatedVarLen, &maxVarLen, var); |
||||
|
||||
if (returnValue != EOK) |
||||
{ |
||||
// OpalRT::setLastErrorMsg();
|
||||
OpalRT::OpalErrorMsg::displayLastErrorMsg(); |
||||
return; |
||||
} |
||||
|
||||
QString path, name; |
||||
for (int i=0; i<numParams; ++i) |
||||
{ |
||||
path.clear(); |
||||
path.append(paths[i]); |
||||
name.clear(); |
||||
name.append(names[i]); |
||||
if (path[path.size()-1] == '/') |
||||
opalParams->insert(path+name, idParam[i]); |
||||
else |
||||
opalParams->insert(path+'/'+name, idParam[i]); |
||||
} |
||||
// Dump out the list of parameters
|
||||
// QMap<QString, unsigned short>::const_iterator paramPrint;
|
||||
// for (paramPrint = opalParams->begin(); paramPrint != opalParams->end(); ++paramPrint)
|
||||
// qDebug() << paramPrint.key();
|
||||
|
||||
|
||||
} |
||||
|
||||
int ParameterList::indexOf(const Parameter &p) |
||||
{ |
||||
// incase p is a copy of the actual parameter we want (i.e., addresses differ)
|
||||
Parameter *pPtr = &((*params)[p.getComponentID()][p.getParamID()]); |
||||
|
||||
QList<QList<Parameter*> >::const_iterator iter; |
||||
int index = -1; |
||||
for (iter = paramList->begin(); iter != paramList->end(); ++iter) |
||||
{ |
||||
if ((index = (*iter).indexOf(pPtr)) != -1) |
||||
return index; |
||||
} |
||||
return index; |
||||
} |
||||
|
||||
|
||||
ParameterList::const_iterator::const_iterator(QList<Parameter> paramList) |
||||
{ |
||||
this->paramList = QList<Parameter>(paramList); |
||||
index = 0; |
||||
} |
||||
|
||||
ParameterList::const_iterator::const_iterator(const const_iterator &other) |
||||
{ |
||||
paramList = QList<Parameter>(other.paramList); |
||||
index = other.index; |
||||
} |
||||
|
||||
ParameterList::const_iterator ParameterList::begin() const |
||||
{ |
||||
QList<QMap<QGCParamID, Parameter> > compList = params->values(); |
||||
QList<Parameter> paramList; |
||||
QList<QMap<QGCParamID, Parameter> >::const_iterator compIter; |
||||
for (compIter = compList.begin(); compIter != compList.end(); ++compIter) |
||||
paramList.append((*compIter).values()); |
||||
return const_iterator(paramList); |
||||
} |
||||
|
||||
ParameterList::const_iterator ParameterList::end() const |
||||
{ |
||||
const_iterator iter = begin(); |
||||
return iter+=iter.paramList.size(); |
||||
} |
||||
|
||||
int ParameterList::count() |
||||
{ |
||||
int count = 0; |
||||
QList<QList<Parameter*> >::const_iterator iter; |
||||
for (iter = paramList->begin(); iter != paramList->end(); ++iter) |
||||
count += (*iter).count(); |
||||
return count; |
||||
} |
||||
|
||||
/* Functions related to reading the xml config file */ |
||||
|
||||
bool ParameterList::open(QString filename) |
||||
{ |
||||
QFile paramFile(filename); |
||||
if (!paramFile.exists()) |
||||
{ |
||||
/// \todo open dialog box (maybe: that could also go in comm config window)
|
||||
return false; |
||||
} |
||||
|
||||
if (!paramFile.open(QIODevice::ReadOnly)) |
||||
{ |
||||
return false; |
||||
} |
||||
|
||||
read(¶mFile); |
||||
|
||||
return true; |
||||
} |
||||
|
||||
bool ParameterList::read(QIODevice *device) |
||||
{ |
||||
QDomDocument *paramConfig = new QDomDocument(); |
||||
|
||||
QString errorStr; |
||||
int errorLine; |
||||
int errorColumn; |
||||
|
||||
if (!paramConfig->setContent(device, true, &errorStr, &errorLine, |
||||
&errorColumn)) |
||||
{ |
||||
qDebug() << "Error reading XML Parameter File on line: " << errorLine << errorStr; |
||||
return false; |
||||
} |
||||
|
||||
QDomElement root = paramConfig->documentElement(); |
||||
if (root.tagName() != "ParameterList") { |
||||
qDebug() << __FILE__ << __LINE__ << "This is not a parameter list xml file"; |
||||
return false; |
||||
} |
||||
|
||||
QDomElement child = root.firstChildElement("Block"); |
||||
while (!child.isNull()) |
||||
{ |
||||
parseBlock(child); |
||||
child = child.nextSiblingElement("Block"); |
||||
} |
||||
|
||||
delete paramConfig; |
||||
return true; |
||||
} |
||||
|
||||
void ParameterList::parseBlock(const QDomElement &block) |
||||
{ |
||||
|
||||
QDomNodeList paramList; |
||||
QDomElement e; |
||||
Parameter *p; |
||||
SubsystemIds id; |
||||
if (block.attribute("name") == "Navigation") |
||||
id = OpalRT::NAV_ID; |
||||
else if (block.attribute("name") == "Controller") |
||||
id = OpalRT::CONTROLLER_ID; |
||||
else if (block.attribute("name") == "ServoOutputs") |
||||
id = OpalRT::SERVO_OUTPUTS; |
||||
else if (block.attribute("name") == "ServoInputs") |
||||
id = OpalRT::SERVO_INPUTS; |
||||
|
||||
paramList = block.elementsByTagName("Parameter"); |
||||
for (int i=0; i < paramList.size(); ++i) |
||||
{ |
||||
e = paramList.item(i).toElement(); |
||||
if (e.hasAttribute("SimulinkPath") && |
||||
e.hasAttribute("SimulinkParameterName") && |
||||
e.hasAttribute("QGCParamID")) |
||||
{ |
||||
|
||||
p = new Parameter(e.attribute("SimulinkPath"), |
||||
e.attribute("SimulinkParameterName"), |
||||
static_cast<uint8_t>(id), |
||||
QGCParamID(e.attribute("QGCParamID"))); |
||||
(*params)[id].insert(p->getParamID(), *p); |
||||
delete p; |
||||
} |
||||
else |
||||
{ |
||||
qDebug() << __FILE__ << ":" << __LINE__ << ": error in xml doc"; |
||||
} |
||||
} |
||||
|
||||
} |
@ -0,0 +1,142 @@
@@ -0,0 +1,142 @@
|
||||
/*=====================================================================
|
||||
|
||||
QGroundControl Open Source Ground Control Station |
||||
|
||||
(c) 2009, 2010 QGROUNDCONTROL PROJECT <http://www.qgroundcontrol.org>
|
||||
|
||||
This file is part of the QGROUNDCONTROL project |
||||
|
||||
QGROUNDCONTROL is free software: you can redistribute it and/or modify |
||||
it under the terms of the GNU General Public License as published by |
||||
the Free Software Foundation, either version 3 of the License, or |
||||
(at your option) any later version. |
||||
|
||||
QGROUNDCONTROL is distributed in the hope that it will be useful, |
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of |
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
||||
GNU General Public License for more details. |
||||
|
||||
You should have received a copy of the GNU General Public License |
||||
along with QGROUNDCONTROL. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
======================================================================*/ |
||||
|
||||
#ifndef PARAMETERLIST_H |
||||
#define PARAMETERLIST_H |
||||
|
||||
#include <QMap> |
||||
#include <QVector> |
||||
#include <QIODevice> |
||||
#include <QFile> |
||||
#include <QDir> |
||||
#include <QApplication> |
||||
#include <QtXml> |
||||
|
||||
#include "mavlink_types.h" |
||||
#include "QGCParamID.h" |
||||
#include "Parameter.h" |
||||
#include "OpalRT.h" |
||||
|
||||
namespace OpalRT |
||||
{ |
||||
class ParameterList |
||||
{ |
||||
public: |
||||
|
||||
class const_iterator |
||||
{ |
||||
friend class ParameterList; |
||||
|
||||
public: |
||||
inline const_iterator() {} |
||||
const_iterator(const const_iterator& other); |
||||
|
||||
const_iterator& operator+=(int i) {index += i; return *this;} |
||||
bool operator<(const const_iterator& other) {return (this->paramList == other.paramList) |
||||
&&(this->index<other.index);} |
||||
bool operator==(const const_iterator& other) {return (this->paramList == other.paramList) |
||||
&&(this->index==other.index);} |
||||
bool operator!=(const const_iterator& other) {return !((*this) == other);} |
||||
const Parameter& operator*() const {return paramList[index];} |
||||
const Parameter* operator->() const {return ¶mList[index];} |
||||
|
||||
const_iterator& operator++() {++index; return *this;} |
||||
private: |
||||
const_iterator(QList<Parameter>); |
||||
QList<Parameter> paramList; |
||||
int index; |
||||
}; |
||||
|
||||
|
||||
ParameterList(); |
||||
~ParameterList(); |
||||
|
||||
/** Count the number of parameters in the list.
|
||||
\return Total number of parameters |
||||
*/ |
||||
int count(); |
||||
|
||||
/** Find p in the list and return its index.
|
||||
\note In order to use this index to look up p, the component is also needed. |
||||
\return the index of p or -1 if p is not found |
||||
\example |
||||
\code |
||||
int compid = OpalRT::CONTROLLER_ID; |
||||
Parameter p("simulinkpath", "simulinkparamname", compid, QGCParamID("PID_GAIN")); |
||||
ParameterList pList; |
||||
if ((int index=pList.indexOf(p)) != -1) |
||||
qDebug() << "PID_GAIN is at index " << index; |
||||
\endcode
|
||||
*/ |
||||
int indexOf(const Parameter& p); |
||||
bool contains(int compid, QGCParamID paramid) const {return (*params)[compid].contains(paramid);} |
||||
|
||||
/// Get a parameter from the list
|
||||
const Parameter getParameter(int compid, QGCParamID paramid) const {return (*params)[compid][paramid];} |
||||
Parameter& getParameter(int compid, QGCParamID paramid) {return (*params)[compid][paramid];} |
||||
const Parameter getParameter(int compid, int index) const {return *((*paramList)[compid][index]);}
|
||||
|
||||
/** Convenient syntax for calling OpalRT::Parameter::getParameter() */ |
||||
Parameter& operator()(int compid, QGCParamID paramid) {return getParameter(compid, paramid);} |
||||
Parameter& operator()(uint8_t compid, QGCParamID paramid) {return getParameter(static_cast<int>(compid), paramid);} |
||||
|
||||
const_iterator begin() const; |
||||
const_iterator end() const; |
||||
|
||||
protected: |
||||
/** Store the parameters mapped by componentid, and paramid.
|
||||
\code |
||||
// Look up a parameter
|
||||
int compid = 1; |
||||
QGCParamID paramid("PID_GAIN"); |
||||
Parameter p = params[compid][paramid]; |
||||
\endcode |
||||
*/ |
||||
QMap<int, QMap<QGCParamID, Parameter> > *params; |
||||
/**
|
||||
Store pointers to the parameters to allow fast lookup by index. |
||||
This variable may be changed to const pointers to ensure all changes |
||||
are made through the map container. |
||||
*/ |
||||
QList<QList<Parameter*> > *paramList; |
||||
/**
|
||||
Get the list of available parameters from Opal-RT. |
||||
\param[out] opalParams Map of parameter paths/names to ids which are valid in Opal-RT |
||||
*/ |
||||
void getParameterList(QMap<QString, unsigned short>* opalParams); |
||||
|
||||
/**
|
||||
Open a file for reading in the xml config data |
||||
*/ |
||||
bool open(QString filename=QString()); |
||||
/**
|
||||
Attempt to read XML configuration data from device |
||||
\param[in] the device to read the xml data from |
||||
\return true if the configuration was read successfully, false otherwise |
||||
*/ |
||||
bool read(QIODevice *device); |
||||
|
||||
void parseBlock(const QDomElement &block); |
||||
}; |
||||
} |
||||
#endif // PARAMETERLIST_H
|
@ -0,0 +1,51 @@
@@ -0,0 +1,51 @@
|
||||
/*=====================================================================
|
||||
|
||||
QGroundControl Open Source Ground Control Station |
||||
|
||||
(c) 2009, 2010 QGROUNDCONTROL PROJECT <http://www.qgroundcontrol.org>
|
||||
|
||||
This file is part of the QGROUNDCONTROL project |
||||
|
||||
QGROUNDCONTROL is free software: you can redistribute it and/or modify |
||||
it under the terms of the GNU General Public License as published by |
||||
the Free Software Foundation, either version 3 of the License, or |
||||
(at your option) any later version. |
||||
|
||||
QGROUNDCONTROL is distributed in the hope that it will be useful, |
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of |
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
||||
GNU General Public License for more details. |
||||
|
||||
You should have received a copy of the GNU General Public License |
||||
along with QGROUNDCONTROL. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
======================================================================*/ |
||||
|
||||
/**
|
||||
* @file |
||||
* @brief Implementation of class OpalRT::QGCParamID |
||||
* @author Bryan Godbolt <godbolt@ualberta.ca> |
||||
*/ |
||||
|
||||
#include "QGCParamID.h" |
||||
using namespace OpalRT; |
||||
|
||||
QGCParamID::QGCParamID(const char paramid[]):data(paramid) |
||||
{ |
||||
} |
||||
|
||||
QGCParamID::QGCParamID(const QString s):data(s) |
||||
{ |
||||
|
||||
} |
||||
|
||||
QGCParamID::QGCParamID(const QGCParamID &other):data(other.data) |
||||
{ |
||||
|
||||
} |
||||
|
||||
//
|
||||
//QDataStream& operator<<(QDataStream& stream, const QGCParamID& paramid)
|
||||
//{
|
||||
// return stream << paramid.data;
|
||||
//}
|
@ -0,0 +1,72 @@
@@ -0,0 +1,72 @@
|
||||
/*=====================================================================
|
||||
|
||||
QGroundControl Open Source Ground Control Station |
||||
|
||||
(c) 2009, 2010 QGROUNDCONTROL PROJECT <http://www.qgroundcontrol.org>
|
||||
|
||||
This file is part of the QGROUNDCONTROL project |
||||
|
||||
QGROUNDCONTROL is free software: you can redistribute it and/or modify |
||||
it under the terms of the GNU General Public License as published by |
||||
the Free Software Foundation, either version 3 of the License, or |
||||
(at your option) any later version. |
||||
|
||||
QGROUNDCONTROL is distributed in the hope that it will be useful, |
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of |
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
||||
GNU General Public License for more details. |
||||
|
||||
You should have received a copy of the GNU General Public License |
||||
along with QGROUNDCONTROL. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
======================================================================*/ |
||||
|
||||
/**
|
||||
* @file |
||||
* @brief Stores the paramid used for mavlink |
||||
* @author Bryan Godbolt <godbolt@ualberta.ca> |
||||
*/ |
||||
|
||||
#ifndef QGCPARAMID_H |
||||
#define QGCPARAMID_H |
||||
|
||||
#include <QString> |
||||
|
||||
#include "mavlink_types.h" |
||||
|
||||
//namespace OpalRT
|
||||
//{
|
||||
// class QGCParamID;
|
||||
//}
|
||||
//
|
||||
//QDataStream& operator<<(QDataStream&, const OpalRT::QGCParamID&);
|
||||
|
||||
namespace OpalRT |
||||
{ |
||||
/** Stores a param_id for the mavlink parameter packets. This class adds the convenience
|
||||
of storing the id as a string (e.g., easy comparison). |
||||
|
||||
\todo Fix: warning: deprecated conversion from string constant to 'char*' |
||||
*/ |
||||
class QGCParamID |
||||
{ |
||||
// friend QDataStream& operator<<(QDataStream& stream, const QGCParamID& paramid);
|
||||
public: |
||||
|
||||
QGCParamID(const char[]); |
||||
QGCParamID(const QString); |
||||
QGCParamID() {} |
||||
QGCParamID(const QGCParamID& other); |
||||
|
||||
bool operator<(const QGCParamID& other) const {return data<other.data;} |
||||
bool operator==(const QGCParamID& other) const {return data == other.data;} |
||||
operator QString() const {return data;} |
||||
|
||||
const QString getParamString() const {return static_cast<const QString>(data);} |
||||
int8_t* toInt8_t() const {return (int8_t*)data.toAscii().data();} |
||||
|
||||
protected: |
||||
QString data; |
||||
}; |
||||
} |
||||
#endif // QGCPARAMID_H
|
@ -0,0 +1,25 @@
@@ -0,0 +1,25 @@
|
||||
#include "OpalLinkConfigurationWindow.h" |
||||
|
||||
OpalLinkConfigurationWindow::OpalLinkConfigurationWindow(OpalLink* link, |
||||
QWidget *parent, |
||||
Qt::WindowFlags flags) : |
||||
QWidget(parent, flags), |
||||
link(link) |
||||
|
||||
{ |
||||
|
||||
|
||||
ui.setupUi(this); |
||||
|
||||
ui.opalInstIDSpinBox->setValue(this->link->getOpalInstID()); |
||||
|
||||
connect(ui.opalInstIDSpinBox, SIGNAL(valueChanged(int)), link, SLOT(setOpalInstID(int))); |
||||
connect(link, SIGNAL(connected(bool)), this, SLOT(allowSettingsAccess(bool))); |
||||
this->show(); |
||||
} |
||||
|
||||
void OpalLinkConfigurationWindow::allowSettingsAccess(bool enabled) |
||||
{ |
||||
ui.paramFileButton->setEnabled(enabled); |
||||
ui.servoConfigFileButton->setEnabled(enabled); |
||||
} |
@ -0,0 +1,27 @@
@@ -0,0 +1,27 @@
|
||||
#ifndef OPALLINKCONFIGURATIONWINDOW_H |
||||
#define OPALLINKCONFIGURATIONWINDOW_H |
||||
|
||||
#include <QWidget> |
||||
#include <QDebug> |
||||
|
||||
#include "LinkInterface.h" |
||||
#include "ui_OpalLinkSettings.h" |
||||
#include "OpalLink.h" |
||||
|
||||
class OpalLinkConfigurationWindow : public QWidget |
||||
{ |
||||
Q_OBJECT |
||||
public: |
||||
explicit OpalLinkConfigurationWindow(OpalLink* link, QWidget *parent = 0, Qt::WindowFlags flags = Qt::Sheet); |
||||
signals: |
||||
|
||||
public slots: |
||||
|
||||
void allowSettingsAccess(bool enabled); |
||||
|
||||
private: |
||||
Ui::OpalLinkSettings ui; |
||||
OpalLink* link; |
||||
}; |
||||
|
||||
#endif // OPALLINKCONFIGURATIONWINDOW_H
|
@ -0,0 +1,173 @@
@@ -0,0 +1,173 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?> |
||||
<ui version="4.0"> |
||||
<class>OpalLinkSettings</class> |
||||
<widget class="QWidget" name="OpalLinkSettings"> |
||||
<property name="geometry"> |
||||
<rect> |
||||
<x>0</x> |
||||
<y>0</y> |
||||
<width>537</width> |
||||
<height>250</height> |
||||
</rect> |
||||
</property> |
||||
<property name="windowTitle"> |
||||
<string>OpalLink Configuration</string> |
||||
</property> |
||||
<layout class="QGridLayout" name="gridLayout" rowstretch="0,0,0,0"> |
||||
<property name="margin"> |
||||
<number>6</number> |
||||
</property> |
||||
<item row="0" column="0"> |
||||
<widget class="QLabel" name="portlabel"> |
||||
<property name="text"> |
||||
<string>Model Instance ID</string> |
||||
</property> |
||||
</widget> |
||||
</item> |
||||
<item row="1" column="0"> |
||||
<widget class="QLabel" name="portlabel_2"> |
||||
<property name="text"> |
||||
<string>Opal-RT Parameter File</string> |
||||
</property> |
||||
</widget> |
||||
</item> |
||||
<item row="2" column="0"> |
||||
<widget class="QLabel" name="portlabel_3"> |
||||
<property name="text"> |
||||
<string>Servo Configuration File</string> |
||||
</property> |
||||
</widget> |
||||
</item> |
||||
<item row="3" column="0" colspan="2"> |
||||
<spacer name="verticalSpacer"> |
||||
<property name="orientation"> |
||||
<enum>Qt::Vertical</enum> |
||||
</property> |
||||
<property name="sizeHint" stdset="0"> |
||||
<size> |
||||
<width>431</width> |
||||
<height>47</height> |
||||
</size> |
||||
</property> |
||||
</spacer> |
||||
</item> |
||||
<item row="1" column="1"> |
||||
<widget class="QLabel" name="label"> |
||||
<property name="text"> |
||||
<string/> |
||||
</property> |
||||
</widget> |
||||
</item> |
||||
<item row="2" column="1"> |
||||
<widget class="QLabel" name="label_2"> |
||||
<property name="text"> |
||||
<string/> |
||||
</property> |
||||
</widget> |
||||
</item> |
||||
<item row="1" column="2"> |
||||
<widget class="QPushButton" name="paramFileButton"> |
||||
<property name="enabled"> |
||||
<bool>false</bool> |
||||
</property> |
||||
<property name="text"> |
||||
<string>Change</string> |
||||
</property> |
||||
<property name="icon"> |
||||
<iconset resource="../../mavground.qrc"> |
||||
<normaloff>:/images/status/folder-open.svg</normaloff>:/images/status/folder-open.svg</iconset> |
||||
</property> |
||||
</widget> |
||||
</item> |
||||
<item row="2" column="2"> |
||||
<widget class="QPushButton" name="servoConfigFileButton"> |
||||
<property name="enabled"> |
||||
<bool>false</bool> |
||||
</property> |
||||
<property name="text"> |
||||
<string>Change</string> |
||||
</property> |
||||
<property name="icon"> |
||||
<iconset resource="../../mavground.qrc"> |
||||
<normaloff>:/images/status/folder-open.svg</normaloff>:/images/status/folder-open.svg</iconset> |
||||
</property> |
||||
</widget> |
||||
</item> |
||||
<item row="0" column="1" colspan="2"> |
||||
<layout class="QHBoxLayout" name="horizontalLayout"> |
||||
<item> |
||||
<spacer name="horizontalSpacer"> |
||||
<property name="orientation"> |
||||
<enum>Qt::Horizontal</enum> |
||||
</property> |
||||
<property name="sizeHint" stdset="0"> |
||||
<size> |
||||
<width>40</width> |
||||
<height>20</height> |
||||
</size> |
||||
</property> |
||||
</spacer> |
||||
</item> |
||||
<item> |
||||
<widget class="QSpinBox" name="opalInstIDSpinBox"> |
||||
<property name="minimum"> |
||||
<number>101</number> |
||||
</property> |
||||
<property name="maximum"> |
||||
<number>200</number> |
||||
</property> |
||||
<property name="value"> |
||||
<number>101</number> |
||||
</property> |
||||
</widget> |
||||
</item> |
||||
</layout> |
||||
</item> |
||||
</layout> |
||||
<action name="actionDelete"> |
||||
<property name="text"> |
||||
<string>Delete</string> |
||||
</property> |
||||
<property name="toolTip"> |
||||
<string>Delete this link</string> |
||||
</property> |
||||
</action> |
||||
<action name="actionConnect"> |
||||
<property name="text"> |
||||
<string>Connect</string> |
||||
</property> |
||||
<property name="toolTip"> |
||||
<string>Connect this link</string> |
||||
</property> |
||||
</action> |
||||
<action name="actionClose"> |
||||
<property name="text"> |
||||
<string>Close</string> |
||||
</property> |
||||
<property name="toolTip"> |
||||
<string>Close the configuration window</string> |
||||
</property> |
||||
</action> |
||||
</widget> |
||||
<resources> |
||||
<include location="../../mavground.qrc"/> |
||||
</resources> |
||||
<connections> |
||||
<connection> |
||||
<sender>actionClose</sender> |
||||
<signal>triggered()</signal> |
||||
<receiver>OpalLinkSettings</receiver> |
||||
<slot>close()</slot> |
||||
<hints> |
||||
<hint type="sourcelabel"> |
||||
<x>-1</x> |
||||
<y>-1</y> |
||||
</hint> |
||||
<hint type="destinationlabel"> |
||||
<x>224</x> |
||||
<y>195</y> |
||||
</hint> |
||||
</hints> |
||||
</connection> |
||||
</connections> |
||||
</ui> |
Loading…
Reference in new issue