Digispark USB Autoit3 Wrapper
(v1.0 updated: nov 13rd 2013)
Digispark USB Autoit3 Wrapper is just a quick few lines of autoit3 code to allow talking with the native USB protocol used by the Digispark USB library. [contact: opensource (arobase) grisambre dot net]
Basic features : send.exe and receive.exe from the digispark code have to be used with the code (in same directory). The wrapper is calling those executables. If the autoit3 code is compiled, the executables are encapsulated inside your code, so no need to provide them.
- DigisparkUSB_Setup($persistent) is making sure send.exe and receive.exe are available. If the code is compiled, they are extracted to the current script directory
- DigisparkUSB_isconnected() checks is a digispark is connected to the host computer
- DigisparkUSB_write($text) is sending some text to the digispark, ex : DigisparkUSB_write('Hello "World" !' & @CR & "See You later...")
- DigisparkUSB_read($chars) Reads whatever the didispark is sending us
- DigisparkUSB_readline() Same but for a single line
Please check source code for complete reference !
Source code (includes example)