I am looking at using a latching switch (SPDT) to momentarily connect two pins. This is for a power button for a raspberry pi, so to power the machine from a hold state you have to momentarily short pins 5 and 6. Then to power the machine down I will switch it back to the other switch state and send a signal to a GPIO executing a shutdown script. I have done some research and found that the monostable multivibrator with 555 (one shot switch) might do the trick but a lot of the literature shows the trigger as a negative pulse? I will be latching the switch to 5v but only require a momentary switch, I was considering using an xor and flip flop but it seems like a lot of hassle.
Can anyone recommend another way or help me to understand if the monostable multivibrator will work for the application?