SamTebbs33
Posts: 4
Joined: Tue May 27, 2014 12:24 am

REPI - Raspberry Pi EEPROM Programmer Interface

Tue May 27, 2014 12:51 am

REPI is a C++ program that utilises the WiringPi (http://wiringpi.com) library to provide a way of programming an EEPROM using the Pi's GPIO pins and an I2C I/O Expander. The current version supports EEPROMs up to 64KB with a 16bit I/O Expander.

Below are the pins that are used by REPI (pin assignments are according to WiringPi):
EEPROM Select: 10
EEPROM Write: 11
EEPROM Read: 12
EEPROM Data: 0->7
I2C Clock: 9
I2C Data: 8
Connect the output pins of the I/O Expander to the address pins on the EEPROM and hook it al up to the 5v and 0v supply from the Pi.

To use the program, navigate to the relevant directory, open up a terminal window and type in "./repi <file_name> <i2c_address> <chip_delay> <verify>" where <file_name> is the input file, <i2c_address> is the I/O Expander's address, <chip_delay> is the EEPROM's write and read delay (in milliseconds) and <verify> is 1 if you want to verify the EEPROM's contents after programming. Please note that the input file must be in raw binary form (not .hex form, use my HexParser program to convert hex files to binary files).

Please note that REPI is in an experimental state and so it may not be fully functional so please test rigourously before using for a serious purpose.

Please see attachments for downloads

Changelog:

v0.2
- Added program verification
- Improved console messages
Attachments
repi.zip
v0.2
(10.13 KiB) Downloaded 183 times

SamTebbs33
Posts: 4
Joined: Tue May 27, 2014 12:24 am

Re: REPI - Raspberry Pi EEPROM Programmer Interface

Tue May 27, 2014 12:06 pm

Updated to v0.2

User avatar
mahjongg
Forum Moderator
Forum Moderator
Posts: 13142
Joined: Sun Mar 11, 2012 12:19 am
Location: South Holland, The Netherlands

Re: REPI - Raspberry Pi EEPROM Programmer Interface

Sun Mar 22, 2015 5:47 pm

I'm interested in this because I need a simple eprom programmer for my ZX81 clone, which uses an 32K x 8-bit EEPROM (AT27C256R).
see http://www.raspberrypi.org/forums/viewt ... 62&t=77429

do you think your programmer is suitable for this task?

However, it seems the information provided here is insufficient, which (two) I/O expanders should be used, you need 15 address lines, so two 8-bit I/O expanders are needed. Which one (base address) must be used for the lower 8 address lines, which base address must be used for the upper (7 or 8) address lines, and in which order are A0 to A-14 to be connected?

You talk about having a converter from hex to binary, but you don't say where to get it (if I need it).

can you say a bit more about the programmer code, is it suitable for an AT27C256R? I doubt it, as you don't talk about switching on any programming voltages! would programming an OTP PROM be possible? how about level shifting issues, considering I'm taking about programming 5V devices.

User avatar
mahjongg
Forum Moderator
Forum Moderator
Posts: 13142
Joined: Sun Mar 11, 2012 12:19 am
Location: South Holland, The Netherlands

Re: REPI - Raspberry Pi EEPROM Programmer Interface

Thu Mar 26, 2015 6:58 pm

I'm guessing that, as you do not provide specific EEPROM programming voltage handler info that the "EEPROM" you were programming is in fact a 5V FLASH device, such as the AMIC A29010A, which is in fact available in a PLCC32, I'll study If I can use such a device in my ZX81+34 as its much more "future proof".
I hope I can build a programmer for it compatible with your code.
Still, I miss info such as what I2C I/O expanders you used, (I'm guessing that I/O expanders of different brands are not 100% software compatible), and details about how (in which order) are addresses coming out of those expanders.
Can scetch up a schematic on how I think it could work with a flash device.

User avatar
mahjongg
Forum Moderator
Forum Moderator
Posts: 13142
Joined: Sun Mar 11, 2012 12:19 am
Location: South Holland, The Netherlands

Re: REPI - Raspberry Pi EEPROM Programmer Interface

Thu Mar 26, 2015 11:46 pm

p.s. No luck with using a flash device with my ZX81+34, its uses a 32KB device , and even then probably need four mirrors of the original 8K code in it. All modern flash devices, if they run at 5V at all, (most run at 3V3) are at least 64KB, and PLCC32 devices from 64K onward have some important pins swapped around compared to 32K (and smaller) devices. so I can't use Flash roms instead of EEPROM's.

now looking for a cheap (around 50 bucks) legacy programmer, like a "williams programmer".

Note to myself, change the design for 64K Flash ROMs in a future revision.

Return to “C/C++”