Merge pull request #1146 from Gator96100/master

J-Link debugging
This commit is contained in:
Philippe Teuwen
2020-12-30 01:01:25 +01:00
committed by GitHub
15 changed files with 464 additions and 165 deletions

View File

@@ -0,0 +1,72 @@
# Visual Studio Code for debugging
Download and install [Visual Studio Code](https://code.visualstudio.com/)
Download and install [J-Link Software and Documentation pack](https://www.segger.com/downloads/jlink)
## Debian / Ubuntu / Kali / ParrotOS / Raspbian
Install dependencies
```sh
sudo apt-get install --no-install-recommends binutils-arm-none-eabi gdb openocd gdb-multiarch
```
On some systems `arm-none-eabi-gdb` was replaced with `gdb-multiarch`. In order to use the J-Link debugger you need to link `arm-none-eabi-gdb` to `gdb-multiarch`:
```sh
ln -s /usr/bin/gdb-multiarch /usr/bin/arm-none-eabi-gdb
```
Setup the Visual Studio Code configuration, by going into your project folder and run:
```sh
./.vscode/setup.sh
```
now launch Visual Studio Code and open your project folder
## Windows: WSL
Enter WSL prompt (`wsl` or `start windows terminal`)
Install dependencies
```sh
sudo apt-get install --no-install-recommends binutils-arm-none-eabi gdb openocd gdb-multiarch
```
The J-Link debugger requires `arm-none-eabi-gdb` which was replaced with `gdb-multiarch`. In order to use the J-Link debugger link `arm-none-eabi-gdb` to `gdb-multiarch`:
```sh
sudo ln -s /usr/bin/gdb-multiarch /usr/bin/arm-none-eabi-gdb
```
Setup the Visual Studio Code configuration, by going into your project folder and run:
```sh
./.vscode/setup.sh
```
and launch Visual Studio Code
```sh
code .
```
## Windows: ProxSpace
Download and install [Visual Studio Code](https://code.visualstudio.com/)
Download and install [J-Link Software and Documentation pack for Windows](https://www.segger.com/downloads/jlink/JLink_Windows.exe)
Enter PorxSpace (`runme64.bat`) and enter your project folder.
Setup the Visual Studio Code configuration, by running:
```sh
./.vscode/setup.sh
```
now launch Visual Studio Code and open your project folder
_note_
Please install the recommended Visual Studio Code extensions in order for debugging to work.

View File

@@ -149,18 +149,3 @@ Note that it may take a quite long time for a freshly plugged Proxmark3 to be vi
Now you're ready to follow the [compilation instructions](/doc/md/Use_of_Proxmark/0_Compilation-Instructions.md).
## Color text on windows 10
In later versions of windows 10 you may be able to get color to work by setting this registry key
```
[HKEY_CURRENT_USER\Console]
"VirtualTerminalLevel"=dword:00000001
```
You also need to disable "use legacy console" in the cmd.exe properties, or set the following registry key
```
[HKEY_CURRENT_USER\Console]
"ForceV2"=dword:00000001
```
After making these changes, you will need to start a new command prompt (cmd.exe) to ensure its using the new settings.
If after making these changes (and restarting proxmark3.exe) you get extra characters and no color text, set either key to 0 or enable legacy mode again (and restart the command prompt).