Remove whitespace, clean up code and fix bug.

This largely removes trailing whitespace, improves a minor stylistic issue and fixes a libusb bug where a parameter changed.

`btchipPersoWizard.py` under Ubuntu 14.04 **does not** work for me without the bugfix.