Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

teltonika-parser-ex

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

teltonika-parser-ex

Parsing teltonika binary data from device FMB0XX. Right now supported Codec8, Codec8 Extended and Codec7 format, Codec 16 yet in process.

  • 0.0.16
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

README

Parsing teltonika binary data from device FMB0XX. Right now supported Codec8, Codec8 Extended and Codec7 format, Codec 16 yet in process.

Source

Forked from: https://www.npmjs.com/package/teltonika-parser

Installation

Run console command

npm i teltonika-parser-ex

Usage example

 const Parser = require('teltonika-parser-ex');
 const binutils = require('binutils64');


 let server = net.createServer((c) => {
     console.log("client connected");
     c.on('end', () => {
         console.log("client disconnected");
     });

     c.on('data', (data) => {

         let buffer = data;
         let parser = new Parser(buffer);
         if(parser.isImei){
             c.write(Buffer.alloc(1, 1));
         }else {
             let avl = parser.getAvl();

             let writer = new binutils.BinaryWriter();
             writer.WriteInt32(avl.number_of_data);

             let response = writer.ByteBuffer;
             c.write(response);
         }
     });
 });

 server.listen(5000, () => {
     console.log("Server started");
 });

Keywords

FAQs

Package last updated on 22 Oct 2020

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

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc