pulse_counter

0.0.1 • Public • Published

Pulse counter library for Raspberry pi

Warning this is not tested yet!

/*
    "INT_EDGE_FALLING",
    "INT_EDGE_RISING"
    "INT_EDGE_BOTH"
*/
//pulse source is connected to pin 6. Edge is rising
addon.init(6,"INT_EDGE_RISING");

//start pulse counter
addon.start();

//clear pulse counter
addon.clear();

setTimeout(function() {
    //read the count of pulses
    console.info(addon.get());
    
    //stop pulse counting
    addon.stop();
}, 30000);

Readme

Keywords

none

Package Sidebar

Install

npm i pulse_counter

Weekly Downloads

1

Version

0.0.1

License

none

Last publish

Collaborators

  • arttupii