VS Code: Virtual Environments for Embedded Development with Conda

Developing for an embedded target means using a certain version of GNU compiler, debugger and other tools. The challenge gets bigger if working with multiple different tool chains and environments.

Conda in VS Code

Conda is package, dependency and environment management tool. While it is heavily used for Python and Data Science development, it is surprisingly working very well to set up and managing environments for embedded development. Conda is great for managing non-Python dependencies and setups.

Continue reading

VS Code: Importing pre-v2.13.0 MCUXpresso SDK Projects

In my previous article I showed how to import, build and debug MCUXpresso SDK projects in VS Code. In my lectures and labs we are using a robot based on the NXP Kinetis K22FX512 ARM Cortex-M4F microcontroller, and there is only the v2.13.0 SDK available.

INTRO Sumo Robot
Sumo Robot with K22FX512

The software on the robot uses the latest NXP MCUXpresso SDK v2.3.1. The he Eclipse based MCUXpresso IDE 11.8.0 works fine with all the 2.x SDKs, up to the latest 2.13.0 one.

Continue reading

VS Code: Building the Project

In a previous article I have imported an example project. Now I want to compile and build it.

Traditionally, the build action inside VS Code is somewhat hidden. There is a keyboard shortcut, but recent additions to VS Code making the build action more accessible.

Multiple ways to start a build in Visual Studio Code
Continue reading

VS Code: MCUXpresso SDK Repository

In a previous article I have installed the MCUXpresso extension and used the MCUXpresso Installer to install the necessary development tools.

In this article I’m going to import the SDK.

Import Repository in VS Code
Continue reading

VS Code: MCUXpresso Installer

VS Code is managing its extensions (see VS Code: MCUXpresso Extension). But to make it usable for embedded development, you need more tools: compiler, linker, debugger, libraries, build system, debug probe support, …

For the experts, this is not a big deal: you know where to get them, and you install them, as shown with another tutorial. But for a class full of students or newcomers to VS Code, this can be a a time consuming and daunting task.

To make the installation easier, NXP has released a ‘dependency checker and installer’ along with their VS Code extension, which makes the setup much easier and simpler.

MCUXpresso Installer
Continue reading

VS Code: Telemetry-free VSCodium

“There is no such thing as a free lunch.”

https://en.wikipedia.org/wiki/No_such_thing_as_a_free_lunch

And this applies to VS Code and many of its extensions. You agree to the licensing conditions, and you pay with your data.

VS Code source code is MIT licensed, but the binaries you can download and install have telemetry built in: you are giving Microsoft your usage data in return for using VS Code.

If you are concerned about this, and looking for free and libre open source binaries of VS Code, then have a look at MIT-Licensed VSCodium.

https://vscodium.com
Continue reading

VS Code: MCUXpresso Extension

In essence, VS Code is only a text editor, although with very nice features. An editor which can be enhanced with so called extensions. With the right set of extensions, VS Code can be specialized for web development, or even LaTeX documenting. Or as in the case of this article series, for embedded development.

Installed VS Code Extensions
Continue reading