$12 Arduboy compatible system


(Scott) #1

Continuing the discussion from Where can I get a dev kit?:

A few days after the Arduboy campaign launched on Kickstarter, I used the information, photos, Dev Kit information on Tindie, and the ArduBreakout code on GitHub to get a pretty good idea of the design and parts used. On May 16 I ordered parts I needed, from Chinese sellers on eBay. The parts arrived last Friday, June 12. The result is pictured here.

I used a copy of the SparkFun Pro Micro 3.3V/8MHz for the Arduino base system. I got a 0.96" display instead of a 1.3" one (same 128x64 resolution) because it was cheaper and I had trouble finding a 1.3" one with a SSD1306 controller. Most of the inexpensive 1.3" ones use the SH1106 controller, which would require some modifications to the library. I wanted to be as compatible as possible.

I’ve currently wired it up on a solderless breadboard but once the design is finalised I’ll mount and solder everything up on a piece of copper proto board. I want to try to make it the same credit card size as the Arduboy (but it will be much thicker, of course, and not in a case).

Parts prices (USD, free shipping, no taxes paid):

SparkFun Pro Micro 3.3V/8MHz clone $6.00
OLED display 0.93" 128x64 SPI $3.80
8 Tactile Pushbuttons $0.40
Piezo Speaker 18mm $0.20
Battery Holder AAX3 $1.00

Solderless Breadboard $2.80.
3 Eneloop AA NiMH Battery $7.65


Building an ArduBoy clone
Debating whether or not to wait for arduboy2
DIY Arduboy - problem with SH1106 screen
What is pin 7 on the OLED? [Nothing]
It's for a school project
Arduboy clone with Arduboy
Can I Make games for Arduboy Without the Development Board?
Post your DIY
Help for DIY Arduboy
First time programmer, DIY arduboy
Has anyone developed a DIY arduboy kit
Arduboy Kickstarter version design discussion
Shadow Runner - First conversion of a TEAM a.r.g. game
DIY Arduboy Kit
Arduboy Kickstarter version design discussion
Please help to find a devkit!
I need some help on the basics
Request for programmable microcard
First time programmer, DIY arduboy
Should the $12 Arduboy system thread's contents be 'forked'/'extracted'
Should we have a 'homemade' category for stuff about homemade Arduboys?
About the Homemade category
About the Homemade category
Arduino uno/Df Robot Input Shield V2
I want to make a homeade arduboy!
(Kevin) #2

Nice! This is very similar to what we used almost a year ago to prototype the whole system. It took us a while to shrink down all the components and everything and get it into a package that can fit into your wallet and is also super durable!


(Scott) #3

@bateske, Thanks for the compliment.

Although my system was relatively cheap to construct, I acknowledge that the true value of an actual Arduboy is in its compact size and durability. It would be difficult for an individual to build a single similar sized unit, with a 1.3" display and including the case, thin film battery and charge controller, for the price you are asking.


(John) #4

Looks like very interesting.
But i don´t understand Details.

Its the projekt for people, that not become a dev kit?
It is a inofficial alternative for arduboy?
It´s possible to dev for arduboy with this?
It is open source or not? For people like me we miss the schematic diagramm. When i order all components, how i know how connect which wire with another? All what i see its your picture.
I see not (i am not a electric genius) how the wires on the back from the Buttons are wired.

Sorry when my english are horrible, i am come from Germany, Bavaria^^ But i understand all what you type.


(Scott) #5

Yes, or for anyone (like me) who likes to work with hardware themselves. Also maybe to save some money. By using a solderless breadboad, I can rewire it to make any changes to match the final Arduboy version, when the details are made available.

The answer is yes to both questions.

