Select the version of your OS from the tabs below. If you don't know the version you are using, run the command cat /etc/os-release
or cat /etc/issue
on the board.
Toradex offers a VS Code extension to help users to develop, deploy, and debug applications on TorizonCore. The following programming languages are currently supported:
This article demonstrates how to set up the recommended configuration comprising:
This article complies to the Typographic Conventions for Torizon Documentation.
Development Computer with
One of the OS below:
Toradex Computer on Module (CoM) with TorizonCore installed.
Note: Make sure that the board and development computers are on the same network.
Attention: The SDK Build will not work if buildkit
is enabled in Docker.
When buildkit
is enabled you can't reference local images. This prevents multi-stage builds or Dockerfile referencing a local image from working. Toradex SDK uses a container that is generated on the fly and kept on the local machine and this fails with buildkit
enabled.
To fix that, please disable buildkit on the local Docker installation by or removing it from your Docker daemon configuration file at "features" section, or setting its value to false.
The latest version of the Toradex Torizon Support extension can be found on the Visual Studio Code marketplace:
Click on the extensions button in Visual Studio Code as shown in the image below and search for Toradex Torizon Support:
Verify that the extension has been enabled:
Choose your development PC OS from the tabs below:
Warning: Required for .NET Core applications only
Download the latest .NET Core SDK on Microsoft Official Website and follow the setup installation. To check if everything went well, open up a command prompt, and run the following command:
$ dotnet
If the installation was successful, you should see the .NET options on the command prompt.
To obtain the Linux subsystem, please refer to the Microsoft instructions. After following all the steps, reboot your machine.
Warning: WSL2 requires Windows 10, updated to version 2004 (also known as the Windows 10 May 2020 Update) or higher.
WSL Setup Video
You may want to install Windows Terminal from the Microsoft Store to improve your experience using wsl.
Open the Microsoft Store and install a distro. We recommend Ubuntu 18.04 LTS. When the process ends, open CMD
and run the following command:
$ wsl
It will ask for your username
and password
, write it. After setting up your credentials, run the command below to see some information about the distro:
$ wslfetch
After evaluating the Windows Subsystem for Linux works, install rsync
and ssh
from the Linux prompt:
$ sudo apt-get update && sudo apt-get install rsync ssh
Check if Ubuntu 18.04 LTS is the default wsl distro on your system by running the command bellow:
$ wsl -l -v
Your default distro is represented by the *. If your output is similar to the one above (docker-desktop or another distro being the default), make Ubuntu default distribution by typing the following command:
$ wsl -s Ubuntu-18.04
Warning: Required for .NET Core applications only
Follow the .NET Microsoft Documentation to install it on Linux, and make sure you select the correct distribution on the left.
You can test if everything went well by running the following command:
$ dotnet --info
The VS Code extension needs ARM emulation mode enabled through binfmt. To allow it, press F1 and type "Torizon: Enable ARM emulation for Docker containers":
Click on continue in the following window:
If everything goes well, you should see the ARM emulation enabled
message in your Visual Studio Code.
To debug and test our application, we need a device to deploy it. Open Visual Studio Code and press F1 to open the command bar, then you can run one of two commands below to add a device connected over the network or over serial.
The command torizon.detectSerialDevice
will add a serial connection to a Torizon device. The interface will prompt to specify the port on your development PC connected to the device over serial.
The command torizon.detectNetworkDevice
will add a network connection to your Torizon device. The interface will request to specify the IP address of your Torizon device. Just make sure that your SoM is on the same network as your development PC, and your PC can reach this address.
Either way, you will then be prompted to enter a valid username and password that is on your Torizon device; this will make it briefly reboot. You should see some dialog in the Terminal
output of the VS code that shows whether the connection was a success or not. Also, if you’ve already created a Torizon Project, then the device will be listed via the Torizon extension sidebar menu.
Expected Result:
On Visual Studio Code, executing command is easy: you need to press F1 to open the command bar then type the command you want. Here is a list with every command and its respective action and category
Command | Action | Category |
---|---|---|
torizon.createPythonApp | Create Python Application | Torizon/Python |
torizon.createDotNetCoreApp | Create .NET Core Application | Torizon/.NET |
torizon.createAspDotNetCoreApp | Create ASP.NET Application | Torizon/.NET |
torizon.detectSerialDevice | Detect device via serial port connection | Torizon |
torizon.detectNetworkDevice | Detect device via network connection | Torizon |
torizon.deleteDevice | Remove device from device list | Torizon |
torizon.selectDevice | Select default deployment device | Torizon |
torizon.buildPythonReleaseContainer | Build release container for Python application | Torizon/Python |
torizon.enableARMEmulation | Enable ARM emulation for docker containers | Torizon |
torizon.deployReleaseContainer | Deploy release container | Torizon |
torizon.runReleaseContainer | Run/restart release container | Torizon |
torizon.updateContainers | Download/update base containers | Torizon |
torizon.buildDotNetReleaseContainer | Build release container for .NET application | Torizon/.NET |
config.yaml
in the appconfig_0 folder. See Moses IDE Backend for reference.Visual Studio Code related-webinars that you can watch on-demand.
Toradex offers a VS Code extension to help users to develop, deploy, and debug applications on TorizonCore. The following programming languages are currently supported:
This article demonstrates how to set up the recommended configuration comprising:
This article complies to the Typographic Conventions for Torizon Documentation.
Development Computer with
One of the OS below:
Toradex Computer on Module (CoM) with TorizonCore installed.
Note: Make sure that the board and development computers are on the same network.
The latest version of the Toradex Torizon Support extension can be found on the Visual Studio Code marketplace:
Click on the extensions button in Visual Studio Code as shown in the image below and search for Toradex Torizon Support:
Verify that the extension has been enabled:
Choose your development PC OS from the tabs below:
Warning: Required for .NET Core applications only
Download the latest .NET Core SDK on Microsoft Official Website and follow the setup installation. To check if everything went well, open up a command prompt, and run the following command:
$ dotnet
If the installation was successful, you should see the .NET options on the command prompt.
To obtain the Linux subsystem, please refer to the Microsoft instructions. After following all the steps, reboot your machine.
Warning: WSL2 requires Windows 10, updated to version 2004 (also known as the Windows 10 May 2020 Update) or higher.
Open the Microsoft Store and install a distro. We recommend Ubuntu 18.04 LTS. When the process ends, open CMD
and run the following command:
$ wsl
It will ask for your username
and password
, write it, and re-run the command to see the following output:
After evaluating the Windows Subsystem for Linux works, install rsync
and ssh
from the Linux prompt:
$ sudo apt-get update && sudo apt-get install rsync ssh
Warning: Required for .NET Core applications only
Follow the .NET Microsoft Documentation to install it on Linux, and make sure you select the correct distribution on the left.
You can test if everything went well by running the following command:
$ dotnet --info
The VS Code extension needs ARM emulation mode enabled through binfmt. To allow it, press F1 and type "Torizon: Enable ARM emulation for Docker containers":
Click on continue in the following window:
If everything goes well, you should see the ARM emulation enabled
message in your Visual Studio Code.
To debug and test our application, we need a device to deploy it. Open Visual Studio Code and press F1 to open the command bar, then you can run one of two commands below to add a device connected over the network or over serial.
The command torizon.detectSerialDevice
will add a serial connection to a Torizon device. The interface will prompt to specify the port on your development PC connected to the device over serial.
The command torizon.detectNetworkDevice
will add a network connection to your Torizon device. The interface will request to specify the IP address of your Torizon device. Just make sure that your SoM is on the same network as your development PC, and your PC can reach this address.
Either way, you will then be prompted to enter a valid username and password that is on your Torizon device; this will make it briefly reboot. You should see some dialog in the Terminal
output of the VS code that shows whether the connection was a success or not. Also, if you’ve already created a Torizon Project, then the device will be listed via the Torizon extension sidebar menu.
Expected Result:
On Visual Studio Code, executing command is easy: you need to press F1 to open the command bar then type the command you want. Here is a list with every command and its respective action and category
Command | Action | Category |
---|---|---|
torizon.createPythonApp | Create Python Application | Torizon/Python |
torizon.createDotNetCoreApp | Create .NET Core Application | Torizon/.NET |
torizon.createAspDotNetCoreApp | Create ASP.NET Application | Torizon/.NET |
torizon.detectSerialDevice | Detect device via serial port connection | Torizon |
torizon.detectNetworkDevice | Detect device via network connection | Torizon |
torizon.deleteDevice | Remove device from device list | Torizon |
torizon.selectDevice | Select default deployment device | Torizon |
torizon.buildPythonReleaseContainer | Build release container for Python application | Torizon/Python |
torizon.enableARMEmulation | Enable ARM emulation for docker containers | Torizon |
torizon.deployReleaseContainer | Deploy release container | Torizon |
torizon.runReleaseContainer | Run/restart release container | Torizon |
torizon.updateContainers | Download/update base containers | Torizon |
torizon.buildDotNetReleaseContainer | Build release container for .NET application | Torizon/.NET |
config.yaml
in the appconfig_0 folder. See Moses IDE Backend for reference.