How to use a low-signaling sensor to trigger wake interrupt

General discussions and questions abound development of code with MicroPython that is not hardware specific.
Target audience: MicroPython Users.
User avatar
dhylands
Posts: 3359
Joined: Mon Jan 06, 2014 6:08 pm
Location: Peachland, BC, Canada
Contact:

Re: How to use a low-signaling sensor to trigger wake interrupt

Post by dhylands » Fri May 22, 2020 5:12 pm

You had mad the comment
so the only connection on the entire board is the sensor output into RESET
and I wanted to clarify that GND was also connected (I've helped lots of people who don't appreciate that without GND there is no reference for the signal voltages).

kwiley
Posts: 99
Joined: Wed May 16, 2018 5:53 pm
Contact:

Re: How to use a low-signaling sensor to trigger wake interrupt

Post by kwiley » Fri May 22, 2020 8:15 pm

Yes, sorry. I see your point. I did write that. I was referring to the only "logic" connection, pushing aside the issue of actually powering the sensor, and furthermore that ground should be "common" amongst components. But you are right that such details need to be clarified.

Thanks!

nekomatic
Posts: 25
Joined: Thu May 08, 2014 9:31 pm

Re: How to use a low-signaling sensor to trigger wake interrupt

Post by nekomatic » Wed Jun 03, 2020 2:00 pm

It sounds as if your GPIO16 is a push-pull output, so when you had it connected to both the board's RESET and the sensor's output pin, it was actively holding both of those either high or low - this would explain why it actually stopped the sensor working.

If you have an input with a pullup to V+, either internal to the processor or using a physical pullup resistor, and you want either of two outputs to be able to take the input low, you can connect each input via a diode, with its anode connected to the pulled-up input and its cathode to the output.

To solve your problem of only alternate reset pulses being effective though, it sounds like you might need to use a hardware monostable circuit to 'stretch' the pulse to a sufficient duration? Something like a 74HC221 maybe, or if you really must, one of the CMOS variants of the 555.

Post Reply