There are slight differences between my system and the Dev Kit:

  1. The Dev Kit runs at 16MHz. Mine runs at 8MHz.
    You could use the SparkFun Pro Micro 5V/16MHz version but you would need 5V to 3.3V level shifting logic to drive the display, or use a display module that is 5V tolerant. If @bateske decides to run the final Arduboy at 5V and 16MHz, as he is now planning, I will probably change mine as well.
  • The SparkFun Pro Micro that I used doesn’t bring out pin 12. The Dev Kit uses this pin for the display reset signal. I’ve currently connected the display reset line to pin 3, and had to make a small change to the Arduboy library to account for this. If you want to run at 5V/16MHz, then in place of the SparkFun Pro Micro you could use an Arduino Leonardo, or Arduino Micro to gain access to pin 12 for better compatibility.

  • The Dev Kit shorts pins A2 and A3 and wires them both to the speaker. This is not good! You shouldn’t short two outputs together. I wire to only one pin at a time, depending on which one the sketch uses.

  • I believe the Dev Kit runs the processor directly from the coin cell battery, which would be about 3.0V, or at 5V when connected to USB (maybe someone can confirm this?). In my system the processor always runs at 3.3V from a regulator on the Pro Micro board.

  • The piezo speaker that I used is not the same as the one the Dev Kit uses. It may sound slightly different.

  • The display module that I used has no CS input. This doesn’t affect anything since no other devices are attached to the SPI interface. If you want to make your own system I would get a display that has all the required signals available.

Other than changing the library for the display reset pin, and differences due to clock speed, my system behaves almost exactly as a Dev Kit. You can develop and run Arduboy sketches with it.

The SparkFun Pro Micro that I used is open source. The display is a standard design with a standard SPI interface and there are many different vendors selling versions that would work.

The safest (but expensive) display to use might be one of the ones from Adafruit, either the 0.96" one or the 1.3" one. These are both 5V tolerant and are virtually guaranteed to work.

I’d be happy to tell you where I got the components, or offer alternatives, or tell you if ones you have found will work.

I put the buttons on separate boards because the ones I used didn’t plug directly into the breadboard properly. If you used buttons that were breadboard compatible it would make things easier.

The wiring is as follows:

Display:

Arduino Pin               Display Pin
===========               ===========
  3 (or 12 if available)  Reset
  4                       D/C (data/command select)
  6                       SPI CS (chip select) (not used by my display)
  15 SCLK                 SPI SCLK (clock)
  16 MOSI                 SPI Data In

Buttons:
Buttons are normally open push buttons. One side of each button goes to system ground. The other side is wired as follows:

Arduino Pin  Button Name
===========  ===========
     5       D-pad RIGHT
     8       D-pad UP
     9       D-pad LEFT
    10       D-pad DOWN
    A0       A
    A1       B

     7       Start (not on the Dev Kit)
    RST      System Reset (not on the Dev Kit)

I might have buttons A and B reversed. I don’t know if it’s been decided which is which.

Speaker:

One side goes to system ground. The other side goes to pin A2 or A3 (but not both!). The Dev Kit shorts pins A2 to A3. Don’t do this. Use one pin at a time.

LED:

The Dev Kit uses the Arduino RXLED pin 17. This is wired to an LED on Pro Micro, Leonardo and Micro boards, so no extra LED is required.

Power:

The negative (black) lead of the 3 AA battery pack is connected to ground. The positive lead (red) is connected to the RAW input of the Pro Micro.

The display I used has an on board 3.3V regulator (it’s supposed to be 5V tolerant but I investigated and found that it really isn’t), so I connected the display’s VCC pin directly to battery positive. If the display you use requires 3.3V power, you could get it from the VCC pin of the Pro Micro.

I don’t have a power switch. I just remove one of the batteries, or one of the leads, to power the system off. Because of the design of the Pro Micro, you must make sure the batteries are disconnected while connected to the USB port.

If you make a 5V system, you would need to use 4 or 5 AA batteries or some other means to power the Pro Micro. If the display required 3.3V you would have to find a way of providing that as well (plus possibly add external level shifter circuitry to the display signals).

Your English is quite understandable. :smile:


#6

Excellent thread @MLXXXp! Will be a good resource for interested DIYers!

If using an Arduino Leonardo / Micro they both have a secondary 3.3V / 50mA supply available.


(Scott) #7

Thanks for pointing this out. You still may need the level shifters, though.

Also, if you use a Leonardo or Micro you don’t need to add the reset button that I did. They both have one on board.


#9

