Wykres commitów

81 Commity (cbab4b1e34b91622ae0bd879f540a66bc0d9b9c1)

Autor SHA1 Wiadomość Data
Victor Mayoral Vilches b548f66967 Fix memory config for STM32F4
The previous memory map didn't allow to debug the whole flash
memory. A new configuration has been added and should be
used while working with the STM32F4Discovery.
2014-09-30 11:54:56 -07:00
Rene Hopf 8f97b230fc gdb server fix, indentation 2014-08-15 10:44:24 +02:00
mux e12842b492 Send F4 memory-map and features for STM32F429
* Fix issues #250 #196
2014-07-17 00:46:18 +02:00
Michael Pratt 3c3b02e83e gdbserver: use uglylogging logging
Rather than putting debug printing in #ifdef blocks, use the same
uglylogging framework used by core stlink code.

To support this, the *LOG() macros are moved into the uglylogging.h
header file, and always use the filename as the logging tag.
2014-07-12 13:23:24 -07:00
Michael Pratt 3b443dc1c8 Reindent all source files
The indentation of various st-link source files is highly inconsistent.
Reindent all source files to 4 space indentions for consistency.

I went with 4 space indentations, as it was the most common style.
2014-07-09 22:56:36 -07:00
Olivier Croquette 788d2df772 Include signal.h to define SIGINT
Fix build error with MinGW
2014-05-19 10:40:52 +02:00
Sean Simmons 94c7ac86dc * Improved support for STM32L152RE - flash/ram sizes, now correct, flash programming works.
* Cleaned up checking of FP_CTRL register in gdb-server.c
* Added source code for stm32lx.s flashloader - just for reference.
2014-03-08 11:21:16 -05:00
Jonas Norling a4ff7ba1f4 Remove unsupported --device option to st-util
Setting the STLINK device with -d hasn't worked for some time, but
the STLINK_DEVICE environment variable works instead. Remove the
option, update documentation and help text.
2014-01-22 22:51:21 +01:00
Olivier Gay 3652f98a5d Fix all compilation warnings 2013-10-27 17:07:01 +01:00
Olivier Gay c02a84641c Restore gdb-server cleanup handlers for MinGW
There were removed in my previous commit 5851dee due
to compilation errors. It actually appears these signals
are supported in MinGW but there was an include error for
MinGW, this commit fixes it.
2013-10-27 16:17:09 +01:00
Olivier Gay 5851dee3cd Fix build issues with MinGW
Remove st-term from the list of the targets for MinGW.
st-term uses termios and would require a rewrite to have
it compile on MinGW. Also remove cleanup signal handlers
in gdb-server for MinGW to compile.
2013-10-27 15:32:43 +01:00
htk e886396e0e Support for reading target voltage 2013-09-30 01:51:26 +02:00
Maxime Vincent 57700499f1 Fixed the DEBUG switch in gdb-server.c 2013-09-01 09:23:19 +02:00
Michael Pratt 596fb35916 Add option to not reset board on connect
'-n' in st-util will cause it to skip the reset step, and thus allow you
to begin debugging at whatever point the code may currently be at.

Adding this feature required changing the stlink_open functions to
accept a reset flag that tells them whether or not to reset after
connecting.  Skipping reset does not seem to have any adverse effects on
stlink usb devices.  Unfortunately, I have to stlink v1 devices to test.
2013-08-18 14:44:58 -04:00
Jack Peel 04c142c69b Add SIGTERM signal handler to also call cleanup
When stopping st-util under Eclipse as an external tool the st-util
	receives a SIGTERM signal, and would not return the device to
	usb mass storage mode.  This change now calls cleanup in the SIGTERM handler too!!
2013-04-05 17:55:19 -07:00
Fabien Le Mentec 8df5b3be5e [ update ] bind gdb server on INADDR_ANY, as requested by thomas@popp.ws 2013-04-01 15:36:52 -05:00
Michael Pratt 2216d28452 Add SIGINT handler for stlink cleanup
SIGINT causes st-util to immediately exit, without closing the open
stlink.  This leaves devices (at least the F4 Discovery) in a state
where they are unable to reset.  st-util could still connect and control
them, but a power cycle was required before they could reset on their
own.

A signal handler is added for SIGINT, which performs cleanup and closing
of the open stlink device, allowing it to function normally on
disconnect.
2013-03-06 16:34:32 -05:00
Michael Pratt 4d1ee4d97e Move persistence flag to st_state_t
It makes sense for it to be with all other state data.  This meant
passing the entire state struct into serve.
2013-03-06 14:23:17 -05:00
Michael Pratt 9bed540624 Add persistence support to gdb-server
When started with -m, or connected with 'target extended-remote', the
GDB server will not terminate upon disconnection from GDB, instead it
will begin listening for conenctions again.

Starting with extended-remote also has the advantage of allowing 'run'
to be used to reset the target and begin again.  Unfortunately, 'start'
is not working properly, as it does not send a reset packet (R), so it
complains when it tries to access memory before it is connected to the
target.
2013-03-06 12:52:12 -05:00
Michael Pratt 3569970998 Revert "[ merge ] patch from fischermi@t-online.de, GDB server endless loop"
This reverts commit 1c2828cc91.
2013-03-06 12:03:27 -05:00
Nicolas Schodet 44445dd7b0 Fix byte count when doing unaligned memory read, fix issue #127
- when start is adjusted, count should also be adjusted,
 - then, count is rounded to the next multiple of word size.
