'Python detect headset button press
I just need simple library that detect headset button state.
So I expect there simple program like this.
from hsbutton import isPressed
while True:
if isPressed():
Print("You are clicking headset button")
else:
Print("Waiting click")
Edit:
Tbh I don't know the difference of headset and earphone so I show you the picture.
In that picture you can see I circled a button. That button is what I mean.

Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
