Comments (4)
Hi, i have the same problem, also after apt-get update/ upgrade.
Greatings.
from wiringpi-node.
Hopefully you sorted things out by now, but something doesn't look right about those pin numberings. The comment indicates pin 7 is of interest. The pin terminology you're using is the 'wiring pi' terminology, and pin 27 may refer to a BCM pin 27, which would be wpi pin 2. Maybe that's the issue?
I have an additional issue where I was trying to set the pull up resistor on a pin. When I would close the circuit to ground, nothing happened... however, when I touched the pin (while beeing bare footed and standing on a wood floor of course) the callback would then and only then fire. I tested this many times. I don't really know my ee so it seems weird to me. The fix was to use the gpio utility to set the pin to input and up.
gpio mode 0 in
gpio mode 0 up
In my case, I was using wpi.setup('sys');
so the app could be run as an unprivileged user. As such I refered to the wpi pin zero as 17. Is there a chance there's something funky in the code about that?
Would someone be willing to confirm this strangeness? The pin that should be touched is on header 11. Somethings up with the pull up/down transistor code if it only fires on your contact instead of when it's touched to ground (say header 6).
Test Setup (incomplete?):
$ gpio mode 0 in
$ gpio edge 0 rising
$ gpio exports
GPIO Pins exported:
0: in 1 rising
17: in 0 rising
Test code:
var wpi = require('wiring-pi');
wpi.setup('sys');
var pin = 0;
var bcm_pin = 17; // pinTranslator.toBCM(pin); // 17
wpi.pinMode(bcm_pin, wpi.INPUT);
wpi.pullUpDnControl(bcm_pin, wpi.PUD_UP);
// A. Get initial state of pins and report states
wpi.wiringPiISR(bcm_pin, wpi.INT_EDGE_RISING, function(delta) {
console.log("detection made... you probably touched wpi pin " + pin);
});
I'm trying it for a second time after rebooting... and it's just not responding to touch or being connected to ground unless I do gpio mode 0 up
which I wouldn't expect I would need to do from bash since there's a function to do that, right?
from wiringpi-node.
Hi.
I want to send interrupts through my gpio pins. I am using the wiringPi Library for this purpose. When a code to wait for interrupt is run ,the ethernet connection to my laptop breaks and it says broken pipe error.
Could someone please help me to execute a command X in C when an interrupt event occurs which also prevents any kind of switch debouncing and transient voltages.
Thank you.
from wiringpi-node.
I had a similar problem and I changed the pin and grounded the shield in the (2m long) cable, that probably acted as an antenna.
Don't use pins like i2c or w1 (pin 7 in whatever counting). You never know if there's a kernel driver "working" on those pins.
-M
from wiringpi-node.
Related Issues (20)
- It is a error?
- how to build for firmware 4.9 and wiringpi 2.4.4? HOT 5
- example for pwmWrite? HOT 3
- Got an error installing wiring-pi on alpine linux
- wiringPi.node _Z15lcd128x64circleiiiii: symbol not found under alpine linux
- Install wiring-pi on Raspberry pi 3 with Raspbian Jessie HOT 2
- Can not install wiring pi while using macOS HOT 3
- "Type Error: wpi.pcf8574Setup is not a function"
- returning from wiringPiSPIDataRW HOT 1
- Build failure: install.sh: line 28: ../../install.log: Permission denied HOT 1
- "sudo npm install wiring-pi" Does not work HOT 2
- Unable to determine hardware version: I see: hardware: bcm2835 HOT 5
- can't install wiringpi on raspy3 HOT 3
- can't install on Node.js v9.6.1
- PWM1 missing?!?
- PWM wrapper for hardware or software PWM
- Software debounce?
- Unable to build (Orange PI One)
- Can't install wiring pi HOT 13
- Please add LICENCE file in root dir
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from wiringpi-node.