Skip to content
| Marketplace
Sign in
Visual Studio Code>Programming Languages>EdgeTX Dev KitNew to Visual Studio Code? Get it now.
EdgeTX Dev Kit

EdgeTX Dev Kit

Jeffrey Nwankwo

|
59 installs
| (0) | Free
Lua scripting toolkit for EdgeTX RC radio firmware — IntelliSense, diagnostics, simulation, script generation, and API search.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

EdgeTX Dev Kit 2.0

A VS Code extension for writing, diagnosing, deploying, and simulating EdgeTX Lua scripts — built for the RC community.

VS Code License

EdgeTX Dev Kit 2.0

EdgeTX Dev Kit brings a proper development environment to EdgeTX Lua scripting. If you've ever written a widget or telemetry script in a plain text editor, copy-pasted it to an SD card, flashed it to your radio, and stared at a blank screen wondering what went wrong, then this extension is for you.

It connects to auto-generated stubs from the EdgeTX source, gives you real IntelliSense for every API, catches mistakes before you ever touch your radio, deploys directly to your SD card on save — and now lets you run your scripts live in a built-in EdgeTX simulator, right inside VS Code.

Requirements

  • VS Code 1.85 or later
  • Lua Language Server (sumneko.lua) — installed automatically as a dependency

Upgrading from 1.x

⚠️ Action required if you're upgrading from a previous version.

Supported radio profiles have been updated in 2.0 and some radio IDs have changed. If you were on 1.x, your saved profile may no longer match a valid radio and the simulator or diagnostics may not work correctly.

Run EdgeTX: Set Radio Profile after upgrading to select your radio again and clear any stale profile data.

Getting Started

  1. Install the extension from the VS Code Marketplace
  2. Open a Lua file (or create a new one)
  3. Run EdgeTX: Toggle EdgeTX Mode from the command palette (Ctrl+Shift+P)
  4. Set your radio profile when prompted — select your EdgeTX version and display type
  5. Start writing

The extension activates automatically on any .lua file. EdgeTX mode (IntelliSense, diagnostics, API search) activates on top of that once you toggle it on or enable edgetx.autoActivateOnStart in settings.

Features

IntelliSense & Type Checking

The extension syncs versioned .d.lua stub files from the edgetx-lua-gen pipeline — a GitHub Actions workflow that parses EdgeTX C++ source and generates LuaLS-compatible definitions.

Once stubs are loaded, the Lua Language Server provides:

  • Autocomplete for all EdgeTX globals (lcd, model, system, getValue, etc.)
  • Parameter hints and type signatures on hover
  • Go-to-definition on any EdgeTX API
  • Version-aware types — APIs that changed between versions reflect the correct signature for your profile

Annotate your script with the correct type and LuaLS handles the rest:

---@type WidgetScript
local script = {
    name = "MyWidget",
    options = { { "Toggle", BOOL, 1 } },
    create = function(zone, options) return {} end,
    refresh = function(widget, event, touchState) end,
}
return script

Script Generation

Wizard

Run EdgeTX: New Script (Wizard) to open a guided webview that walks you through selecting a script type, EdgeTX version, and display type. The wizard generates a complete, annotated script template in the active editor.

Inline Shortcuts

In any .lua file with EdgeTX mode active, type ! at the start of a line to open the script picker, then select a script type and press Tab or Enter:

Shortcut Generates
!w Widget script
!t Telemetry script
!f Function script
!m Mix script
!o One-time script

The trigger text is replaced with a fully annotated script template. A formatter runs automatically if you have a Lua formatter (e.g. prettier) installed.

Diagnostics

The extension runs two layers of diagnostics on every save:

Structural checks

  • Missing return statement — warns if the file doesn't end with a return statement
  • Missing required fields — informs if the returned table is missing non-optional fields for the detected script type and version
  • Wrong field types — errors if a field is assigned the wrong type (e.g. a string where a function is expected)

These checks read the actual returned table via an AST parse (using luaparse). The extension understands all common script structures and not just table literals:

-- Inline table
return { name = "X", create = function() end }

-- Variable-initialized table
local script = { name = "X", create = function() end }
return script

-- Sequential assignment
local script = {}
script.name = "X"
script.create = function() end
return script

Widget-specific checks

  • name must be 10 characters or less
  • options maximum: 5 entries on EdgeTX ≤ 2.10, 10 entries from 2.11
  • Each option name (first table value) must be 10 characters or less with no spaces
  • Widget scripts are only available on color displays

