12345678910111213141516171819202122232425262728293031323334353637383940414243 |
-
-
-
-
- var rotaryEncoder = require("jsupm_rotaryencoder");
-
-
- var myRotaryEncoder = new rotaryEncoder.RotaryEncoder(2, 3);
-
- var myInterval = setInterval(function()
- {
- console.log("Position: " + myRotaryEncoder.position());
- }, 100);
-
-
- process.on('SIGINT', function()
- {
- clearInterval(myInterval);
- console.log("Exiting...");
- process.exit(0);
- });
|