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
18c7a96c
Commit
18c7a96c
authored
Jun 04, 2015
by
Don Gagne
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added PX4Flow identification
Also added logging category
parent
006c4528
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
10 deletions
+13
-10
LinkManager.cc
src/comm/LinkManager.cc
+10
-10
LinkManager.h
src/comm/LinkManager.h
+3
-0
No files found.
src/comm/LinkManager.cc
View file @
18c7a96c
...
...
@@ -47,7 +47,7 @@ This file is part of the QGROUNDCONTROL project
#include "QGCApplication.h"
IMPLEMENT_QGC_SINGLETON
(
LinkManager
,
LinkManager
)
QGC_LOGGING_CATEGORY
(
LinkManagerLog
,
"LinkManagerLog"
)
/**
* @brief Private singleton constructor
...
...
@@ -459,15 +459,13 @@ void LinkManager::_updateConfigurationList(void)
QList
<
QSerialPortInfo
>
portList
=
QSerialPortInfo
::
availablePorts
();
// Iterate Comm Ports
foreach
(
QSerialPortInfo
portInfo
,
portList
)
{
#if 0
qDebug() << "-----------------------------------------------------";
qDebug() << "portName: " << portInfo.portName();
qDebug() << "systemLocation: " << portInfo.systemLocation();
qDebug() << "description: " << portInfo.description();
qDebug() << "manufacturer: " << portInfo.manufacturer();
qDebug() << "serialNumber: " << portInfo.serialNumber();
qDebug() << "vendorIdentifier: " << portInfo.vendorIdentifier();
#endif
qCDebug
(
LinkManagerLog
)
<<
"-----------------------------------------------------"
;
qCDebug
(
LinkManagerLog
)
<<
"portName: "
<<
portInfo
.
portName
();
qCDebug
(
LinkManagerLog
)
<<
"systemLocation: "
<<
portInfo
.
systemLocation
();
qCDebug
(
LinkManagerLog
)
<<
"description: "
<<
portInfo
.
description
();
qCDebug
(
LinkManagerLog
)
<<
"manufacturer: "
<<
portInfo
.
manufacturer
();
qCDebug
(
LinkManagerLog
)
<<
"serialNumber: "
<<
portInfo
.
serialNumber
();
qCDebug
(
LinkManagerLog
)
<<
"vendorIdentifier: "
<<
portInfo
.
vendorIdentifier
();
// Save port name
currentPorts
<<
portInfo
.
systemLocation
();
// Is this a PX4 and NOT in bootloader mode?
...
...
@@ -483,6 +481,8 @@ void LinkManager::_updateConfigurationList(void)
// Lets create a new Serial configuration automatically
if
(
portInfo
.
description
()
==
"AeroCore"
)
{
pSerial
=
new
SerialConfiguration
(
QString
(
"AeroCore on %1"
).
arg
(
portInfo
.
portName
().
trimmed
()));
}
else
if
(
portInfo
.
description
().
contains
(
"PX4Flow"
))
{
pSerial
=
new
SerialConfiguration
(
QString
(
"PX4Flow on %1"
).
arg
(
portInfo
.
portName
().
trimmed
()));
}
else
if
(
portInfo
.
description
().
contains
(
"PX4"
))
{
pSerial
=
new
SerialConfiguration
(
QString
(
"Pixhawk on %1"
).
arg
(
portInfo
.
portName
().
trimmed
()));
}
else
{
...
...
src/comm/LinkManager.h
View file @
18c7a96c
...
...
@@ -33,6 +33,7 @@ This file is part of the PIXHAWK project
#include "LinkConfiguration.h"
#include "LinkInterface.h"
#include "QGCLoggingCategory.h"
// Links
#ifndef __ios__
...
...
@@ -49,6 +50,8 @@ This file is part of the PIXHAWK project
#include "QGCSingleton.h"
#include "MAVLinkProtocol.h"
Q_DECLARE_LOGGING_CATEGORY
(
LinkManagerLog
)
class
LinkManagerTest
;
/// Manage communication links
...
...
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