Lint checks

  • Display-specific APIs — errors if you use color-only apis: lcd.setColor(), RGB(), COLOR_THEME_*, TINSIZE etc. on a B&W profile and vice-versa
  • Version-gated APIs — errors if you use an API that requires a newer version than your profile (e.g. touchState requires 2.6+)
  • Unsupported standard libraries — errors for os, coroutine, package, debug usage; table flagged on B&W profiles
  • Unsupported io functions — errors for any io.* call outside the five supported functions: io.open, io.close, io.read, io.write, io.seek
  • lcd unavailable in function scripts - errors when lcd is used in a function script
  • lvgl support - errors when lvgl apis is used in a wrong way or unsupported script types

API Search

Click the EdgeTX icon in the activity bar to open the API Search sidebar. Search across all functions and constants for your active EdgeTX version.

Clicking a result (functions only) inserts a snippet directly into the active editor at the cursor position.

You can also open API Search as a floating panel beside your editor via EdgeTX: Search API from the command palette or right-click context menu.

SD Card Deployment

Configure your SD card path once:

"edgetx.sdCardPath": "/Volumes/EdgeTX"

From that point, the extension knows where to deploy each script type based on the ---@type annotation:

Script type Target path
WidgetScript WIDGETS/{name}/
TelemetryScript SCRIPTS/TELEMETRY/
FunctionScript SCRIPTS/FUNCTIONS/
MixScript SCRIPTS/MIXES/
OneTimeScript SCRIPTS/TOOLS/

Widget scripts are deployed into a subfolder named after the name field in the returned table. If the name field can't be resolved, the filename is used as a fallback.

Auto-deploy on save:

"edgetx.autoDeployOnSave": true

When enabled, every save to a recognized EdgeTX Lua file copies it to the correct SD card location automatically. The status bar shows deploy status briefly after each deploy.

Manual deploy:

Run EdgeTX: Deploy Script to SD Card from the command palette or right-click menu to deploy the active file on demand.

Deploy guards:

Before deploying, the extension checks for errors in the current file. If blocking errors exist, you'll be prompted to confirm before proceeding.

If the SD card path doesn't exist or the card is ejected, you will be notified.

Simulator

EdgeTX Dev Kit 2.0

EdgeTX Dev Kit 2.0 includes a built-in simulator powered by the actual EdgeTX WASM firmware — the same firmware that runs on your radio, compiled to WebAssembly and running directly in VS Code. No EdgeTX Companion required.

Prerequisites: Set your radio profile (EdgeTX: Set Radio Profile) and SD card path (edgetx.sdCardPath) before using the simulator.

Opening the Simulator

Run EdgeTX: Open Simulator from the command palette to open the simulator panel. The panel shows the radio LCD display and, optionally, the full controls panel.

The WASM binary is downloaded and cached on first launch. Subsequent opens load instantly from disk and only re-download when a new firmware build is available.

Tip — high-resolution displays: Radios with large screens (such as the TX16S MK3 at 800 px wide) render at full firmware resolution. For the sharpest image, drag the panel splitter to widen the simulator, or drag the panel tab into a separate editor group to give it more space. Constraining the panel width causes the browser to downscale the WebGL canvas, which reduces clarity.

Controls Panel

Click Show Controls in the simulator header to reveal the full radio control set — dual gimbals with spring physics, switches, buttons, pots, sliders, and trim buttons. All inputs are wired to the live firmware; move a stick and the radio responds in real time.

Click Hide Controls to collapse the panel and focus on the display.

Controls

Simulate Script

With a widget or telemetry script open in the editor, run EdgeTX: Simulate Script (or right-click → Simulate Script).

The extension reads the ---@type annotation, deploys the script to the SD card, boots the simulator, and launches the script automatically — no menu navigation required.

  • Widget scripts — the widget is loaded and rendered on the main screen immediately after the firmware boots.
  • Telemetry scripts — the script is executed as a standalone Lua program and takes over the display.

Simulate Script

Simulate in a specific zone:

By default, widgets simulate at full-screen size. Add a ---@simulate annotation to target a specific layout and zone — useful when your widget is designed for a corner or half-screen slot:

---@type WidgetScript
---@simulate Layout2x2 zone=1

Valid layout names match the layouts available on your radio (e.g. Layout1x1, Layout2x2). If the annotation is absent or the layout isn't recognised, the widget falls back to the full main area.

Watch Script

Run EdgeTX: Watch Script to simulate with live reload. Every time you save the file, the extension automatically redeploys and restarts the simulation with your latest changes — no manual re-triggering.