Tried to make a sytem myself, but in the software I get this when I try to compile something from the standard Arduboy-master:

This report would have more information with
"Show verbose output during compilation"
enabled in File > Preferences.
Arduino: 1.0.6 (Mac OS X), Board: "Arduino Leonardo"
In file included from ArduBreakout.ino:13:
/Users/DHELL/Documents/Arduino/libraries/Arduboy-master/Arduboy.h:100: error: ISO C++ forbids initialization of member ‘cursor_x’
/Users/DHELL/Documents/Arduino/libraries/Arduboy-master/Arduboy.h:100: error: making ‘cursor_x’ static
/Users/DHELL/Documents/Arduino/libraries/Arduboy-master/Arduboy.h:100: error: ISO C++ forbids in-class initialization of non-const static member ‘cursor_x’
/Users/DHELL/Documents/Arduino/libraries/Arduboy-master/Arduboy.h:101: error: ISO C++ forbids initialization of member ‘cursor_y’
/Users/DHELL/Documents/Arduino/libraries/Arduboy-master/Arduboy.h:101: error: making ‘cursor_y’ static
/Users/DHELL/Documents/Arduino/libraries/Arduboy-master/Arduboy.h:101: error: ISO C++ forbids in-class initialization of non-const static member ‘cursor_y’
/Users/DHELL/Documents/Arduino/libraries/Arduboy-master/Arduboy.h:102: error: ISO C++ forbids initialization of member ‘textsize’
/Users/DHELL/Documents/Arduino/libraries/Arduboy-master/Arduboy.h:102: error: making ‘textsize’ static
/Users/DHELL/Documents/Arduino/libraries/Arduboy-master/Arduboy.h:102: error: ISO C++ forbids in-class initialization of non-const static member ‘textsize’

I’m a beginner, but just can’t wait to play some games!!! Just to get this testboard going would be nice.


#10

I tried to compile ArduBreakout using the 1.0.6 version of Arduino that you used and it indeed produces these errors. Updating to the latest version of the Arduino IDE (currently 1.6.5) should make these errors go away.

Note : if compiling and uploading works but the screen stays black, carefully check all the connections to the screen, especially the RST signal. You can change the pins of CS, DC and RST in Arduboy.h. D0 is SCLK (pin 15) and D1 is MOSI (pin 16).


(Ross) #11

This topic is now a banner. It will appear at the top of every page until it is dismissed by the user.


(Kevin) #12

This topic is no longer a banner. It will no longer appear at the top of every page.


(Tim McMahon) #13

Did you notice that the price from ebay sellers for the SSD1306 0.96" 128x64 SPI OLED display jumped from $3.80 to $10.56 shortly after June 2015?

Luckily I purchased one on the 10th of June for $3.96 :slight_smile:


(Scott) #14

Since it looks like the production Arduboy is going to run at 16MHz, I’ve replaced the 3.3V 8MHz Pro Micro with a 5V 16MHz Arduino/Genuino Micro clone.

I switched from a Pro Micro to an Arduino Micro to get the extra I/O pins needed for better hardware and software compatibility. It has an on board reset button, so an external one is no longer needed, and since @bateske has decided not to include a Start button, now only the lower A and B buttons of the 4 on the right are used.

Because the display I’m using can’t handle 5V signals, I’ve also added a 5V to 3.3V level shifter module. Another benefit of the Arduino Micro is that it provides a 3.3V output for the level shifters (and display, if necessary, though mine has an on board regulator).

Once the wiring of the new RGB LED is known, I’ll add one as well. When the I/O pin assignments for the buttons and speaker have been finalised and disclosed, I’ll rewire mine accordingly, and then probably mount everything permanently on a circuit board.

I’m now using four AAA size NiMH rechargeable batteries for power. Their total output voltage will vary between 5.5V and 4.5V (if not discharged too far), which is within specifications for the processor running at 16MHz, so I’m just feeding the battery output straight into Vcc, without regulation. With the 800mAh Eneloop batteries I’m using, I should get at least 14 hours of operation per charge. For 1.5V non-rechargeable batteries, or other higher voltage supply, you could probably use the Micro’s on board 5V regulator.

