Created: 2012-03-22 14:47
Updated: 2016-11-09 23:12
License: mit

USB Panic Button

I got given a USB Panic Button for christmas a few years ago. I'm trying to make it do things on Mac OSX with Python.

Shout Outs

Shamelessly learned what calls to make from Ken Shirriff's experiences on Linux who also copied some magic number knowledges from Benjamin Kendinibilir's adventures in Perl.

morland provided moral support and Python tips.

What I done to make it run

I used libusb but it's possible that OpenUSB would work too. For convenience, I used homebrew.

brew install libusb

I installed Python 2.7.2 through virtualenv. Then, I got the PyUSB module. Version 1.0.0a2 to be precise.

pip install pyusb

Run the script


We need to go deeper

If you really want to understand what's going on in USB land, I gained some insight from USB in a NutShell.

Cookies help us deliver our services. By using our services, you agree to our use of cookies Learn more