-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GPIO Button alway closed #32
Comments
If you have confirmed that your circuit is working as expected (with a
multimeter or similar), then you could try stopping homebridge and running
the gpio tool. It should show the status change between having the button
open or closed. That would rule out a plugin problem.
If you've reconfigured the pins as inputs, make sure you have overrideCache
set to true in your config, and try deleting the
accessories/cachedAccessories file (ensuring that homebridge is stopped
before you delete it)
…On Sun, 17 Sep 2017 at 17:07, sherazan ***@***.***> wrote:
Hi, I'm using your fantastic plugin and it work great to manage some leds,
but I would try to use also to read the status fo some buttons; the
problems is that the status is always closed, also changing parameters like
pull up/dow/off and invert; do you have some suggests? Thanks in advance.
Guido
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#32>, or mute the
thread
<https://github.com/notifications/unsubscribe-auth/ARe_tT8DlPQ8iZdiRFemLIef2mlD5hSyks5sjUOsgaJpZM4PaMSz>
.
|
Hi,
"platform" : "WiringPiPlatform", {"name" : "GPIO8", "pin" : 2, "enabled" : "true","mode" : "in", "pull" : "up", "inverted" : "false","duration" : 0,"polling" : "false"}, Let me know. Thanks |
Hi,
When homebridge starts, it should set:
/says/class/gpio/gpioX/edge to "both"
Could you confirm which physical pin on the Pi header you've got it
connected to? Pin 2 (BCM number) is physical pin 3, which is called GPIO0.
I'm wondering if the I2C that's the default for pins 2 and 3 (BCM) is
causing a conflict.
…On Sun, 17 Sep 2017 at 17:43, sherazan ***@***.***> wrote:
Hi,
thanks for your feedback; about your suggest:
- checked with GPIO utility the button status and it changes from 1 to
0 when it is pressed, so the circuit ok.
. cancelled the cache as suggested by you in a previous post and
restarted hombridge, but the problem persiste: the status is always closed
also if I press the button.
Following my definitions:
"platform" : "WiringPiPlatform",
"name" : "Pi GPIO (WiringPi)",
"overrideCache" : "true",
"autoExport" : "true",
{"name" : "GPIO8", "pin" : 2, "enabled" : "true","mode" : "in", "pull" :
"up", "inverted" : "false","duration" : 0,"polling" : "false"},
Let me know.
Thanks
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#32 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ARe_tTTf2TfapKE4Tr3dEkaQXSZUD4voks5sjUw4gaJpZM4PaMSz>
.
|
Hi, Let me know. Thanks |
Following the log: |
Thanks for confirming.
The polling mechanism for Switch state is based on epoll. It might be worth
playing with the onoff node module to see if that is all working as
expected:
https://github.com/fivdi/onoff
Not sure if there's a node or kernel version problem that means the gpio
interrupts aren't firing (or being caught by the module)
…On Sun, 17 Sep 2017 at 21:09, sherazan ***@***.***> wrote:
Following the log:
[2017-9-17 22:07:27] [Pi GPIO (WiringPi)] Loading cached GPIO pins complete
[2017-9-17 22:07:27] [Pi GPIO (WiringPi)] New GPIO from config.json: GPIO8
(2)
[2017-9-17 22:07:27] [Pi GPIO (WiringPi)] GPIO8 Configure GPIO Pin
9d812b72-55e7-4cbe-bafe-6c4248d37429
[2017-9-17 22:07:27] [Pi GPIO (WiringPi)] Setting up interrupt callback
[2017-9-17 22:07:27] [Pi GPIO (WiringPi)] New GPIO from config.json: GPIO9
(3)
[2017-9-17 22:07:27] [Pi GPIO (WiringPi)] GPIO9 Configure GPIO Pin
5340bf88-027e-47d2-b5c8-021221816879
[2017-9-17 22:07:27] [Pi GPIO (WiringPi)] Setting up interrupt callback
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#32 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ARe_tROZdhyH0rEUUZxg7Pk1ZNS4k7eNks5sjXyDgaJpZM4PaMSz>
.
|
Hi, |
Hi, tests executed: I can confirm that with other GPIOs everything works fine, so, pheraps, there is some conflict using I2C pins. |
Thanks for testing. You could try disabling I2C in /boot/config.txt if you
would like to use those pins. Google suggests adding the following:
dtparam=i2c_arm=off dtparam=i2s=off
…On Thu, 5 Oct 2017 at 10:11, sherazan ***@***.***> wrote:
Hi, tests executed: I can confirm that with other GPIOs everything works
fine, so, pheraps, there is some conflict using I2C pins.
Thanks
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#32 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ARe_tVIg8FUyjqd0jQUv8CMxJfRnzgH-ks5spJ0pgaJpZM4PaMSz>
.
|
Hi, I'm using your fantastic plugin and it work great to manage some leds, but I would try to use also to read the status fo some buttons; the problems is that the status is always closed, also changing parameters like pull up/dow/off and invert; do you have some suggests? Thanks in advance.
Guido
The text was updated successfully, but these errors were encountered: