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

node-pirit-printer

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-pirit-printer

Pirit Printer COM Node.js API

  • 0.1.6
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
0
decreased by-100%
Maintainers
1
Weekly downloads
 
Created
Source

Pirit Printer Node.js API

Overview

Pirit is roll printer using for printing cash receipt.

For connection to working horses it use COM Port or USB Type A (USB use virtual COM Port driver to communicate with printer)

Install

$ npm i node-pirit-printer --save

Using

var connect = require('node-pririt-printer').connect;

connect(function(err, pirit) {
if (err) return console.error(err);
  pirit
    //wrote some text
    .writeLine("Оно может сцепляться")
    .writeLine("Можно напечатать много всего инетересного, но не по теме")
    .writeLine("Ножик будет резать неправильно, если не отмотать 4 или 8 строк перед вызовом partialSlice или Slice")
    .writeLine("Так как каждый раз Pirit отрезал по линии")
    //When we want slice paper, we need roll 4 or more rows
    .rollRow(8)
    //And slice after print and roll
    .partialSlice()
    .writeLine("Потом опять что-то печатать")
    .writeLine("Потом опять что-то печатать")
    .writeLine("Потом опять что-то печатать")
    .safeSlice()
    //When we done with commands, we can use send, sendAndClean or sendAndClose to send buffer to Pirit Printer
    .sendAndClose();
});

When you call connect function, it trying find Pirit Printer as COM device. When connect was opened it call callback function and set as second argument object of Pirit constructor.

After all you can use Pirit API

TODO Methods

To see methods documentation use ”jsdoc“ generator.

Keywords

FAQs

Package last updated on 11 Sep 2015

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