Switching the processor board ($2.90 more) and adding level shifters ($1.00) has increased the cost somewhat, so my $12 system is now more like $16. Also, as @TimMcMahon pointed out, the cost of the displays has increased significantly, so today’s price would be more like $23.


Star Honor - A Space Roguelike Adventure
Multi-player linked Arduboys via a USB host (PC)
Help With Building Arduboy/Devkit Clone (Blackstripe)
How to Reset the Dev Kit
Amplifier Circuit
drawPlusMask artifacts, frequent bricking after upload
Arduboy 2 My Ultimate Hardware Wishlist
(Kevin) #15

There is a shortage of displays right now, I was lucky to get in just before it got really bad. And also very lucky the quantity was so high, because it ended up being the minimum order quantity for the only place that could get them any faster than 6 months!

This is part of the reason the kickstarter units are behind schedule, we should get all of them delivered to us by the end of the year.

I’m looking into ways to sell the parts on the store here, but it only makes sense to me if I can sell them cheaper than they are available elsewhere. I’m looking at ways of selling the battery separate but that is a project for another day.

Don’t forget the original board files are out there too!


(Kevin) #63

I just wanted to jump in here and say I love to see all this work here, it’s so cool to see everyone helping each other out. These kind of forum posts are exactly how I got started. Keep it up everyone!


(Raphael) #76

Hello everyone!

I’ve recently ordered my Arduboy from the webstore and I think I’m gonna get it in my hands soon enough. But since I always love cool projects, for as simple as they may be, I bought everything necessary to build my own homemade Arduboy, or “Hackduboy” as some have said. :slight_smile:

I know a bit about electronics and programming, but have never messed with any Arduino related thing.

So, I’ve got an Arduino Leonardo, this OLED https://cdn-shop.adafruit.com/1200x900/938-15.jpg, a piezo speaker and buttons.

I want it to be as compatible as the production Arduboy, but I’m not so sure of how to connect everything, and I’m afraid I can damage something if I do it wrong.

Can someone help me, please? :grin:


(Scott) #78

To be fully compatible you would also need a common anode RGB LED and three suitable dropping resistors for it.

Wiring for an Arduboy compatible using an Arduino Leonardo and Adafruit 938 (or 326) OLED display:

Some of the display pins need to be connected to the Leonardo’s ICSP header, which is the 3x2 pin connector on the edge opposite from the power and USB connectors.

Display Leonardo
Data ICSP 4 MOSI
Clk ICSP 3 SCK
DC 4
Rst ~6
CS 12
3v3 (not connected)
Vin 5V or ICSP 2 VCC
Gnd GND or ICSP 6 GND

Either speaker lead can go to either pin. If the volume is too high, you can put a resistor between one of the speaker leads and the Leonardo pin.

Speaker Leonardo
Lead 1 ~5
Lead 2 ~13

One side of each button goes to GND. The other side of each button goes to:

Button Leonardo
Up A0
Right A1
Left A2
Down A3
A 7
B 8

The common anode of the RGB LED goes to 5V.
The cathode of each individual RGB LED should connect to its own appropriate dropping resistor. The other lead of the resistor should go to:

LED resistor Leonardo
Blue ~9
Red ~10
Green ~11

For the RGB LED that I used, similar to this one, I found the following resistor values to work well with regulated 5V power: Red 1K, Green 3.3K, Blue 1K


First time programmer, DIY arduboy
First time programmer, DIY arduboy
(Raphael) #79

Thank you very very much, man! It all works perfectly well!

Now that I’ve tested it using a breadboard, I’m gonna make a box or something of the kind for handling it better.

If anyone’s interested, I’ll post some pictures of what I’ve done when I’m finished.


(Mike McRoberts) #97

ArduBoy uses 16 pins? I made a clone of an ArduBoy and it is using 12 pins.


(Scott) #98

Buttons: 6
Display: 5
Speaker: 2
RGB LED: 3

Tricks with the display: Tie CS low and use an RC circuit for reset to eliminate 2 pins.
This still means 14 pins.

If you want to remove some functionality: Use only 1 pin for the speaker. Eliminate the RGB LED.