Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
qgroundcontrol
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Valentin Platzgummer
qgroundcontrol
Commits
b878d1f3
Commit
b878d1f3
authored
Feb 10, 2014
by
Don Gagne
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
These are all unused variable or parameter warning fixes
parent
e53822a0
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
24 additions
and
31 deletions
+24
-31
MAVLinkSimulationLink.cc
src/comm/MAVLinkSimulationLink.cc
+1
-1
MAVLinkSimulationLink.h
src/comm/MAVLinkSimulationLink.h
+1
-1
MAVLinkSimulationMAV.cc
src/comm/MAVLinkSimulationMAV.cc
+15
-5
MAVLinkSwarmSimulationLink.cc
src/comm/MAVLinkSwarmSimulationLink.cc
+2
-2
MAVLinkSwarmSimulationLink.h
src/comm/MAVLinkSwarmSimulationLink.h
+1
-1
MockUAS.h
src/qgcunittest/MockUAS.h
+1
-1
UAS.cc
src/uas/UAS.cc
+0
-17
HUD.cc
src/ui/HUD.cc
+1
-1
QGCPX4VehicleConfig.cc
src/ui/QGCPX4VehicleConfig.cc
+2
-2
No files found.
src/comm/MAVLinkSimulationLink.cc
View file @
b878d1f3
...
...
@@ -55,7 +55,7 @@ This file is part of the QGROUNDCONTROL project
* @param writeFile The received messages are written to that file
* @param rate The rate at which the messages are sent (in intervals of milliseconds)
**/
MAVLinkSimulationLink
::
MAVLinkSimulationLink
(
QString
readFile
,
QString
writeFile
,
int
rate
,
QObject
*
parent
)
:
MAVLinkSimulationLink
::
MAVLinkSimulationLink
(
QString
readFile
,
QString
writeFile
,
int
rate
)
:
readyBytes
(
0
),
timeOffset
(
0
)
{
...
...
src/comm/MAVLinkSimulationLink.h
View file @
b878d1f3
...
...
@@ -48,7 +48,7 @@ class MAVLinkSimulationLink : public LinkInterface
{
Q_OBJECT
public:
MAVLinkSimulationLink
(
QString
readFile
=
""
,
QString
writeFile
=
""
,
int
rate
=
5
,
QObject
*
parent
=
0
);
MAVLinkSimulationLink
(
QString
readFile
=
""
,
QString
writeFile
=
""
,
int
rate
=
5
);
~
MAVLinkSimulationLink
();
bool
isConnected
()
const
;
qint64
bytesAvailable
();
...
...
src/comm/MAVLinkSimulationMAV.cc
View file @
b878d1f3
...
...
@@ -303,6 +303,11 @@ void MAVLinkSimulationMAV::mainloop()
timer25Hz
--
;
}
// Uncomment to turn on debug message printing
//#define DEBUG_PRINT_MESSAGE
#ifdef DEBUG_PRINT_MESSAGE
//static unsigned chan_counts[MAVLINK_COMM_NUM_BUFFERS];
static
const
unsigned
message_lengths
[]
=
MAVLINK_MESSAGE_LENGTHS
;
...
...
@@ -376,17 +381,22 @@ static void print_field(const mavlink_message_t *msg, const mavlink_field_info_t
}
qDebug
(
" "
);
}
#endif
static
void
print_message
(
const
mavlink_message_t
*
msg
)
{
#ifdef DEBUG_PRINT_MESSAGE
const
mavlink_message_info_t
*
m
=
&
message_info
[
msg
->
msgid
];
const
mavlink_field_info_t
*
f
=
m
->
fields
;
unsigned
i
;
// qDebug("%s { ", m->name);
// for (i=0; i<m->num_fields; i++) {
// print_field(msg, &f[i]);
// }
// qDebug("}\n");
qDebug
(
"%s { "
,
m
->
name
);
for
(
i
=
0
;
i
<
m
->
num_fields
;
i
++
)
{
print_field
(
msg
,
&
f
[
i
]);
}
qDebug
(
"}
\n
"
);
#else
Q_UNUSED
(
msg
);
#endif
}
void
MAVLinkSimulationMAV
::
handleMessage
(
const
mavlink_message_t
&
msg
)
...
...
src/comm/MAVLinkSwarmSimulationLink.cc
View file @
b878d1f3
#include "MAVLinkSwarmSimulationLink.h"
MAVLinkSwarmSimulationLink
::
MAVLinkSwarmSimulationLink
(
QString
readFile
,
QString
writeFile
,
int
rate
,
QObject
*
parent
)
:
MAVLinkSimulationLink
(
readFile
,
writeFile
,
rate
,
parent
)
MAVLinkSwarmSimulationLink
::
MAVLinkSwarmSimulationLink
(
QString
readFile
,
QString
writeFile
,
int
rate
)
:
MAVLinkSimulationLink
(
readFile
,
writeFile
,
rate
)
{
}
...
...
src/comm/MAVLinkSwarmSimulationLink.h
View file @
b878d1f3
...
...
@@ -7,7 +7,7 @@ class MAVLinkSwarmSimulationLink : public MAVLinkSimulationLink
{
Q_OBJECT
public:
MAVLinkSwarmSimulationLink
(
QString
readFile
=
""
,
QString
writeFile
=
""
,
int
rate
=
5
,
QObject
*
parent
=
0
);
MAVLinkSwarmSimulationLink
(
QString
readFile
=
""
,
QString
writeFile
=
""
,
int
rate
=
5
);
signals:
...
...
src/qgcunittest/MockUAS.h
View file @
b878d1f3
...
...
@@ -154,7 +154,7 @@ public slots:
virtual
void
setLocalPositionSetpoint
(
float
x
,
float
y
,
float
z
,
float
yaw
)
{
Q_UNUSED
(
x
);
Q_UNUSED
(
y
);
Q_UNUSED
(
z
);
Q_UNUSED
(
yaw
);
Q_ASSERT
(
false
);
};
virtual
void
setLocalPositionOffset
(
float
x
,
float
y
,
float
z
,
float
yaw
)
{
Q_UNUSED
(
x
);
Q_UNUSED
(
y
);
Q_UNUSED
(
z
);
Q_UNUSED
(
yaw
);
Q_ASSERT
(
false
);
};
virtual
void
startRadioControlCalibration
(
int
param
)
{
Q_ASSERT
(
false
);
};
virtual
void
startRadioControlCalibration
(
int
param
)
{
Q_
UNUSED
(
param
);
Q_
ASSERT
(
false
);
};
virtual
void
endRadioControlCalibration
()
{
Q_ASSERT
(
false
);
};
virtual
void
startMagnetometerCalibration
()
{
Q_ASSERT
(
false
);
};
virtual
void
startGyroscopeCalibration
()
{
Q_ASSERT
(
false
);
};
...
...
src/uas/UAS.cc
View file @
b878d1f3
...
...
@@ -3086,23 +3086,6 @@ void UAS::sendHilGroundTruth(quint64 time_us, float roll, float pitch, float yaw
Q_UNUSED
(
yacc
);
Q_UNUSED
(
zacc
);
float
q
[
4
];
double
cosPhi_2
=
cos
(
double
(
roll
)
/
2.0
);
double
sinPhi_2
=
sin
(
double
(
roll
)
/
2.0
);
double
cosTheta_2
=
cos
(
double
(
pitch
)
/
2.0
);
double
sinTheta_2
=
sin
(
double
(
pitch
)
/
2.0
);
double
cosPsi_2
=
cos
(
double
(
yaw
)
/
2.0
);
double
sinPsi_2
=
sin
(
double
(
yaw
)
/
2.0
);
q
[
0
]
=
(
cosPhi_2
*
cosTheta_2
*
cosPsi_2
+
sinPhi_2
*
sinTheta_2
*
sinPsi_2
);
q
[
1
]
=
(
sinPhi_2
*
cosTheta_2
*
cosPsi_2
-
cosPhi_2
*
sinTheta_2
*
sinPsi_2
);
q
[
2
]
=
(
cosPhi_2
*
sinTheta_2
*
cosPsi_2
+
sinPhi_2
*
cosTheta_2
*
sinPsi_2
);
q
[
3
]
=
(
cosPhi_2
*
cosTheta_2
*
sinPsi_2
-
sinPhi_2
*
sinTheta_2
*
cosPsi_2
);
// Emit attitude for cross-check
emit
valueChanged
(
uasId
,
"roll sim"
,
"rad"
,
roll
,
getUnixTime
());
emit
valueChanged
(
uasId
,
"pitch sim"
,
"rad"
,
pitch
,
getUnixTime
());
...
...
src/ui/HUD.cc
View file @
b878d1f3
...
...
@@ -601,7 +601,7 @@ void HUD::paintHUD()
xImageFactor
=
width
()
/
(
float
)
glImage
.
width
();
yImageFactor
=
height
()
/
(
float
)
glImage
.
height
();
float
imageFactor
=
qMin
(
xImageFactor
,
yImageFactor
);
//
float imageFactor = qMin(xImageFactor, yImageFactor);
// Resize to correct size and fill with image
// FIXME
...
...
src/ui/QGCPX4VehicleConfig.cc
View file @
b878d1f3
...
...
@@ -1836,13 +1836,13 @@ void QGCPX4VehicleConfig::parameterChanged(int uas, int component, QString param
else
{
//Param recieved that we have no metadata for. Search to see if it belongs in a
//group with some other params
bool
found
=
false
;
//
bool found = false;
for
(
int
i
=
0
;
i
<
toolWidgets
.
size
();
i
++
)
{
if
(
parameterName
.
startsWith
(
toolWidgets
[
i
]
->
objectName
()))
{
//It should be grouped with this one, add it.
toolWidgets
[
i
]
->
addParam
(
uas
,
component
,
parameterName
,
value
);
libParamToWidgetMap
.
insert
(
parameterName
,
toolWidgets
[
i
]);
found
=
true
;
//
found = true;
break
;
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment