Electrical – Edge-triggering on simple logic

digital-logicedge

I'm making a module where a microcontroller can control RAM with only 10 GPIO pins (8 is data D0 through D7 and 2 are control).

One thing I want to do is that the moment a control line is raised, I want a reset to occur on a 74HC164 shift register if the highest data pin (D7) is set.

At first I was thinking using D7 and the control line as nand gate inputs and the reset as the output, but the problem with that is both lines must stay high, but I can't do that with the GPIO line because I use each state for a different purpose For example, low=accept data, high=shift register contents, low-to-high transition=reset, etc.

Is there something like a simple logic gate where an event can happen only when an input is on its rising or falling edge?

At first I was thinking utilizing a monostable multivibrator, but that involves additional timings which could make my project run slower. Are there other alternatives?

Best Answer

OnSemi's AND8408 describes how you can build an edge detector from a '97 logic gate (Schmitt-trigger (N)AND gate with one inverted input). The pulse width can be adjusted with the R/C values:

edge detector