Using SIMMs to Add Some Extra RAM on your Arduino UNO

 

A Single In-line Memory Module (SIMM) is a type of memory module containing Random Access Memory (RAM) which was used in computers from the early 1980s to the late 1990s (think 386, 486, Macintoshs, Atari STE…). [Rafael] just made a little library that allows you to interface these modules to the Atmega328p-based Arduino UNO in order to gain some memory space. His work was actually based on the great Linux on the 8bit ATMEGA168 hack from [Dmitry Grinberg] but some tweaks were required to make it work with [Rapfael]‘s SIMM but also to port it to the Arduino platform. The 30-pin SIMM shown above is capable of storing up to (hold on to your chairs…) 16MB but due to limited amount of available IOs on the Atmega328p only 256KB can be used. Our guess it that an SPI / I2C IO extender could lift this limitation. A quick (shaky) video is embedded after the break.

Comments

  1. MRE says:

    I have often though of ideas like this but never got around to working out how to make it happen. Really cool. When I saw the photo and read the first few lines I was all like “WHAAAT?!!! YEEEAAAH!!!” And about wet myself with “storing up to 16MB..” (that is a LOAD for a little AVR or PIC) but then cried a little when I saw “only 256KB can be used.”

  2. Waterjet says:

    Can we get an Arduino like thing with lots of IO AND a fast processor AND megs of ram for $30 or so? Is that too much to ask? RasPi *kind* of does this but not reallllly. Needs more IO. Being able to run linux while also doing reasonably real time IO would be nice too. Maybe some kind of LCD screen so you can actually get feedback as to what is going on. Anybody?

    • Mike Szczys says:

      Yes, that is too much to ask. The Arduino gives you a taste of the power of embedded system. If you need something with the specs you’ve listed but don’t need embedded Linux just build your own.

      If you have the skills to actually use the features you spec’d it should be trivial for you to design and populate a board.

    • Jan says:

      Look at some of the smaller ARM chips like the STM32F10x or STM32F30x series. They cost peanuts, run up to 150MHz, have tons of I/O, decent amount of on-board RAM and some have external memory interfaces, so adding more is not a problem.

      • a1cypher says:

        They also have a lot of lovely features like DMA and an FPU that works with pretty much all of the internal peripherals.

        I’ve used the TiVA (same renamed chip as the stellaris launchpad) and its great because you can setup an ADC sequence that automatically samples periodically and copies the results to memory with DMA. So you just get an interrupt every time you have a new value in memory ready to use.

    • Chris C. says:

      This is why people tend to pair a Linux device with an MCU (like a Pi and an Arduino).

      Running a complex OS lets you easily take advantage of a complex and powerful processor. And gives you ready-made drivers to access consumer peripherals that can do something useful with all the data it will be processing. But pretty much precludes generic real-time I/O.

      Combine the two and get the best of both worlds. I’ve been pairing older used Pogoplugs with a bare PIC. About $25 for the combo, and I get all the CPU and RAM, plus high and low level connectivity, I need.

      Of course there is no requirement to run Linux on a Pi or other device which would normally run it. You could always code bare metal, and then you can do whatever you want with all its capabilities. Is that too much to ask? ;)

    • chango says:

      BeagleBone Black @ $45.

      Tons of IO, some IO routable to one of the two DMA capable 200MHz real time coprocessors (PRU), 512MB RAM, 2GB onboard flash plus microSD, 1GHz Cortex-A8, HDMI out, Ethernet, USB HS host and device, onboard power controller with soft power off support and LiPo/LiIon charging.

      Debian, Android, Ubuntu, and many more Linux distros supported by a large community. Almost all code open source (GPU lib and power management coprocessor blobs, both optional), all design files open source, and all parts can be sourced in onesies.

    • Sweeney says:

      Well, there’s the latest STM F4 Discovery board, it comes with 2GB of flash, 256K of onboard and 8MB of external RAM, a 2.4″ LCD screen with touch encoder and an ARM M4F (with hardware floating point) @180MHz for less than £25

    • jdarling says:

      Not at $30 USD but you can for $60 to $100 depending on how much support you want.

      PhonenixA20 $60 <- Very poor support
      CubieTruck $100 <- A20 based alternative with what appears to be good support
      RadxaRock $100 <- Very green board with a growing community

      Then there are any of the Arduino "compatible" boards with an ARM on board.

    • thedoktorj says:

      Check out the PCDuino on SparkFun. It meets these requirements and even let’s you code in Arduino-like C++.

    • F says:

      STM32F429Discovery:

      lots of IO – check
      fast processor – check
      megs of ram – check
      for $30 or so – check

  3. MRE says:

    GOOD LORD how many app tabs does he have open at the bottom of his screen?!

  4. Mike Szczys says:

    When all of the college student rental leases expire in August you can walk down the street and find old PCs waiting for the garbage man. I usually pop the case off the side and see if I can get some memory, hard drives, optical drives, etc. for my junk bin. The memory interface makes for a fun weekend project, and I don’t feel bad soldering to the DIMM (yes, you can do this with somewhat more modern memory too) just for kicks since it was going to be ewaste anyway.

  5. Jan says:

    My God, people WHY?!? Why to add RAM in this way? You get a bit more RAM, but basically make the controller useless, because it is wasting all time refreshing the DRAM and all its pins are taken up by the RAM interface …

    This sort of thing has a value only as a neat hack demonstrating that it can be done, but its practical value is zero. The first thing to do if you need more RAM is to look whether you can can get static RAM – they cost only a few bucks these days in megabyte capacities. Of course, a sensible person would use a serial RAM on this type of micro, not a parallel one.

    An actual engineer would choose a controller with enough RAM or at least something that has an external memory interface option (some larger ATMegas or XMegas have it, then many of the small ARM micros do as well).

    Mind-boggling, honestly …

    • Trui says:

      You must be fun at parties.

    • DainBramage1991 says:

      “This sort of thing has a value only as a neat hack demonstrating that it can be done”

      There you have it in a nutshell, Jan. Some folks enjoy doing proof of concept stuff, myself included.

      • I do this for a living says:

        Like seeing if you can screw your feet down to the floor using sheet rock screws and a gold ol’ manual screwdriver… Completely pointless and hours of pain and frustration all so you can say “I new I could do it!” and hopefully post it to youtube to impress your hipster friends.Just imagine if these people dedicated all that effort and brain power into something useful!!! We might have a cure for Cancer!? If only grandma would have let you come up from the basement! But then we’d have fewer pictures of cats with bread mushed over their cute little heads and less arduinos running TRS-80 emulations. Super important ground breaking and fun stuff!

        • Torque says:

          Get a load of this guy.
          Bet he’s the center of attention at every party he attends

        • Drake says:

          With some hardware modifications you can free up a bunch of pins as well as cycles. You always need a proof of concept before you can advance or at a minimum see if it is viable to advance

          • I do this for a living says:

            Or, I dunno, you could save all that effort and get some modern chips that save 50 or 60 pins, have a nice compatible SPI or I2C interface – built in no less, is static RAM so you don’t have to worry about losing data and refreshing DRAM constantly and you can use the full memory without resorting to all the gotchas of above. Engineers somewhere have already solved all of these problems, packaged them in a nice little IC at a dollar or two a pop. But forget all that! Proof of concept? The fact we were using these in 486’s in 1980 something is your proof that they once worked, and man moved on. Or is it just stabbing in the dark like a mad man at something that, yes is possible, but makes you look like a raving lunatic for trying when there is a better way and has been for years? Don’t let me stop you from trying to turn the earth backwards, But here’s a chisel and a big lump of rock, now go make a better wheel or something…

          • please link me to a $10(how much that SIMM stick costs) SPI RAM in the 16MByte range. please!

        • Trui says:

          If there was pain and frustration involved, it was not pointless, because some experience has been gained.

        • BJ says:

          Darn, and I like TRS-80 emulators.

        • OtherPeople says:

          The point is learning and experience. There’s no need to reinvent the wheel, but you can’t design the next big sports car if you don’t understand wheels.

          • DainBramage1991 says:

            This.

            Precisely.

            Because not all of us have reached the status of “Advanced God” when it comes to electronics.

    • OtherPeople says:

      I thought these old rams were static not dynamic. Also the pin count could be reduces by using shift registers for more of a serial interface.

    • What an incredibly misinformed comment!

      It only takes 2% of the cpu time to refresh the RAM in ASM version (i wrote it, i know)
      and there isnt another easy way to get 16MB of ram attached to an AVR easily
      so for 2% loss of performance you get access to 16MB of ram. sounds pretty useful to me. like for example the linked linux project used it :)

    • NewCommentor says:

      my god why the fuck does clothing store sell clothing?
      BECAUSE ITS A CLOTHING STORE

      this site is devoted to DIY andor “because we can”

      this site, BTW, is called HackADay, get it?
      hack, as in poorly executed modification FFS
      nobody is forcing you to read this site EVERY DAY.

      you keep coming back to post, every day about how this site is not good enough for you. so stop coming back and seek mental help.

      this site is devoted to it and you will never change that.
      we come here to share non practacle projects because we all like reading about non practacle things.

      YOU are the weird one here! YOU are the misfit here!
      WE already know its a hack,
      WE figured this because this site’s name is HACKADAY!

      WARNING THIS CONTENT MIGHT NOT STAND UP TO YOUR STANDARDS!
      ENTER AT YOUR OWN (risk? lol)

      remember, we do not owe you anything.
      don’t act like you already paid us to come up with a solution.

      and of course your right, its all just a huge conspiricy
      to get you to do shoddy work on the job. (facepalm)

  6. somsof62 says:

    @MRE exaclty thought the same thing when I saw this post :D, i have the same modules lying around and tried to interface them with an arduino mega2560, but didn’t get it working

  7. Sweeney says:

    23LCV1024? SPI Serial SRAM chips with 128KB of capacity that cost about £3 each in lots of 1. No worries about the number of available IOs or keeping DRAM refreshed, and they are available in DIP packages for easy use in hobby projects.

    • F says:

      Yeah, SPI SRAM is the way to go here. No question. This is a fun hack but not very practical. Or FRAM, if you want persistence.

    • Got a link for 16MByte spi rams at reasonable prices?

      • Greenaum says:

        Just to prove a point, you can get 1MByte for about 2 bucks at some of the usual sites. Don’t think they make 16MBytes in that format, but still, it’s in the same sortof ballpark. And 1MB of RAM on a serial connection is probably more use for a microcontroller than 16MB that uses up all the I/O pins.

        Then again there probably aren’t many uses for 16MB of data on a microcontroller like that, otherwise they’d make them that way. It’s a proof of concept, and I suppose managing the refresh in software is quite clever. But just about nobody connects RAM chips up to MCUs, it’s the opposite way of thinking. For the money and the hassle you’d just buy the right chip in the first place.

        • bootstrap says:

          Getting linux to run on a micro like a CortexM3 takes megs of RAM. The docs for uClinux say a 2MB min, other places say 4MB or even 16MB is required. Have a read of [link]http://electronicdesign.com/embedded/practical-advice-running-uclinux-cortex-m3m4[/link] for the why and how. Short answer: cost, power consumption, I/O flexibility, etc

        • Dmitry Grinberg says:

          So, for 16MByte, in fact this is cheaper? thanks for proving my point. i appreciate it.

          • Greenaum says:

            Probably about half or a third of the price. So yes, if you wanted 16MB RAM on an 8-bit MCU with only a couple of pins for actual I/O, then yes, this would be cheaper. Assuming you have a source of obsolete memory from 15 years ago. And you add something to provide the extra pins so you can have more than 256K.

          • Greenaum says:

            Finally, to be fair, we should be comparing prices of 15-year-old obsolete parts you can probably pick up as scrap, rather than new, modern parts.

  8. Nimajamin says:

    Could use latches to page the higher address ranges? – and, or use an Arduino Mega with more pins?? Perhaps use the Xmem system.. Ahh.. here’s the link: http://hackaday.com/2011/09/05/upgrading-ram-in-an-arduino-mega/
    ..one could pull the same trick using these larger rams.

  9. Torque says:

    I’m still amazed about that there isn’t a official Arduino based on the DIP version of ATmega1284P

    http://maniacbug.wordpress.com/2011/11/27/arduino-on-atmega1284p-4

    • F says:

      Are you also amazed that ford has not lately introduced an update to the model T?

      ATmega is pretty much deprecated for new designs. Sure people will continue to hack on it but anyone starting from scratch will be much better served by more modern architectures like ARM.

      By the way you can get some very powerful ARM and MIPS processors that will blow away any atmega chip and will fit into the same form factor. See Teensy 3, mikroe-1367, fubarino for examples. These all make atmega look sick in comparison.

    • justice099 says:

      There likely isn’t much money in it because when they use DIP versions, people can easily just build their own boards or breadboard it. Notice that the ‘duinos have been migrating mostly to SMT packages only. With the exception of the original Uno, of course.

      So, why go through all the effort of officially designing something and coding in official support when most people wouldn’t buy the board? Especially when you already have the Mega?

      As you already linked, several people have already unofficially supported it. I was actually one of the people that helped put it together (though I think maniacbug was working independently on his own, IIRC.)

      The QFP version of the 1284 gives you some more IO. You can find dev boards with all the plugins for the Arduino IDE.

  10. Genki says:

    Good thing I save old memory. If I can find SIMM Tree or SIMM Stacker, I can put 4x4MB into Arduino and get 16MB!!

    • Greenaum says:

      Aaah, I remember those! Remember RAM compression software, too? For Windows 3.1. Use compression to have your 4MB RAM act like a very slow and diseased 6MB RAM! SOMEbody bought it! Back at the height of RAM pricing, just a little while before VLSI chips adopted the pricing model of jellybeans. Actual sugar ones. The RAM famine of the early 90s, it was terrible!

  11. argoneum says:

    It’s even easier with SDRAM. It has self-refresh mode, burst mode, so very little job is required to make a use of it. Also timings are not very critical (e.g. clock signal doesn’t need to be stable, and memory can survive more than datasheet says without refreshing). I wonder why people are afraid using those. Too dense pins maybe?

    • Greenaum says:

      Needing 130-odd pins wiring up is probably a hindrance to the hobbyist market, and the borderline-magickal routing requirements. Also the baroque clock-multiplied data signals and whatever else. Can they even run at speeds below 600MHz or so?

      • tekkieneet says:

        > Can they even run at speeds below 600MHz or so?
        You are thinking of DDR with terminations. They are both clock edges, so actual clock rate is 1/2. I think you can get DDR 400 i.e. 200MHz parts (or slower parts?)

        SDRAM (without DDR prefix) come with 3.3V TTL signals, so they don’t go above 200MHz. You can probably find them in embedded system or really old hardware running at 66MHz.

        There is probably some lower limits on how slow the CLK can run at or otherwise stuff like auto refresh won’t refresh fast enough. If you want to play tricks with CKE can be used to effectively slow it down, but keep the CLK running fast. This is not for bit-banging in software.

    • rasz_pl says:

      voltage for starters, at this point there is no reason not to use fpga

    • tekkieneet says:

      1. 3.3V logic level
      2. Larger RAM array, so more rows to refresh. Higher overhead. ~15.6us per row
      3. Commands are synchronous, so you’ll need extra cycles to toggle the clock. No you can’t just hook up the clk to PWM etc because commands and latency are *synchronous* to clock.
      4. Auto refresh cycles still needs the clock.
      5. Larger memory array means you are burning up lots of I/O and they need to be fast – can’t be from SPI or I2C. (to satisfy #2.) Can’t simply tie them to fix level as the address pins are also used for sending commands.

      Between 2 & 3, you are spending a lot of time talking to the chip.

      it is easy to do it in a CPLD/FPGA, but a waste of time if you have to bit-bang in software. Not sure why anyone want to access large memory array in a 8-bit processors. Use a 32-bit processor with external memory interface and get compiler support.

  12. ndb says:

    The idea of doing this with an AVR is at least 10 years old though. I think elm-chan should get some cred here too ;-) http://elm-chan.org/works/vp/report.html

  13. agtrier says:

    I must have a ton or so of old SIMMs that I really should have thrown away ten years or so ago. But now I’m glad I didn’t :-)

  14. Rob says:

    Haven’t had such a good laugh for years…. Keep up the good work, ALL of you!!!
    Soon people will be lasering 386’s to make ARM chips…..

  15. janostman says:

    The arduino due has plenty of IO for interfacing.
    And the speed for refreshing as well.

    Otherwise use the 644 or 1284 for the full 16MB.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.

Join 93,736 other followers