forked from qt-creator/qt-creator
...to connect to embedded Linux devices. Change-Id: Icd4196a25cf99928d929c70df17cd0f7e271abf6 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
154 lines
6.7 KiB
Plaintext
154 lines
6.7 KiB
Plaintext
/****************************************************************************
|
|
**
|
|
** Copyright (C) 2019 The Qt Company Ltd.
|
|
** Contact: https://www.qt.io/licensing/
|
|
**
|
|
** This file is part of the Qt Creator documentation.
|
|
**
|
|
** Commercial License Usage
|
|
** Licensees holding valid commercial Qt licenses may use this file in
|
|
** accordance with the commercial license agreement provided with the
|
|
** Software or, alternatively, in accordance with the terms contained in
|
|
** a written agreement between you and The Qt Company. For licensing terms
|
|
** and conditions see https://www.qt.io/terms-conditions. For further
|
|
** information use the contact form at https://www.qt.io/contact-us.
|
|
**
|
|
** GNU Free Documentation License Usage
|
|
** Alternatively, this file may be used under the terms of the GNU Free
|
|
** Documentation License version 1.3 as published by the Free Software
|
|
** Foundation and appearing in the file included in the packaging of
|
|
** this file. Please review the following information to ensure
|
|
** the GNU Free Documentation License version 1.3 requirements
|
|
** will be met: https://www.gnu.org/licenses/fdl-1.3.html.
|
|
**
|
|
****************************************************************************/
|
|
|
|
/*!
|
|
|
|
\contentspage index.html
|
|
\page creator-developing-generic-linux.html
|
|
\if defined(qtdesignstudio)
|
|
\previouspage creator-developing-android.html
|
|
\nextpage studio-advanced.html
|
|
\else
|
|
\previouspage creator-developing-baremetal.html
|
|
\nextpage creator-developing-ios.html
|
|
\endif
|
|
|
|
\title Connecting Embedded Linux Devices
|
|
|
|
You can connect embedded Linux devices to the development PC to run,
|
|
debug, and analyze applications built for them from \QC.
|
|
|
|
If you have a tool chain for building applications for embedded Linux
|
|
devices installed on the development PC, you can add
|
|
it to \QC. You can then select a \l{glossary-buildandrun-kit}{kit}
|
|
with \uicontrol {Embedded Linux} device type to
|
|
build applications for and run them on embedded Linux devices.
|
|
|
|
To be able to run and debug applications on embedded Linux devices, you must
|
|
add devices and select them in the \QC \l{glossary-buildandrun-kit}{kit}.
|
|
|
|
You use a wizard to create the connections. You can edit the settings later
|
|
in \uicontrol Tools > \uicontrol Options > \uicontrol Devices >
|
|
\uicontrol Devices.
|
|
|
|
\image qtcreator-linux-device-configurations.png "Devices dialog"
|
|
|
|
You can protect the connections between \QC and a device by using an
|
|
\l{https://www.openssh.com/}{OpenSSH} connection. OpenSSH is a
|
|
connectivity tool for remote login using the SSH protocol. The OpenSSH
|
|
suite is not delivered with \QC, so you must download it and install it
|
|
on the development PC. Then, you must configure the paths to the tools in
|
|
\QC. For more information, see \l {Configuring SSH Connections}.
|
|
|
|
You need either a password or an SSH public and private key pair for
|
|
authentication. If you do not have an SSH key, you can use the ssh-keygen
|
|
tool to create it in \QC. For more information, see \l {Generating SSH Keys}.
|
|
|
|
To configure connections between \QC and an embedded Linux device and to
|
|
specify build and run settings for the device:
|
|
|
|
\list 1
|
|
|
|
\li Make sure that your device can be reached via an IP address.
|
|
|
|
\li Select \uicontrol Tools > \uicontrol Options > \uicontrol Kits >
|
|
\uicontrol {Qt Versions} > \uicontrol Add to add the Qt version
|
|
for embedded Linux.
|
|
|
|
\li Select \uicontrol Tools > \uicontrol Options > \uicontrol Kits >
|
|
\uicontrol Compilers > \uicontrol Add to add the compiler for
|
|
building the applications.
|
|
|
|
\li To deploy applications and run them remotely on devices, specify
|
|
parameters for accessing the devices:
|
|
|
|
\list 1
|
|
|
|
\li Select \uicontrol Tools > \uicontrol Options >
|
|
\uicontrol Devices > \uicontrol Devices > \uicontrol Add >
|
|
\uicontrol {Generic Linux Device}
|
|
> \uicontrol {Start Wizard}.
|
|
|
|
\image qtcreator-screenshot-devconf-linux.png "Connection Data wizard"
|
|
|
|
\li In the \uicontrol {The name to identify this configuration} field,
|
|
enter a name for the connection.
|
|
|
|
\li In the \uicontrol {The device's host name or IP address} field,
|
|
enter the host name or IP address of the device.
|
|
This value will be available in the variable \c %{Device:HostAddress}.
|
|
|
|
\li In the \uicontrol {The username to log into the device} field,
|
|
enter the username to log into the device and run the
|
|
application as.
|
|
This value will be available in the variable \c %{Device:UserName}.
|
|
|
|
\li In the \uicontrol {The authentication type} field, select
|
|
\uicontrol Default to use the currently displayed private
|
|
key file for authentication. Select \uicontrol {Specific Key}
|
|
to use some other key, and enter the path to the file that
|
|
contains the private key in the field below. This value will
|
|
be available in the variable \c %{Device:PrivateKeyFile}.
|
|
|
|
\li Click \uicontrol {Next} to create the connection.
|
|
|
|
\endlist
|
|
|
|
All of these parameters can be edited later, as well as additional ones that the
|
|
wizard does not show because there are sensible default values. One of these is
|
|
the SSH port number, which is available in the variable \c %{Device:SshPort}.
|
|
|
|
|
|
\li Select \uicontrol Tools > \uicontrol Options > \uicontrol Kits >
|
|
\uicontrol Add to add a kit for building for the device. Select the
|
|
Qt version, compiler, and device that you added above, and choose
|
|
\uicontrol {Generic Linux Device} for the device type.
|
|
|
|
\li To specify build settings:
|
|
|
|
\list 1
|
|
|
|
\li Open a project for an application you want to develop for the
|
|
device.
|
|
|
|
\li Select \uicontrol Projects > \uicontrol {Build & Run} to enable
|
|
the kit that you specified above.
|
|
|
|
\endlist
|
|
|
|
\li Select \uicontrol Run to specify run settings. Usually, you can use
|
|
the default settings.
|
|
|
|
When you run the project, \QC deploys the application as specified by the
|
|
deploy steps. By default, \QC copies the application files to the device.
|
|
For more information, see \l{Deploying Applications to Embedded Linux Devices}.
|
|
|
|
\endlist
|
|
|
|
\include linux-mobile/linuxdev-keys.qdocinc configuring ssh
|
|
\include linux-mobile/linuxdev-keys.qdocinc generating ssh keys
|
|
\include linux-mobile/linuxdev-processes.qdocinc managing device processes
|
|
*/
|