Prepare the bridge host
The bridge host must run Linux or macOS. On it:- Install Embedder. The bridge ships with it.
- Connect the board, the debug probe and any instruments.
-
Install the device drivers, and give the account that runs the bridge access to the USB serial ports and probes. A bridge started with
embedder bridge startruns as your user. On Linux, the installed service runs as theembedder-bridgesystem user, which the installer adds to thedialoutandplugdevgroups; check that your probes’ udev rules let that user or group open them. -
Install the flashing tools your board needs, probe-rs, OpenOCD or both:
On macOS, run
brewas your normal user, not withsudo. On Linux, the installed service can’t run programs from your home folder. Aftercargo install, copy probe-rs to a system folder:
Install a persistent bridge
To claim a bridge, you need an owner or admin role in the team that will own it. Other members see the bridges shared with their teams but can’t claim them.1
Install the service
On the bridge host, install and start the bridge service:The command ends with
Bridge installed and running.2
Read the setup code
Once the service connects to Embedder, read its setup code on the bridge host:
- macOS
- Linux
3
Claim the bridge
In the Embedder app, choose Benches in the sidebar, then choose Add bridge. Enter the Setup code and a Name. If you manage more than one team, choose the Owner team. Then choose Claim bridge.The bridge appears in the list and shows Online within a few seconds. Then select it in a session.
setup-code file doesn’t exist yet, check the service log. On macOS, read /usr/local/var/log/embedder-bridge.log. On Linux, run sudo journalctl -u embedder-bridge -n 50. Confirm the host can connect to Embedder, then read the file again.
The installer accepts --state-dir <path> and --bin-dir <path>. If you used --state-dir, read setup-code from that directory instead.
The service keeps running after you close the terminal and starts again when the host boots. Keep the host powered, online and connected to the board.
On macOS, keep a user logged in on the host after a reboot. Some vendor probe tools can reach USB only from a logged-in session.
Share the bridge with other teams
On the Benches page, choose + (Add team) on the bridge’s row and pick a team. Members of that team can then select the bridge in their sessions. Choose the remove control beside a team to take its access away. Who can change a bridge:Pair a bridge on your network
Pairing connects your workstation directly to a bridge on the same network. You don’t claim it in the Embedder app.-
On the bridge host, start the bridge:
It prints
Bridge running on 0.0.0.0:4849with its process ID, and keeps running in the background. -
On your workstation, find the bridge:
-
On the bridge host, generate a pairing code. With the default installation paths:
The code is valid for two minutes and works once.
-
On your workstation, pair with the discovered name or the host address, using the code:
If you leave out
--code, the command asks for it. If discovery finds nothing, pair directly with the host’s address and port4849. -
Compare the fingerprint printed after pairing with the one the host reports:
Select a bridge in a session
Select the bridge in each chat where you want to use it. In VS Code, run/bridge to open the Remote Bridges panel, then choose Select beside the bridge.
In the terminal UI, /bridge opens the Remote Bridges manager. Select a bridge on the Paired tab, scan the network for bridges on the Discover tab, or pair a new one. To select a bridge directly, run /bridge <name>, for example /bridge bench.
Chats without a selected bridge use the boards and ports attached to that computer.
The Remote Bridges panel lists claimed bridges your current team can use and bridges you paired from this workstation. A dot beside each bridge shows whether it’s connected or unreachable.
Bridge serial ports appear as bridge:<name>:<device>, such as bridge:bench:/dev/ttyACM0. Confirm the ports and target before you ask Embedder to flash:
Work through a bridge
Bridges installed with
embedder bridge install-service or started with embedder bridge start have instruments enabled. If Embedder reports that the bridge is not instrument-enabled, set instruments_enabled = true in the bridge’s config.toml on the host, then restart the bridge:
Describe the boards on a bridge host
Embedder chooses how to flash from the boards described in ahardware.toml file on the bridge host. Describe a board when Embedder can’t detect the target, or when you flash with OpenOCD. After Embedder flashes a target that isn’t described yet, it saves that target to the file.
Only the service can read its folder, so edit the service’s file with
sudo. If the bridge’s config.toml sets hardware_descriptor to another path, the bridge reads that file instead. The bridge reads the board file each time Embedder checks its hardware, so you don’t need to restart it.
Add a [[board]] table for the board:
- When the file describes several boards, Embedder asks for the chip name and flashes with probe-rs. To flash with OpenOCD, describe only that board in the file.
- Use the exact key names and values above. An unknown key makes the bridge ignore every board in the file. An invalid value, such as
stlinkinstead ofst-linkor aflashBasewithout0x, stops Embedder from finding any target on the bridge. - Boards that Embedder saves can include other keys, such as
serialPort. Leave them as they are.
Check a paired bridge
These commands check bridges you paired from this workstation:embedder bridge status reports whether each paired bridge is connected or unreachable. embedder bridge doctor checks the connection, serial ports, flashing tools and file transfer, and prints a fix for each failed check. Resolve missing tools or device permissions on the bridge host.
To run a command on a paired bridge, such as listing probes, use embedder bridge exec:
Stop or remove a bridge
Troubleshoot
- Benches isn’t in the sidebar, or Add bridge is missing: ask your Embedder administrator whether bridges are available for your organization, and whether you have an owner or admin role in a team.
sudo: embedder: command not found:sudomay not search the directory Embedder is installed in. Runsudo "$(command -v embedder)" bridge install-service.- Invalid or expired setup code: read the
setup-codefile again and enter the current code. - The bridge stays Offline: check that the service is running and the host can connect to Embedder. Check the service log.
- No bridge named “bench”: claim it on the Benches page or pair it with
embedder bridge pair. For a claimed bridge, check that your current team owns it or has access to it. - Discovery finds nothing: check that both machines are on the same network, then pair directly with
host:4849. - Pairing fails: generate a fresh code on the host and use it within two minutes.
- The fingerprint changed: confirm the change on the bridge host before you pair again.
- Serial ports or probes are missing: check USB cables, target power, host drivers and device permissions.
- Flashing tools are missing: install probe-rs or OpenOCD as described in Prepare the bridge host, then run
embedder bridge doctoragain. On Linux, use the commands on this page rather than thebrewcommand thatembedder bridge doctorsuggests. - Embedder finds no target, or ignores your boards: check the entries in the board file for misspelled keys or invalid values, or give Embedder the chip name.
- The bridge is not instrument-enabled: turn on instruments in the bridge’s configuration, as described in Work through a bridge.
- A command is rejected: the host may limit which programs the bridge can run. Ask the host’s administrator.