|
Post by jmaurin on Oct 4, 2017 4:18:16 GMT -8
Hi! I'm trying to use WeatherBoard with my current running Rpi-3 on a metal box along with some power supplys. My rpi-3 is running fine there (for ADS-B reception and VHF reception, using dongles - Only reception!). But when I try to install WeatherBoard with 35cm cables (for i2c and rain/wind interrupt), i'm getting false-reading for interrupts. It's intermittent and doesn't happen if I use very short cables (like 10cm). So my question is: is there anything that I can do to avoid this? I've checked manual and these pins are already pulled-up with 10k resistor. But since I'm using direct with rpi (without grove board) and 3.3v, I'm guessing this resistors are too much for 3v3 and this cable length. Maybe? OR any software debounce solution?
|
|
|
Post by SDL on Oct 7, 2017 7:00:47 GMT -8
JMaurin,
Hmm. I would guess you are getting some noise on the lines. You can try to do two things:
1) Add another 10K Ohm resistor pullup. That would make the total pullup 5K Ohms, which is still just fine for the Raspberry Pi (The GPIOs can sink 50mA if my memory is correct). 5K Ohms is still less than a 1mA
2) Go into the python software where the debounce time is set (i.e. something like GPIO.add_event_detect(23, GPIO.FALLING, callback=my_callback2, bouncetime=300) ) and increase the bounce time a bit.
BP
|
|