A ● WATCHING badge appears in the simulator header while watch mode is active. Close the simulator panel to stop watching.

Watch Script Mode

Telemetry Streaming

Open the Telemetry panel in the simulator header to inject fake telemetry data into the running firmware at 10 Hz. Adjust values across five tabs:

Tab Sensors
Link 1RSS, 2RSS, Rqly, RSNR, RFMD, ANT, TPWR, TRSS, TQly, TSNR
GPS Lat, Lon, Alt, Sats, Hdg
Attitude Ptch, Roll, Yaw
Battery RXBt, Curr, Capa
Flight FM, VSPD

Toggle STREAMING on to start sending frames. Toggle it off to pause. Values persist for the session.

Telemetry

Persistence

Radio settings, model configuration, and any changes made during a simulation session are saved to disk and restored on the next boot. The simulated SD card state (models, scripts, settings) persists between sessions when using your configured SD card path.

Radio Profile

Run EdgeTX: Set Radio Profile to configure:

  • EdgeTX version — determines which stubs and API docs are loaded, and which version-gated diagnostics apply
  • Display type — color or bw or monochrome, used to flag display-specific API misuse
  • Radio name — shown in the status bar for quick reference

The active profile is shown in the status bar:

EdgeTX: tx16s • 2.12

Stub Sync

Stubs are fetched from a remote pipeline that tracks EdgeTX releases. On activation, the extension checks for stub updates silently in the background.

Run EdgeTX: Check for API Updates and Sync to force a manual sync.

SUPPORTED_MANIFEST_VERSION = 2

The base URL is configurable if you host your own stubs:

"edgetx.stubsRawBaseUrl": "https://raw.githubusercontent.com/JeffreyChix/edgetx-stubs/main"

Commands

All commands are available via Ctrl+Shift+P and prefixed with EdgeTX:. Most are also available in the right-click context menu when a Lua file is open.

Command Description
EdgeTX: Toggle EdgeTX Mode Enable or disable EdgeTX mode for the current workspace
EdgeTX: Set Radio Profile Configure your radio's EdgeTX version and display type
EdgeTX: New Script (Wizard) Open the guided script generation wizard
EdgeTX: New Widget Script Generate a widget script template in the active editor
EdgeTX: New Telemetry Script Generate a telemetry script template
EdgeTX: New Function Script Generate a function script template
EdgeTX: New Mix Script Generate a mix script template
EdgeTX: New OneTime Script Generate a one-time script template
EdgeTX: Search API Open the API search panel
EdgeTX: Deploy Script to SD Card Deploy the active script to the configured SD card path
EdgeTX: Check for API Updates and Sync Force a stub sync against the remote pipeline
EdgeTX: Open Simulator Open the EdgeTX simulator panel
EdgeTX: Simulate Script Simulate the active widget or telemetry script in the built-in simulator
EdgeTX: Watch Script Simulate with live reload — restarts the simulation automatically on every save

Extension Settings

Setting Type Default Description
edgetx.autoActivateOnStart boolean false Automatically enable EdgeTX mode on start if a Lua file is open
edgetx.autoDeployOnSave boolean false Deploy to SD card automatically on every save
edgetx.sdCardPath string — Absolute path to your EdgeTX SD card root — also used as the simulator filesystem
edgetx.checkUpdatesOnStart boolean true Check for stub updates when the extension activates
edgetx.stubsRawBaseUrl string GitHub raw URL Base URL for stub file hosting

Script Types

EdgeTX Dev Kit supports all five EdgeTX Lua script types:

Widget Script

Displayed in a zone on color LCD radios. Requires name, create, and refresh. Optional: options, update, background.

Telemetry Script

Displayed on a telemetry screen page. Has full LCD access. Requires run. Optional: init, background.

Function Script

Activated by a switch. Runs in the background. No LCD access. Requires run. Optional: init, background (from 2.4).

Mix Script

Custom mix that reads inputs and produces outputs. Requires run. Optional: input, output, init. Do not use for anything safety-critical.

One-Time Script

Runs once when activated. Useful for setup or configuration. Requires run. Optional: init.

Contributing

Found a bug or have a feature request? Open an issue with as much context as you can provide.

Pull requests are welcome. If you're planning something substantial, open an issue first to discuss the approach.

The stub pipeline lives in a separate repository — edgetx-lua-gen. If you spot missing or incorrect API definitions, contributions there improve the IntelliSense and diagnostics for everyone.

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2026 Microsoft