Author Topic: Simple arduino parallel EEPROM programmer  (Read 12781 times)

0 Members and 1 Guest are viewing this topic.

Offline jamesglanvilleTopic starter

  • Contributor
  • Posts: 48
Simple arduino parallel EEPROM programmer
« on: May 24, 2014, 09:23:07 pm »
Hi, just thought I'd share a neat trick I've been using to program parallel EEPROMs using an arduino.

AVRs have a lot of flash memory (256k in the case of the atmega2560 I'm using), much more than the EEPROMs I needed to program (16k). You can easily store the whole EEPROM image in flash, and program the device without any messy communications with a PC.

Code is here: (You'll need to modify it to suit your wiring but it's dead simple)
https://github.com/JamesGlanville/eepromprogrammer/blob/master/eepromprogrammer.ino

I needed this for the Z80 machine I'm building (following this: http://searle.hostei.com/grant/cpm/index.html). I couldn't find an existing arduino sketch that suited, a few rely on a clunky pc interface to send the data, or use a bunch of port expanders. I had an arduino mega 2560 on hand so this was a convenient no-component solution. I generate the array at the top of the sketch with some regex in notepad++ from the intel hex files (making sure to strip the checksum and other metadata).

Actually you do need one component, a pullup resistor on the write enable line. That keeps the device from corrupting when the arduino boots up.

Anyway, thought this might be of interest to someone, hope it helps.
 

Offline jancumps

  • Supporter
  • ****
  • Posts: 1273
  • Country: be
  • New Low
Re: Simple arduino parallel EEPROM programmer
« Reply #1 on: May 24, 2014, 09:41:37 pm »
I'm reviewing that same principle on the TI TMS570 µC family.
TI released a library (F021 flash API)  to emulate EEPROM in flash (FEE is the name of the driver, Flash EEPROM emulator). The library is intended to maximise the write/erase cycles and to guarantee the data retention as listed in the processor specs.

The driver works. I haven't been able to test that it meets its specifications (I didn't try 100k write/erase operations on a cell)
 

Offline mariush

  • Super Contributor
  • ***
  • Posts: 5181
  • Country: ro
  • .
Re: Simple arduino parallel EEPROM programmer
« Reply #2 on: May 24, 2014, 09:47:33 pm »
Yes, I guess it works fine as long as you're not going to do over 10k writes in flash.
Even then, you'd probably increase the life by using several 16k segments out of that 256k flash memory.

Still, an atmega2560 is 10-15$ ...

a 256 kbit (32 KB) SRAM chip is $1.27 : http://www.digikey.com/product-detail/en/23K256-I%2FSN/23K256-I%2FSN-ND/2001113   
a 512 kbit (64 KB) SRAM chip is $1.87 : http://www.digikey.com/product-detail/en/23LC512-I%2FP/23LC512-I%2FP-ND/3543089
a 1 megabit (128KB) sram chip is $2.59 : http://www.digikey.com/product-detail/en/23K256-I%2FSN/23K256-I%2FSN-ND/2001113

Couple one of these with a PIC18F that has USB for about 2.5-3$ (incl. the oscillator and a handful or resistors) and you have a programmer: http://www.digikey.com/product-detail/en/PIC18F13K50-I%2FP/PIC18F13K50-I%2FP-ND/2021357

(though i guess if you have to buy a 40-60$ programmer for the PIC it doesn't make sense anymore)
 

Offline sparkyresistor

  • Contributor
  • Posts: 11
  • Country: us
    • Honkey Hacker
Re: Simple arduino parallel EEPROM programmer
« Reply #3 on: May 25, 2014, 05:14:34 am »
What about TI Launchpad as an all in one solution? The 8bit micro version is only about $9, comes with usb, and a whole slew of other functionality, just that you would have to buy another ti chip with the proper amount of flash for around $5 and if you get the code set up, it's damn near nothing to implement. The TI430 chips only need a single resistor on the reset pin, but that's it to run it.
Dumb enough to learn, Smart enough to blow it up! XD
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf