creator-baremetal-dev.qdoc 5 KB
Newer Older
1 2
/****************************************************************************
**
3 4
** Copyright (C) 2016 The Qt Company Ltd.
** Contact: https://www.qt.io/licensing/
5
**
6
** This file is part of the Qt Creator documentation.
7
**
8 9 10 11 12 13 14
** 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.
15
**
16
** GNU Free Documentation License Usage
17 18
** Alternatively, this file may be used under the terms of the GNU Free
** Documentation License version 1.3 as published by the Free Software
19 20 21 22
** 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.
23 24 25 26 27
**
****************************************************************************/

    /*!

28
    \contentspage {Qt Creator Manual}
29 30
    \previouspage creator-developing-android.html
    \page creator-developing-baremetal.html
31
    \nextpage creator-developing-generic-linux.html
32 33 34 35 36 37 38 39 40 41

    \title Connecting Bare Metal Devices

    You can connect bare metal devices to a development host to run and debug
    applications on them from \QC using GDB or a hardware debugger. This enables
    you to debug on small devices that are not supported by the generic remote
    Linux device plugin. However, if the device does not have Qt libraries, you
    need a fake Qt installation.

    The bare metal device type accepts custom GDB commands that you specify in
42 43
    the device options. You can specify the commands to execute by default or
    the commands to execute when connecting to OpenOCD or ST-LINK Utility.
44 45 46 47

    To connect bare metal devices:

    \list 1
Tobias Hunger's avatar
Tobias Hunger committed
48 49 50
        \li Select \uicontrol Help > \uicontrol {About Plugins} >
            \uicontrol {Device Support} > \uicontrol {Bare Metal} to enable the
            Bare Metal Device plugin.
51 52 53

        \li Restart \QC to be able to use the plugin.

54
        \li Select \uicontrol Tools > \uicontrol Options > \uicontrol Devices >
55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79
            \uicontrol {Bare Metal} > \uicontrol Add > \uicontrol Default,
            \uicontrol OpenCD, or \uicontrol {ST-LINK Utility} to specify
            connections to GDB servers or hardware debuggers:

            \image creator-baremetal-device.png "Bare Metal options"

            \list 1

                \li In the \uicontrol {Startup mode} field, select the mode to
                    start the GDB server or debugger in. The available modes
                    depend on the server or debugger.

                \li In the \uicontrol Host field, select the host name and port
                    number to connect to the GDB server or hardware debugger.

                \li In the \uicontrol {Init commands} field, enter the commands
                    to  execute when initializing the connection.

                \li In the \uicontrol {Reset commands} field, enter the commands
                    to  execute when resetting the connection.

                \li Select \uicontrol Apply to add the GDB server or debugger.

            \endlist

Tobias Hunger's avatar
Tobias Hunger committed
80 81 82
        \li Select \uicontrol Tools > \uicontrol Options > \uicontrol Devices >
            \uicontrol Add > \uicontrol {Bare Metal Device} >
            \uicontrol {Start Wizard}:
83 84 85 86 87 88 89 90 91 92 93 94

            \list 1

                \li In the \uicontrol {GDB server provider} field, select a
                    GDB server or hardware debugger.

                \li Select \uicontrol Apply to add the device.

            \endlist

        \li Select \uicontrol Tools > \uicontrol Options >
            \uicontrol {Build & Run} > \uicontrol Kits > \uicontrol Add to add a
95
            kit for building applications and running them on bare metal devices:
96 97 98 99

            \image creator-baremetal-kits.png "Bare Metal Device kits"

            \list 1
100

101
                \li In the \uicontrol Name field, specify a name for the kit.
102

103 104
                \li In the \uicontrol {Device type} field, select
                    \uicontrol {Bare Metal Device}.
105

106 107
                \li In the \uicontrol Device field, select the bare metal device
                    for the kit.
108

109
                \li Select \uicontrol Apply to add the kit.
110

111
            \endlist
112

113 114
        \li Open a project for an application you want to develop for the
            device.
115

116
        \li Select \uicontrol Projects > \uicontrol {Build & Run}, and then
117
            select the kit for building the application and running it on the bare
118
            metal device specified in the kit.
119

120
            \image creator-baremetal-kit-for-project.png "Adding a bare metal kit for a project"
121

122
        \li Select \uicontrol Run to specify run settings.
123 124 125 126 127 128

            Usually, you can use the default settings.

    \endlist

*/