Skip to content

probe-web / @probe-web/client / index

index

@probe-web/client — the headless probe-rs SDK for browsers (and Node over WebSocket). One API, two transports: a native probe-rs serve over WebSocket, or probe-rs itself compiled to wasm inside a Web Worker over WebUSB. Wire types are generated from the probe-rs RPC schema (./wire).

Start with Client.connect (or openSession, which also picks a probe and attaches), then use the Session to flash, monitor and debug.

Example

ts
import { Client } from '@probe-web/client';

const client = await Client.connect({ kind: 'websocket', url: 'ws://127.0.0.1:3000', token: 'secret' });
const [probe] = await client.listProbes();
const session = await client.attach({ probe, chip: 'MCXA153', protocol: 'Swd' });
const bootInfo = await session.flash({ image: '/firmware/app.elf', format: 'elf' });
await session.monitor(bootInfo, (ev) => { if (ev.kind === 'text') console.log(ev.text); });
client.close();

Classes

Interfaces

Type Aliases

Variables

Functions

References

Wire

Renames and re-exports wire