Commit Graph

21 Commits

Author SHA1 Message Date
Denis Vygovskiy
e644a5b39a Baremetal: Add option to use gdb target "extended-remote"
This target is used by Black Magic Probe hardware gdb server.

Task-number: QTCREATORBUG-14102
Change-Id: Id2fc9646e8fe5b750f69ddf419d133718b3fb9a2
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
Reviewed-by: hjk <hjk@qt.io>
2019-05-14 10:57:05 +00:00
Denis Shienkov
a3790cc059 bare-metal: Add missed 'const' keywords
Change-Id: I109a4df799a06f11381a49a32bdd7a56c4d9dff1
Reviewed-by: hjk <hjk@qt.io>
2019-05-09 14:41:24 +00:00
Denis Shienkov
f57d43045b bare-metal: Return initializier lists instead of ctors
Change-Id: Ifc764130ca9c20f77ae1e1549fddba41a900150a
Reviewed-by: hjk <hjk@qt.io>
2019-05-08 12:33:01 +00:00
Denis Shienkov
dfb0f391dd bare-metal: Refactor the plugin code a bit more
* An include files and forward declarations are sorted in an
  alphabetical order.
* Used the 'final' keywords for the methods and classes which
  not should be overridden.
* Used the 'auto' and 'explicit' keywords more.
* A class members are initialized in an initializier list.

Change-Id: Ia74783e47aff92467d696d471760b5a97bca3d7a
Reviewed-by: hjk <hjk@qt.io>
2019-05-08 11:15:07 +00:00
hjk
6f37348b4c Replace static_casts by QOverload where possible
Mainly to get rid of the QProcess::finished deprecation warning.

Also adjust coding style in the surrounding connects when needed.

Change-Id: I12f9b248c7974b892c4a069356e578e80f8c59e9
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
2019-02-26 15:18:14 +00:00
Alessandro Portale
9d296cf1f1 BareMetal: Modernize
modernize-use-auto
modernize-use-nullptr
modernize-use-override
modernize-use-equals-default
modernize-use-using

Change-Id: Ia4e7f4e75a49357ca1b225f25af68a0480fba748
Reviewed-by: hjk <hjk@qt.io>
2018-11-06 05:50:35 +00:00
Orgad Shaneh
7d3a79c696 Utils: Purge asConst
Replace by qAsConst.

Change-Id: I3301366f73c066c86f08df7188d70dc3b613c55c
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2018-04-09 09:04:00 +00:00
Tobias Hunger
c330cf0679 Replace manual signal blocking/unblocking with QSignalBlocker
Change-Id: Ibb59fab4e37d045e506c5a8172b6f5cbb955b028
Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
2017-10-04 09:35:06 +00:00
Orgad Shaneh
0c6d5d6aed BareMetal: Fix crash on shutdown
Change-Id: I40c2381f5d70d57c8bb7b6d4727a5350a52eefc5
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
Reviewed-by: hjk <hjk@qt.io>
2017-03-23 07:47:42 +00:00
Orgad Shaneh
c82c742d8d BareMetal: Update device address when provider is changed
Change-Id: Id020328797c4ec9a739cbf5844f9c4a9acf363ff
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
2017-03-20 10:08:41 +00:00
Orgad Shaneh
d9a66a5406 BareMetal: Apply "static" pattern to GdbServerProviderManager
Change-Id: I7fe76b5912808ac0855ef09cd6d31afdf9225f6f
Reviewed-by: hjk <hjk@qt.io>
2017-03-17 08:51:12 +00:00
Tim Jenssen
2631ffabd5 Remove spaces in initializer lists
Format initializer lists code style like.

Change-Id: Ib82c235e4ba7dc75ee96a7abc0c47eff7b0a9013
Reviewed-by: hjk <hjk@qt.io>
2017-02-22 16:25:09 +00:00
Tobias Hunger
397e7f4843 Update License according to agreement with Free Qt Foundation
* Update files in src/plugins

Change-Id: Ia5d77fad7d19d4bb3498e78661982f68729adb22
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2016-01-19 15:57:01 +00:00
Denis Shienkov
7607fae2bf BareMetal: Use the Qt5 signal/slot connection syntax
Change-Id: Icb51db0fbd77bbaba913a16eb468b0edafa047bb
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
Reviewed-by: Tim Sander <tim@krieglstein.org>
2015-12-07 08:54:56 +00:00
Orgad Shaneh
c37193f884 BareMetal: Fix cloning of GDB server providers
Change-Id: Ie063ce3ab2caf5cf2ee709236db891e22bb9cc8b
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
Reviewed-by: Tim Sander <tim@krieglstein.org>
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
2015-11-18 12:22:51 +00:00
hjk
2847a02fec BareMetal: Modernize
C++11, Utils::TreeModel.

