New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

@novastar/serial

Package Overview
Dependencies
Maintainers
1
Versions
18
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@novastar/serial

Serial binding for @novastar/codec

latest
Source
npmnpm
Version
2.1.0
Version published
Weekly downloads
44
340%
Maintainers
1
Weekly downloads
 
Created
Source

@novastar/serial

Serial binding for @novastar/codec.

Go to API documentation.

Installation

Using npm:

npm install --save @novastar/serial@next

or yarn:

yarn add @novastar/serial@next

Usage

import { Request } from '@novastar/codec';
import serial, { findSendingCards } from '@novastar/serial';

const [port] = await findSendingCards();
const session = await serial.open(port.path);
const readReq = new Request(1);
readReq.deviceType = DeviceType.ReceivingCard;
readReq.address = 0x02000001;
readReq.port = 0;
const { data: [value] } = await session.connection.send(readReq);

// Close all serial sessions
serial.release();

The search for connected devices is carried out by the VID/PID pair. At the initial stage, it contains a pair for MCTRL300: ['10c4', 'ea60']. Using the API, you can change the list of known devices.

Keywords

novastar

FAQs

Package last updated on 28 Oct 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts