Welcome to Visual Studio Code extension for Tizen
Visual Studio Code extension for Tizen (VS Code extension for Tizen) is a Visual Studio Code extension that enables you to develop Tizen .NET, Web and Native applications easily using Visual Studio Code. You can access most of its features by simply typing 'tizen' in the command palette.
Using VS Code extension for Tizen, you can:
- Create a project from templates.
- Edit code with IntelliSense.
- Build your project and get a Tizen application.
- Deploy your application to the device or emulator and run it.
- Debug your application.
- Remove your application from the device.
- Launch Tizen Studio tools.
Prerequisites
The following prerequisites apply to the VS Code extension for Tizen:
Supported host platforms
VS Code extension for Tizen supports the following operating systems:
- Windows 10 (64-bit)
- Ubuntu 18.04/20.04 (64-bit)
- macOS 10.15 (Catalina)/ 11 (Big Sur)
Required tools
To use VS Code extension for Tizen, you must install the following tools:
The following tools are required, but they can be installed from VS Code extension for Tizen if they are not already installed:
- Tizen Baseline SDK
- Tizen CLI (Tizen Core)
- Certificate Manager
- Emulator Manager
- Device Manager
- Package Manager
Required Visual Studio extensions
To use VS Code extension for Tizen, you must install the following extensions from the Visual Studio Marketplace:
- Microsoft "C#" extension for Visual Studio Code
- Microsoft "C/C++" extension for Visual Studio Code
Running VS Code extension for Tizen through VSIX Installation
To run VS Code extension for Tizen through VSIX installation:
On the release tab, download the latest vscode-tizen-csharp - x.x.x. vsix
release file.
Open Visual Studio Code.
On the Activity bar, click the Extensions icon (or press Ctrl + Shift + X).
The Extensions side bar opens.
On the Extensions side bar, click the ... (More) icon.
Select Install from VSIX.
Select the downloaded vscode-tizen-csharp - x.x.x.vsix
file.
Running VS Code extension for Tizen from Source
To run VS Code extension for Tizen from the source code:
Open the command line with Administrator privileges (for Windows®) or the terminal (for Linux) and move to the VS Code extension for Tizen source code directory.
Install the required npm packages in the directory using the npm install
command:
- On Windows®:
C:\Users\{home}\git\vscode-ext> npm install
- On Linux:
~/git/vscode-ext$ npm install
- On macOS:
~/git/vscode-ext$ npm install
If you have a permission problem when installing the npm packages, see Fixing npm permissions.
Open Visual Studio Code.
In the File menu, open the VS Code extension for Tizen source code directory.
In the Activity bar, select the Debug view, and press F5 or click Launch Extension.
Another Visual Studio Code instance opens, with VS Code extension for Tizen activated.
Packaging VS Code extension for Tizen from Source to vsix file
To package VS Code extension for Tizen from the source code:
Open the command line with Administrator privileges (for Windows®) or the terminal (for Linux) and move to the VS Code extension for Tizen source code directory.
Install the required npm packages in the directory using the npm install
command:
- On Windows®:
C:\Users\{home}\git\vscode-ext> npm install
- On Linux:
~/git/vscode-ext$ npm install
- On macOS:
~/git/vscode-ext$ npm install
If you have a permission problem when installing the npm packages, see Fixing npm permissions.
Package the extension and generate vsix in the current directory using vsce package
command:
- On Windows®:
C:\Users\{home}\git\vscode-ext> vsce package
- On Linux:
~/git/vscode-ext$ vsce package
- On macOS:
~/git/vscode-ext$ vsce package
vscode-tizen-csharp-x.x.x.vsix will be generated in the current directory.
Open Visual Studio Code, install extension using this VSIX and start using the extension.
When the VS Code extension for Tizen is run for the first time, it automatically installs a new Tizen Baseline SDK instance or sets the location of an already installed Tizen Baseline SDK(or Tizen Studio) instance.
If you want to install an additional Tizen Baseline SDK instance or change the Tizen Baseline SDK installation path, open the command palette and enter tizen install
or tizen set path
.
Using VS Code extension for Tizen
You can create and build a project, and deploy, run, and debug an application.
Creating Your First Tizen Project
To create a Tizen .NET project:
- Create an empty directory as the root directory for your Tizen project.
- In Visual Studio Code, open the directory.
- Open the command palette, and enter
tizen create
.
- Select Tizen: Create a new Tizen project.
- Select the relevant options from the subsequent quick pick lists.
- Define the project name.
Building Your Project
To build your project:
- Open the command palette, and enter
tizen build
.
- Select Tizen: Build a Tizen project.
- View the result in the Output window, and check the generated location for a package file with the
.tpk
or .wgt
extension.
Note
If you have a certificate for a Tizen device, create a certificate profile using the Tizen Certificate Manager before building your project.
Deploying and Running Your Application in the Emulator
To deploy and run your application:
- To launch the Tizen Emulator Manager, open the command palette and enter
tizen run
.
- Select Tizen: Launch Tizen Emulator Manager.
- In the Emulator Manager, create and launch an emulator instance.
- To deploy your application to the target, enter
tizen install
and select Tizen: Install a Tizen application on the Tizen device.
- To run the application on the target, enter
tizen run
and select Tizen: Run a Tizen application on the Tizen device.
Debugging Your Application in the Emulator
To debug your application:
Note
If an emulator is already running, skip steps 1, 2 and 3.
- To launch the Tizen Emulator Manager, open the command palette and enter
tizen run*
.
- Select Tizen: Launch Tizen Emulator Manager.
- In the Emulator Manager, create and launch an emulator instance.
- In the Activity bar, select the Debug side bar.
- In the Debug view, open the Configuration drop-down box and select Add Configuration.
- In the command palette list, select the right configuration according to the project type.
- To start the debugging session, press F5.