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
1f54d9a3
Commit
1f54d9a3
authored
Nov 19, 2010
by
Mariano Lizarraga
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
git://github.com/tecnosapiens/qgroundcontrol
into mergeRemote
parents
2226a433
6d43e99e
Changes
12
Show whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
86 additions
and
45 deletions
+86
-45
Waypoint.cc
src/Waypoint.cc
+1
-0
Waypoint.h
src/Waypoint.h
+1
-0
SlugsMAV.cc
src/uas/SlugsMAV.cc
+14
-14
SlugsMAV.h
src/uas/SlugsMAV.h
+2
-0
UASWaypointManager.cc
src/uas/UASWaypointManager.cc
+3
-0
UASWaypointManager.h
src/uas/UASWaypointManager.h
+3
-0
MainWindow.cc
src/ui/MainWindow.cc
+4
-0
MapWidget.cc
src/ui/MapWidget.cc
+11
-1
SlugsDataSensorView.cc
src/ui/SlugsDataSensorView.cc
+24
-25
SlugsPIDControl.cpp
src/ui/SlugsPIDControl.cpp
+2
-2
WaypointList.cc
src/ui/WaypointList.cc
+17
-2
WaypointList.h
src/ui/WaypointList.h
+4
-1
No files found.
src/Waypoint.cc
View file @
1f54d9a3
...
...
@@ -75,6 +75,7 @@ bool Waypoint::load(QTextStream &loadStream)
return
false
;
}
void
Waypoint
::
setId
(
quint16
id
)
{
this
->
id
=
id
;
...
...
src/Waypoint.h
View file @
1f54d9a3
...
...
@@ -59,6 +59,7 @@ public:
bool
load
(
QTextStream
&
loadStream
);
protected:
quint16
id
;
float
x
;
...
...
src/uas/SlugsMAV.cc
View file @
1f54d9a3
src/uas/SlugsMAV.h
View file @
1f54d9a3
...
...
@@ -105,6 +105,8 @@ protected:
mavlink_slugs_action_t
mlAction
;
// Standart messages MAVLINK used by SLUGS
private:
...
...
src/uas/UASWaypointManager.cc
View file @
1f54d9a3
...
...
@@ -383,9 +383,12 @@ void UASWaypointManager::localLoadWaypoints(const QString &loadFile)
}
file
.
close
();
emit
loadWPFile
();
emit
waypointListChanged
();
}
void
UASWaypointManager
::
globalAddWaypoint
(
Waypoint
*
wp
)
{
...
...
src/uas/UASWaypointManager.h
View file @
1f54d9a3
...
...
@@ -91,6 +91,7 @@ public:
void
localMoveWaypoint
(
quint16
cur_seq
,
quint16
new_seq
);
///< locally move a waypoint from its current position cur_seq to a new position new_seq
void
localSaveWaypoints
(
const
QString
&
saveFile
);
///< saves the local waypoint list to saveFile
void
localLoadWaypoints
(
const
QString
&
loadFile
);
///< loads a waypoint list from loadFile
/*@}*/
/** @name Global waypoint list operations */
...
...
@@ -120,6 +121,8 @@ signals:
void
currentWaypointChanged
(
quint16
);
///< emits the new current waypoint sequence number
void
updateStatusString
(
const
QString
&
);
///< emits the current status string
void
loadWPFile
();
///< emits signal that a file wp has been load
private:
UAS
&
uas
;
///< Reference to the corresponding UAS
quint32
current_retries
;
///< The current number of retries left
...
...
src/ui/MainWindow.cc
View file @
1f54d9a3
...
...
@@ -401,6 +401,9 @@ void MainWindow::connectActions()
// Slugs View
connect
(
ui
.
actionShow_Slugs_View
,
SIGNAL
(
triggered
()),
this
,
SLOT
(
loadSlugsView
()));
//GlobalOperatorView
// connect(ui.actionGlobalOperatorView,SIGNAL(triggered()),waypointsDockWidget->widget(),SLOT())
}
void
MainWindow
::
showHelp
()
...
...
@@ -918,6 +921,7 @@ void MainWindow::loadGlobalOperatorView()
{
addDockWidget
(
Qt
::
BottomDockWidgetArea
,
waypointsDockWidget
);
waypointsDockWidget
->
show
();
}
// Slugs Data View
...
...
src/ui/MapWidget.cc
View file @
1f54d9a3
...
...
@@ -396,7 +396,17 @@ void MapWidget::createWaypointGraphAtMap(const QPointF coordinate)
str
=
QString
(
"%1"
).
arg
(
path
->
numberOfPoints
());
// create the WP and set everything in the LineString to display the path
CirclePoint
*
tempCirclePoint
=
new
CirclePoint
(
coordinate
.
x
(),
coordinate
.
y
(),
10
,
str
);
//CirclePoint* tempCirclePoint = new CirclePoint(coordinate.x(), coordinate.y(), 10, str);
Waypoint2DIcon
*
tempCirclePoint
;
if
(
mav
)
{
tempCirclePoint
=
new
Waypoint2DIcon
(
coordinate
.
x
(),
coordinate
.
y
(),
20
,
str
,
qmapcontrol
::
Point
::
Middle
,
new
QPen
(
mav
->
getColor
()));
}
else
{
tempCirclePoint
=
new
Waypoint2DIcon
(
coordinate
.
x
(),
coordinate
.
y
(),
20
,
str
,
qmapcontrol
::
Point
::
Middle
);
}
mc
->
layer
(
"Waypoints"
)
->
addGeometry
(
tempCirclePoint
);
Point
*
tempPoint
=
new
Point
(
coordinate
.
x
(),
coordinate
.
y
(),
str
);
...
...
src/ui/SlugsDataSensorView.cc
View file @
1f54d9a3
...
...
@@ -51,7 +51,6 @@ void SlugsDataSensorView::addUAS(UASInterface* uas)
connect
(
slugsMav
,
SIGNAL
(
slugsGPSDateTime
(
int
,
const
mavlink_gps_date_time_t
&
)),
this
,
SLOT
(
slugsGPSDateTimeChanged
(
int
,
const
mavlink_gps_date_time_t
&
)));
#endif // MAVLINK_ENABLED_SLUGS
// Set this UAS as active if it is the first one
if
(
activeUAS
==
0
)
{
activeUAS
=
uas
;
...
...
src/ui/SlugsPIDControl.cpp
View file @
1f54d9a3
src/ui/WaypointList.cc
View file @
1f54d9a3
...
...
@@ -91,6 +91,7 @@ WaypointList::WaypointList(QWidget *parent, UASInterface* uas) :
this
->
setVisible
(
false
);
isGlobalWP
=
false
;
isLocalWP
=
false
;
loadFileGlobalWP
=
false
;
centerMapCoordinate
.
setX
(
0.0
);
centerMapCoordinate
.
setY
(
0.0
);
...
...
@@ -131,6 +132,7 @@ void WaypointList::setUAS(UASInterface* uas)
connect
(
&
uas
->
getWaypointManager
(),
SIGNAL
(
updateStatusString
(
const
QString
&
)),
this
,
SLOT
(
updateStatusLabel
(
const
QString
&
)));
connect
(
&
uas
->
getWaypointManager
(),
SIGNAL
(
waypointListChanged
(
void
)),
this
,
SLOT
(
waypointListChanged
(
void
)));
connect
(
&
uas
->
getWaypointManager
(),
SIGNAL
(
currentWaypointChanged
(
quint16
)),
this
,
SLOT
(
currentWaypointChanged
(
quint16
)));
connect
(
&
uas
->
getWaypointManager
(),
SIGNAL
(
loadWPFile
()),
this
,
SLOT
(
setIsLoadFileWP
()));
}
}
...
...
@@ -147,8 +149,11 @@ void WaypointList::loadWaypoints()
{
if
(
uas
)
{
QString
fileName
=
QFileDialog
::
getOpenFileName
(
this
,
tr
(
"Load File"
),
"."
,
tr
(
"Waypoint File (*.txt)"
));
uas
->
getWaypointManager
().
localLoadWaypoints
(
fileName
);
}
}
...
...
@@ -336,6 +341,11 @@ void WaypointList::waypointListChanged()
WaypointGlobalView
*
wpgv
=
wpGlobalViews
.
value
(
wp
);
wpgv
->
updateValues
();
listLayout
->
addWidget
(
wpgv
);
if
(
loadFileGlobalWP
)
{
emit
createWaypointAtMap
(
QPointF
(
wp
->
getX
(),
wp
->
getY
()));
qDebug
()
<<
"Emitiendo Pos: "
<<
wp
->
getX
()
<<
" - "
<<
wp
->
getY
();
}
}
}
...
...
@@ -391,7 +401,7 @@ void WaypointList::waypointListChanged()
}
loadFileGlobalWP
=
false
;
}
...
...
@@ -622,3 +632,8 @@ void WaypointList::changeWPPositionBySpinBox(Waypoint *wp)
emit
changePositionWPGlobalBySpinBox
(
wp
->
getId
(),
wp
->
getY
(),
wp
->
getX
());
}
void
WaypointList
::
setIsLoadFileWP
()
{
loadFileGlobalWP
=
true
;
}
src/ui/WaypointList.h
View file @
1f54d9a3
...
...
@@ -102,6 +102,8 @@ public slots:
void
moveDown
(
Waypoint
*
wp
);
void
removeWaypoint
(
Waypoint
*
wp
);
void
setIsLoadFileWP
();
...
...
@@ -128,6 +130,7 @@ protected:
bool
isGlobalWP
;
bool
isLocalWP
;
QPointF
centerMapCoordinate
;
bool
loadFileGlobalWP
;
private:
Ui
::
WaypointList
*
m_ui
;
...
...
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