Skip to content

elkrem/HDLC

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

HDLC

Simple HDLC library using NodeJS.

Installation

$ npm install HDLC

Usage

import HDLC

import { HDLC } from "hdlc";
const hdlc = new HDLC();

Initialize

hdlc.init(sendbyte);
hdlc.eventEmitter.on('newFrame', router);

function sendbyte(data) {
  console.log(data);
}

function router(frame) {
  console.log(frame);
}

To send

hdlc.sendFrame(messageBytes);

To receive

hdlc.byteReceiver(messageFrame);

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published