Dvorkin Dmitry
Dvorkin Dmitry
Hello, @TaylorIsAGoodboy > Do we have a way to release the line obviously, yes. In my gpio module for nodeRed (will be published within 2 days) I am doing like...
Dear @noctarius ! You commit is very good. But things like getNumberOfLines, getChipName, getChipLabel are libgpiod-specific :) We could get rid of libgpiod dependency and simply use native linux functions....
here is a link: https://github.com/s5z6/node-red-contrib-libgpiod https://www.npmjs.com/package/node-red-contrib-libgpiod https://flows.nodered.org/node/node-red-contrib-libgpiod
@noctarius @sombriks ! if you'd run the code in debug mode (I added it in my commit) you can see: ../src/chip.cc New():31 ../src/chip.cc New():33 ../src/chip.cc Chip():15 ../src/chip.cc Chip():17 0x207b2e8 ../src/chip.cc...
test code: ``` const { version, Chip, Line } = require("node-libgpiod"); const chip = new Chip(0); var line = new Line(chip, 12); // led on GPIO12 line = new Line(chip,...
with C library and direct ioctl commands you'll have same issue, but with "int fd" (file descriptor). if you're not able to have only 1 NodeJS object for 1 line,...
it should be like this: every /dev/gpiochip* should have 1 Lines object. when you want to access certain line, you just call Lines.somefunc( pinnum, params) thats all!