deno_serial icon indicating copy to clipboard operation
deno_serial copied to clipboard

Serialport API for Deno.

Deno SerialPort

Tags License Sponsor

Serial Port API for Deno with zero third-party native dependencies.

Platform getPorts open
Windows
macOS
Linux

Try out

Run the following to list all available ports:

deno run --unstable --allow-ffi -r https://raw.githubusercontent.com/DjDeveloperr/deno_serial/main/examples/print_ports.ts

NOTE: Not yet published to deno.land/x as not all platforms are supported yet.

Usage

import { getPorts, open } from "https://deno.land/x/[email protected]/mod.ts";

const ports = getPorts();
console.log("Ports:", ports);

const port = open({ name: ports[0].name, baudRate: 9600 });

// ...

port.close();

License

Apache-2.0. Check LICENSE for more information.

Copyright © 2022-2023 DjDeveloperr