I need to implement a switch that closes a circuit twice for a short time - when pressed and then when released. The switch needs to be really small (should fit inside a 3.5mm TRRS headphone jack, meaning that the male jack would be the button itself, no wires will come out of it).
The jack itself only needs to connect the top ring and the sleeve (when pressed), and doesn't need to transfer audio in the other rings (so it can be hollowed out to fit the electronics inside).
I have a few about mechanical solutions, but thought that maybe an electrical one could be more reliable.
Any suggestions how to implement that?