I have added experimental library for HexWax expandIO-USB to GitHub . It should work fine for official evaluation board as well as it works for mine custom made one. The library is still in early stage so some significant changes are to be expected to both code and code structure.
Read only repository is here: git://github.com/mlalevic/HexWax-expandIO-Python-Library.git
Nearly all commands from the firmware are covered, and I have added two examples – one single threaded and one multi-threaded – the same example – blinking LEDs.
See how simple it is:
All commands are created like SetBit(“TRISC”, 6, 0), method pack() is used to get byte array representation for sending to device. Unpacking is done by a corresponding unpack class – like SetBitUnpack, and it unpacks input packet into member attributes.
Here’s multi-threaded version which is even simpler:
UsbBackgroundRead spawns a thread to read data from USB device in background. This is useful if the device can have external events – interrupts.
Anyway, got to do some more documentation on it and add more examples soon.
Comments