Skip to content

Update vscode.md to instruct Windows users to install GNU Make + inst… #410

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Feb 22, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 18 additions & 1 deletion docs/tutorials/debug/vs_code.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
## Visual Studio Code

This document explains how to build and debug Arm Mbed OS applications using Visual Studio Code. Before starting, first [configure your local debug toolchain](/docs/v5.6/tools/setting-up-a-local-debug-toolchain.html).
This document explains how to build and debug Arm Mbed OS applications using Visual Studio Code. Before starting, first [configure your local debug toolchain](/docs/v5.7/tools/setting-up-a-local-debug-toolchain.html).

Also install [GNU Make](https://www.gnu.org/software/make/) or [Mbed CLI](/docs/v5.7/tools/arm-mbed-cli.html) to build the project.

### Installing Visual Studio Code

Expand Down Expand Up @@ -69,3 +71,18 @@ To configure the debugger for your project:
<span class="images">![](https://s3-us-west-2.amazonaws.com/mbed-os-docs-images/vscode5.png)<span>Running the debugger</span></span>

<span class="tips">**Tip:** You can use the Debug Console to interact with the device over GDB and use functionality the UI does not expose. For example, to see the registers, type `-exec info registers`. To put a watch on a memory location, type `-exec watch *0xdeadbeef`.</span>

### Building with Mbed CLI

Visual Studio Code uses `make` to build your application by default. You can also build with Mbed CLI. To do this:

1. In `.vscode/tasks.json`, replace every instance (4 times) of `make` with `mbed`.
1. In `.vscode/tasks.json`, change `args` to:

```
"args": ["compile", "--profile=debug", "-t", "GCC_ARM", "-m", "YOUR_TARGET"],
```

1. In `.vscode/launch.json`, replace every instance (twice) of `make` with `mbed`.
1. In `.vscode/launch.json`, change `${workspaceRoot}/BUILD/` (twice) to `${workspaceRoot}/BUILD/YOUR_TARGET/GCC_ARM/`.
1. In `.vscode/launch.json`, change `${workspaceRoot}\\BUILD` to `${workspaceRoot}\\BUILD\\YOUR_TARGET\\GCC_ARM`.