Turns on USB leds using uhubctl when the webcam is activated and turns them off when it is deactivated.
It depends on uhubctl to turn on and off the USB lights that can be found here: http://github.com/mvp/uhubctl.
This works with Apple external iSight and maybe other FireWire webcams changing the DEVNAME variable.
Hi, I'm the author of uhubctl. Nice to see you using it in some inventive ways :)
This script looks quite ugly, all just to find which port to turn on/off.
I had this idea for a while: add feature to uhubctl to be able to specify which port to control not by number, but by identity of connected USB device: vendor, device type, or device serial number.
The only issue with that approach that it will work to turn off, but not to turn on: if device is off, we could not possibly know which port to operate on, unless we remembered it beforehand.
Ok, thanks for input. I will start coding it, and will commit when ready - may take a week or two.
You can help by pushing it into homebrew: Homebrew/homebrew-head-only#172 - I cannot comment on that thread, unfortunately. Thanks!