2013-02-12 19:38:46 +01:00
Fabien Le Mentec 1c2828cc91 [ merge ] patch from fischermi@t-online.de, GDB server endless loop 2012-12-27 07:00:46 -06:00
Fabien Le Mentec 08872f834d [ merge ] Andreas Seltenreich <uwi7@rz.uni-karlsruhe.de> patches 2012-11-25 09:50:44 -06:00
Jeff Kent ff1a7aa50b workaround for asserting nRST, issue "monitor jtag_reset" from gdb 2012-09-19 12:22:28 -05:00
Michael Pratt 684d76afa0 Fix watchpoint support
Setting of watchpoints was nested inside of a case statement, so it
would only run for that case, even though it supports all cases.
2012-08-19 12:19:25 -04:00
Michael Pratt c6274f026b Write to extra (FP, etc) registers from GDB
The extra registers added in my previous commit can now be modified from
within GDB.  Since the ST-LINK does not support accessing these
registers, a workaround was used from reading an writing to them.

That is, the Debug Core Register Selector Register (DCRSR) can be written
with the register requested, and it will be read/written to/from the
Debug Core Register Data Register (DCRDR).  The standard ST-LINK memory
access functions are used to make these accesses.

A target descriptor XML file is sent to GDB from the server, which tells
GDB which registers exist on the target.

This is only supported for the STM32F4, and has only been tested on the
STM32F4DISCOVERY.  I tested st-util on an STM32L-DISCOVERY and my
changes did not seem to interfere with its operation.
2012-07-09 01:00:53 -04:00
Michael Pratt b1e65ea367 Extra registers integration with GDB
The support for extra registers has been added to GDB.  Now all core
registers can be read from GDB.  Write support has not yet been added.
2012-07-08 23:04:35 -04:00
Michael Sparmann 5b6eb51bd2 Fix "monitor reset" gdb command being misinterpreted as "monitor resume"
by checking for the full word, not just the first two chars.
2012-07-03 15:10:07 +02:00
Tectu 105b293a15 fixed option bytes amount 2012-05-25 17:05:44 +02:00
Dave Murphy 620a63c3ed Merge branch 'master' into mingw 2012-05-14 12:35:30 +01:00
Dave Murphy 947c1409e3 cast to avoid pointer warning 2012-05-13 22:55:41 +01:00
Dave Murphy d02326726a fix signedness warning 2012-05-13 22:54:26 +01:00
Michael Pratt b61a06a8b7 Fixed issue #66 - Fixed the F4 memory map to include CCM RAM. https://github.com/texane/stlink/issues/66 2012-05-11 14:11:12 -04:00
Dave Murphy 2559ab0c30 use WSAStartup on windows, replace bzero with memset 2012-04-29 18:48:26 +01:00
Dave Murphy 7ed5be2963 build with mingw 2012-04-29 14:43:46 +01:00
Fabien Le Mentec 18d6fe4893 Get st-util ack'ing the monitor request. Responds to
monitor reset     -- reset the core
    monitor resume    -- get the core running but don't stop gdb executing commands
    monitor halt      -- halt the core
2012-02-01 16:05:46 -06:00
Karl Palsson f38ff8f912 Unify chipid naming convention.
Flag more duplicate variables that need to be removed/combined
2012-02-01 20:55:10 +00:00
Daniel O'Connor 5e5d1fa747 Use pkg-config to find libusb CFLAGS and LDFLAGS. 2012-01-31 16:49:45 +10:30
Uwe Bonnes 9c41193a16 Use stlink_r|w_debug32 for single word access in the gdbserver too 2012-01-19 13:47:23 +01:00
Friedrich Beckmann 8e5b2b51bf Added the library to the list of dependencies as in flash 2012-01-03 23:58:01 +01:00
Uwe Bonnes 7eb080490c Move reset/load_param in the open functions, as requested by Karl 2011-12-18 23:35:20 +01:00
Uwe Bonnes 82c638ed83 For gdbserver, use the same initialization sequence like for flashing 2011-12-18 21:44:40 +01:00
Karl Palsson 83a5eb2ed3 Merge branch 'tmaster' into future
This branch should work for F1 and F4 devices.  It has currently been tested
with F1 value line, (a VL discovery board) programmed via gdb via both an
stlinkv1 and an stlinkv2.

F4 has _not_ yet been tested on this branch

Conflicts:
	.gitignore
	doc/tutorial/tutorial.pdf
	example/blink/main.c
	gdbserver/Makefile
	gdbserver/gdb-server.c
	src/stlink-common.c
	src/stlink-common.h
	src/stlink-usb.c
2011-11-15 00:57:09 +00:00
Karl Palsson b55b75c3b9 Remove final reference to old sg/usb compilation flags 2011-11-14 23:01:03 +00:00
jnosky 768a70d321 Added code so gdbserver can fully support the STM32F4 variable page sizes
gdbserver can now upload up to 1MB projects to flash
2011-11-14 16:20:49 -05:00
Karl Palsson d019d3fc4f Turn down default logging level.
And remove dead/duplicate code that is included in the opening of the device
2011-11-14 04:11:10 +00:00
Karl Palsson 5a5d36fdc3 Move all the flash size mapping from gdb server into core.
All the device params like flash size and page size should all be in the core open routines, not
_only_ in the gdbserver.  (This should stop it from ending up duplicated in the core, and get rid of
some of the hacks that were turning up.  All of this is chip specific!)
2011-11-12 20:36:43 +00:00
Fabien Le Mentec 0ff09f90ce [merge] merge jnosky/master 2011-11-12 02:25:02 -06:00
Fabien Le Mentec 13c0da3bcc Merge branch 'jnosky/master' 2011-11-12 01:49:08 -06:00
Karl Palsson 6cc3375151 Merge branch 'master' of github.com:karlp/stlink 2011-11-11 22:59:44 +00:00