Skip to content

felps-dev/ezinterface.js

Repository files navigation

Open Source EZInterface bindings for NodeJS

A simple implementation of EZInterface using NodeJS and FFI for dll communication.

Requirements:

  • NodeJS 14+
  • ffi-napi requirements (see there)

Roadmap:

  • Implement all dll functions (37/278)
  • Implement event mode (Async)

Usage:

import EZInterface from 'ezinterfacejs';

const test = new EZInterface('127.0.0.1', 5123, 10000); //Host, port and timeout

test.testConnection();
console.log('Conexão OK');
const count = test.getDeliveriesCount();
console.log('Encontrado ' + count + ' abastecimentos.');

for (let index = count; index !== 0; index--) {
    const del_id = test.getDeliveryByOrdinal(index);
    console.log('Abastecimento ' + del_id + ': ');
    const abast = test.getDeliveryPropertiesEx4(del_id);
    console.log(abast);
    test.lockDelivery(del_id);
    test.clearDelivery(del_id, abast.dtype);
}

Contributing

  1. Ensure any install or build dependencies are removed before the end of the layer when doing a build.
  2. Update the README.md with details of changes to the interface, this includes new environment variables, exposed ports, useful file locations and container parameters.
  3. Increase the version numbers in any examples files and the README.md to the new version that this Pull Request would represent. The versioning scheme we use is SemVer.
  4. You may merge the Pull Request in once you have the sign-off of two other developers, or if you do not have permission to do that, you may request the second reviewer to merge it for you.

License

MIT License. See the LICENSE file.

About

Javascript implementation of EZTech DLL interface

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published