My goal is to reset an ESP8266 in deep sleep (pull RST low) when the value of my float sensor changes (which detects the water level in a tank), so that I can report the value change to the IoT platform. It's a low power design, so the MCU should sleep as much as possible.
Edit: At first it seemed like the sensor value was on/off, but on second thoughts, it could be analog. I'll do some testing and update.
I created a dual edge monostable trigger which wakes the MCU when the value changes. Is this the best approach for low power, or is there a better solution?
Can the monostable I came up with be improved? I designed a circuit which I can make out of junkbox parts, but it doesn't need to be, I'm happy to use an IC or MCU feature instead. I'm also happy to use a different MCU.
simulate this circuit – Schematic created using CircuitLab
Note: Clock signal and Q10 simulates the sensor value changing; purely for simulation and not actually part of the real circuit.
Edit: I see from an answer on a similar question that PIC micros have something called "interrupt on change". I see that ESP8266 has GPIO interrupts, but it looks like only a specific pin can be used to wake from deep sleep. It looks like the ESP32 can wake from different GPIOs, but can it wake on either falling or rising edge? Also, from the same answer I see that I might have created an "edge to glitch converter"... is my circuit a good or a bad example of such a design?
Edit: Below image is the float sensor. Unfortunately, I'm not sure where the datasheet is, but I'll do some testing to see if it's digital or analog.
Edit: After testing, I see that the sensor produces a digital signal, as I had hoped.