Change-Id: I0746693436c41fa6b0f02cb61a9cc99d4e6e3e64
Reviewed-by: Christian Stenger <christian.stenger@theqtcompany.com>
Reviewed-by: hjk <hjk@theqtcompany.com>
2015-04-27 08:42:28 +00:00
Leena
a8dd74c020 GDBServer: fix grammar and punctuation in messages
Change-Id: Icbcb658a9df0be53da4e16f411283a855e1bcdd7
Reviewed-by: hjk <hjk@theqtcompany.com>
2015-03-23 14:07:10 +00:00
Leena Miettinen
ac01185f5e BareMetal: use book-style capitalization for combobox items
Change-Id: Ia2f57eb721cd761ba7c71e58a9b37a3c3fbcc043
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
2015-03-17 08:21:01 +00:00
Leena Miettinen
31b3855a8c BareMetal: fix language in messages
Change-Id: Ic1c39dc3b7a9b45d8e96b1bd215f0379892730c4
Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
2015-03-16 12:49:37 +00:00
Orgad Shaneh
5dd11dc214 BareMetal: Support remote channel without port
e.g. "| vgdb"

Change-Id: Iedae02dab5bbb884d57604605597225fe9a262c2
Reviewed-by: Tim Sander <tim@krieglstein.org>
Reviewed-by: hjk <hjk@theqtcompany.com>
2015-02-10 08:01:57 +00:00
Denis Shienkov
165f008dce BareMetal: Allow to manage configurations of HW GDB servers
The user has only one possibility to setup of the remote GDB server
when a new device is created (or to modify it for existing device).
It is possible only in the host/port fields for connection to the
GDB server. It is a little inconvenient for the user. If the user
wants to use other configuration of the GDB server, then need every
time to edit the current configuration.

Improving this it is introduction a new concept with a new entity
named as "GDB server provider". Now to the device debugging purpose
the user can choose any of the GDB provider from the list (by analogy
with toolchain and so on). Each configuration of GDB provider is
created by the user manually on the new "GDB Server Provider" options
page. This can be made before or after creation of device.

A GDB server provider can work in three startup modes (depends on
implementation of concrete provider):

1) NoStartup mode.

This means that we do not want to startup a provider, we just trying
to connect to the already started GDB provider server. This mode uses
the TCP/IP connection with manually specifying of remote host and port.

2) StartupOnNetwork mode.

This means that we want to launch of the GDB provider automatically
before connect to it in process of remote debugging. This mode also
uses the TCP/IP protocol. In addition to it, a GDB provider can has
additional options which are contains a paths to provider executable
file, to configuration files and so on (it is depends on concrete
provider implementation). This mode (with NoStartup) covers about 90%
of usecase, and is supported by most set of the GDB server providers.

3) StartupOnPipe mode.

This is similar to StartupOnNetwork mode and we also automatically
starts the GDB server provider before debugging. But in this case is
used the Pipe mode instead of TCP/IP. Not each of the GDB provider
can support debugging via pipes.

This patch has concrete implementations for a following set of the
GDB server providers:

* "Default" provider which supports only the NoStartup mode.

* "Open On-Chip Debugger" (http://openocd.sourceforge.net/)
  provider which supports all modes.

* "STLinkUtil" (https://github.com/texane/stlink)
  provider which supports NoStartup and StartupOnNetwork modes.

Tested on Windows and Linux with:

* target HW: ARM Stm32F4Discovery board with HW debugger STLink-v2
* provider: OpenOCD v0.8.0 (tested on Windows and Linux)
* provider: STLink-Util (tested on Linux only)
* toolchain: ARM GCC v4.9.2
* debugger: GDB v7.8.1 (with Python support)
* QtCreator with QBS project

Task-number: QTCREATORBUG-13686
Change-Id: I59c775d91b0a4227d931188879850c536290e1ba
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@theqtcompany.com>
Reviewed-by: hjk <hjk@theqtcompany.com>
2015-01-06 15:04:47 +01:00