No, I actually genuinely don’t think it should be a Arduboy thing …
Why am I even doing this? I know that my large proto shield is not going to have ICSP access so why am I writing a sketch that depend on physical SPI?
Call me crazy.
I spent hours poking through the ArduboyCore lib (Arduboy1 version) trying to source something useful, only to find it cutting all the corners into one difficult-to-port mess.
I really should try this earlier, but I didn’t. Anyway, it’s now done.
I went to Adafruit’s Github place and downloaded their SSD1306 relevant stuff. Then I poke around their code (it is gigantic, because it is test code and not optimized for size, and it’s readable and very well-documented because it is … well, it’s by Adafruit.)
So I am able to piece together the very bare minimum code that initializes the display and write some data to it (to display).
The sketch (of mine) draw a single clump of pixel (30, 30 to 31, 31) using four drawPixel (most rudimentary method of updating display).
It looked like this:
Apparently you are not at all impressed. It’s okay. But this allows you to use the Arduboy wiring (on the physical Arduino pinout, because all regular-header board attempted to keep the same pinout) on almost every board by them — Yun, Uno, Leonardo (of course), Mega, Due (included), including the old Arduino NG and Duemilanove and Dicilmila.
Maybe I should lead you to their page instead of mine (because how mine adopt it to my own purposes, and certain functions are removed)
You’ll need their SPI and I2C wiring package as well as their generic graphics package.
Not all functions may be available (e.g. EEPROM’s absence from DUE), but this opens up possibility for “compatible” systems that includes the core functions (LED, direction and AB buttons, display).
It would also allow more expandability, such as the massively increased capability for the DUE and the Mega, so the users can develop hardware outside of relevance to Arduboy, only using it as a interface (of graphics and input). Or, if the user wishes, use it to play Arduboy games.
If it garners enough attention I would make a fork of the library and go from there.
1 post - 1 participant
Read full topic