Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>YW_E69New to Visual Studio Code? Get it now.
YW_E69

YW_E69

Thomas Chong

|
214 installs
| (0) | Free
Direct BLE Pybricks connector for VS Code: connect to hubs, download, run, stop, stream output, and inspect battery telemetry without pybricksdev.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

YW_E69

YW_E69 is a rebuilt Visual Studio Code extension for working with LEGO hubs that run Pybricks firmware. It connects directly to the hub over Bluetooth Low Energy from the VS Code extension host and does not use pybricksdev as a runtime dependency.

The extension is focused on a compact edit, download, run, stop, and inspect workflow for Pybricks Python programs.

Features

  • Direct Pybricks BLE connection using the Pybricks GATT service.
  • Configured hub quick connect from the VS Code status bar.
  • Disconnect command when a hub is connected.
  • Download the active .py editor file to hub slot 0.
  • Run the active .py editor file after compiling and downloading it.
  • Stop a running user program while keeping the hub connected.
  • F10 toggles Run or Stop based on the current Pybricks running status.
  • Program stdout is streamed to the Pybricks Connector output channel.
  • Battery telemetry command reads voltage, current, and charger status through the Pybricks REPL path.
  • Status bar actions adapt to connection and program state.
  • Settings button opens the VS Code settings page filtered to this extension.
  • Local imported Python modules from the same project folder are packaged with the entry file as a multi-mpy program whose first module is __main__.

Requirements

  • A LEGO SPIKE or Technic hub running Pybricks firmware.
  • A Bluetooth Low Energy adapter available to VS Code on the local machine.
  • A compatible MicroPython compiler for Pybricks programs:
    • Recommended: mpy-cross-v6.1
    • Install example: py -m pip install mpy-cross-v6.1
    • Alternatively set MPY_CROSS to a compatible mpy-cross executable path before starting VS Code.

This extension owns its Pybricks BLE and download implementation. It does not shell out to pybricksdev.

Status Bar Workflow

When no hub is connected, the status bar shows:

  • Connect Hub
  • Open Output
  • Settings

After a hub connects, the status bar shows:

  • Disconnect Hub
  • Download Program
  • Run Program
  • Battery Info
  • Open Output
  • Settings

When a user program is running, Run Program is replaced by Stop Program.

Commands

Command Description
Pybricks: Connect Hub Connect to the configured Pybricks hub name, or the first hub found when the name is empty.
Pybricks: Disconnect Hub Disconnect from the currently connected hub.
Pybricks: Download Program Compile and download the active Python file without starting it.
Pybricks: Run Program Compile, download, and start the active Python file.
Pybricks: Stop Program Stop the currently running user program and keep BLE connected.
Pybricks: Run or Stop Program Run when idle, stop when a program is running. Bound to F10.
Pybricks: Battery Info Read battery voltage, current, and charger status.
Pybricks: Open Output Open the Pybricks Connector output channel.
Pybricks: Open Settings Open VS Code settings filtered to this extension.

Settings

Setting Default Description
pybricksConnector.hubName test Hub name filter used by Connect Hub. Leave empty to connect to the first Pybricks hub found.
pybricksConnector.programPath Test_program/main.py Fallback Python program path used when no Python file is active in the editor.
pybricksConnector.scanTimeoutMs 15000 Bluetooth scan timeout in milliseconds.

Program Packaging

The active editor file is compiled and downloaded as __main__. Local .py modules imported from the same project folder are compiled and included in the same multi-mpy package.

For example, if main.py imports Movement_v4, the extension packages both modules before writing the user program to the hub.

Battery Information

Pybricks status events expose warning flags such as low voltage and high current. They do not expose a precise battery percentage.

The Battery Info command starts the Pybricks REPL temporarily and reads:

  • hub.battery.voltage()
  • hub.battery.current()
  • hub.charger.status()

The extension stops the REPL after the reading and keeps the hub connected.

Notes

  • Download and run currently target hub slot 0.
  • Download Program and Run Program use the active .py editor file. If no Python editor is active, the extension falls back to pybricksConnector.programPath.
  • Native BLE dependencies can depend on the local VS Code, Node, Electron, and operating system environment.
  • This version is a full rebuild of the previous extension behavior and should be treated as a new BLE-based implementation under the existing Marketplace identifier.
  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2026 Microsoft