The Arduboy, as you might have guessed from the name, was designed as a love letter to the Nintendo Game Boy that many a hacker spent their formative years squinting at. While the open source handheld is far smaller than the classic DMG-01, it retains the same general form factor, monochromatic display, and even the iconic red LED to the left of the screen. But one thing it didn’t inherit from the original was the concept of removable game cartridges. That is, until now.
Over the last year, [Mr.Blinky] and a group of dedicated Arduboy owners have been working on adding a removable cartridge to the diminutive handheld. On paper it seemed easy enough, just hang an external SPI flash chip off of the test pads that were already present on the Arduboy PCB, but to turn that idea into a practical cartridge required an immense amount of work and discussion. The thread on the Arduboy community forums covers everything from the ergonomics of the physical cartridge design to the development of a new bootloader that could handle loading multiple games.
The first problem the group had to address was how small the Arduboy is: there’s simply no room in the back to add in a cartridge slot. So a large amount of time is spent proposing different ways of actually getting the theoretical cartridge attached to the system. There was some talk of entirely redesigning the case so it could take the cartridge internally (like the real Game Boy), but this eventually lost out for a less invasive approach that simply replaced the rear of the Arduboy with a 3D printed plate that gave the modders enough room to add a male header along the top edge of the system.
As an added bonus, the cartridge connector doubles as an expansion port for the Arduboy. While perfecting the design, various forum users have chimed in with different gadgets that make use of the new port, from WS2812B LEDs to additional input devices like joysticks or a full QWERTY keyboard. Even if you aren’t interested in expanding the storage space on your Arduboy, being able to plug in new hardware modules certainly opens up some interesting possibilities.
In fact, the project so impressed Arduboy creator [Kevin Bates] that he chimed in on the topic last month to announce he would start looking into integrating the community’s cartridge modification into the production hardware. If all goes well, pretty soon there might be an official upgrade path for those who want to expand what this tiny nostalgia machine is capable of.
[Thanks to Roo for the tip.]
I am not in the Arduboy loop here… Why not an sd-card?
That’s kind of like saying, “Why not make the games 3D” or “Why not have WiFi to download content from the Internet”.
It’s far beyond the capability of the system. They could tack an extra flash chip with (relatively) minimal hardware/software work. Adding an SD slot and support for FAT filesystems is a whole different story.
Which is why I prefaced my comment with, “I am not in the Arduboy loop here…”…
It isn’t particularly difficult to read an SD card with an atmega328. You don’t need to use FAT32, you can use the flash however you want. That would certainly be a lot easier to integrate than a big honking pin header. Maybe not as fun though, and having more pins does open up more interesting expansion cards.
It all starts with an innocent question based on ignorance and it ends in a crowd with torches and pitchforks asking for more. Sometimes things are just good the way they are and improving it beats it’s original intentions.
In other words: no matter how you make it… there will always be people wanting something else.
And there will always be people saying that those things aren’t impossible, but in the mean time it still needs to be done and everyone expects some else to do it…
And all regarding a system that was never intended to be used that way.
The atmega328 can easily read an SD card, even FAT32, yes. But it can’t execute code directly from it.
It would have to load it in RAM first but some games already need all the RAM.
I’m not criticizing the choices made in the article, I’m just refuting the false claims about SD card access from a low-end microcontroller. Daniel asked a seemingly innocent and valid question, and the first response he got seemed off based on my own knowledge of the subject.
Other than being a slightly more complicated protocol with the 512-byte blocks and “busy” signalling, an SD card isn’t much different from accessing any other SPI flash chip. SD cards support SPI and can even be bit-banged if necessary. Folk don’t need to be intimidated by the prospect of interacting with an SD card in low-performance applications like this.
It’s true that an atmega328 can’t execute code directly from an SD card, but that’s true of any external memory chip because the mcu lacks an external instruction memory bus. As far as I know the mcu can’t run code directly from RAM either (no reason for RAM be connected to the instruction bus in a Harvard architecture cpu), but I’ve never looked deeply into it. I don’t actually know if the arduboy uses an atmega328 or something else, but this external cartridge project obviously depends on a bootloader to transfer the game from the flash chip to the internal flash memory. A bootloader like that can read from an SD card just as easily as it can read from another SPI flash chip. It would be a few hour difference in development time, for me at least, but I’ve written code to talk to an SD card on an atmega328 before.
I don’t necessarily believe the claims that an SD card based approach is inherently more expensive, either. Certainly in terms of time and likely even dollars, buying a low capacity SD card for < $3 is way cheaper than assembling a custom PCB and housing in low quantities. The arduboy side would likely be a bit more expensive due to the need for voltage level shifting and the choice of socket, but once again that's on the order of a few bucks. It would even be fun to "hack" a socket out of non-traditional components to be in the spirit of the arduboy's construction. Heck, you could use those micro-to-SD adapters as the socket.
Once again, I'm not criticizing the choices made by the featured project. They likely had different priorities that led them down the path they went. As long as the people had fun and learned something, it was a success.
> That’s kind of like saying, “Why not make the games 3D”
Yeah, why not?
https://www.youtube.com/watch?v=ES3fGLuse4s
https://hackaday.com/2019/01/07/star-fox-comes-to-arduboy/
> It’s far beyond the capability of the system.
¯\_(ツ)_/¯
Valid question tbh, weird to see that ‘Limited’ guy flex.
Just like Jeff also mentioned, i think they went for this approach because now the cards can be more then just games. Not saying you cant use SD for something like that either (you can, im sure you’ve heard of Wifi SD cards and stuff) but this approach with a simple header is just a cheaper solution
SD card mods exist, this has a smaller footprint and computational overhead. Also cheaper.