I cannot find any libraries to connect a USB thumb drive to the native USB port of the Arduino Due.
I have an on going project that involves controlling some test equipment and I would like to create report files (xxxxx.txt) on a USB thumb drive to be printed on a PC.
The USBhost library only has examples for mouse and keyboard.
I would very much appreciate any suggestions on how to achieve this feature.
To write/read on a thumb drive with the Native USB port, I first used this library and example sketch:
Then I altered otgFSRead() using f_open() and f_read(), and otgFSWrite() using f_open() and f_write().
You can find f_read() and f_write() arguments here:
https://raw.githubusercontent.com/contiki-os/contiki/master/lib/fs/fat/ff.h
Note that your USB key should be properly formated before any write/read from the DUE:
1 Like
Thanks for the quick reply.
This library set is great, its going to do everything i need and more!
The GitHub Page pointed me to this website, which explains all the features in great detail.
OK MarkMakesStuff - Feel free to post your results, others may be interested too.