PDA

View Full Version : Programming IC2 24LC256



Squibcakes
- 18th September 2006, 07:44
Hi,

I'm trying to pre-program my IC2 eeprom using winpic800.

Apparantly this program can program IC2 devices but there is no help info on the hardware setup.

Has anyone done this before?
Cheers
Squib

Sphere
- 18th September 2006, 12:26
What programmer are you using with winpic.
Sphere....

Squibcakes
- 18th September 2006, 21:34
Looks like Winpic800 is a bit buggy... it works well using IC-prog -D... using my very simple 3 resistor programmer. :P

Have a great day.

Cheers
Squib

Sphere
- 19th September 2006, 01:23
I have a jdm myself, but I have used a SN7407 to buffer the signals to eliminate programing errors. Glad to see you sorted your problem.

Sphere...

Darrel Taylor
- 19th September 2006, 01:42
Yo Squib,

3 resistor programmer

Is there a link to more info on this? I've spent almost $300 on 3 different programmers.

Just feel like kicking myself in the ___, for not knowing.
<br>

Squibcakes
- 19th September 2006, 03:56
Yo Squib,

3 resistor programmer


<br>

DT, its kinda in my head, but based loosly on my simple programmer http://www.picbasic.co.uk/forum/showthread.php?t=703 the only difference is that VPP is not connected, so infact you only need two (2) resistors and a 5 volt supply.

Here's a cut and paste from the top of my code.....

' TO PROGRAM THE 24LC256 MANUALLY USE ICPROG-D. SELECT THE AT24C256 CHIP
' CONNECT TO SERIAL PORT USING SIMPLE PROGRAMMER
' CONNECTIONS:
' PIN1:PIN4 TO GROUND
' PIN5 TO DATA (DTR via 4.7k) + (CTS)
' PIN6 TO CLOCK (RTS via 4.7k)
' PIN7 TO GROUND (FROM MAIN PCB AND SERIAL PORT GROUND)
' PIN8 TO VCC (FROM ext 5V)

Cheers
squib

Squibcakes
- 19th September 2006, 05:47
Here's a funny one,

I was hoping to use both an LCD (4bit mode) and the above mentioned eeprom on a 16F88 chip.

Unfortunately, SDA is on Portb.1 and SCL is on Portb.4.

I'm using RA2:RA4 for the LCD contol lines...

How can I simultaneously hook up the LCD data lines and the I2C eeprom to the PIC? I've tried and it doesn't work.

I'm thinking the only way is to go a bigger PIC with more I/O pins.

Cheers Squib.

Darrel Taylor
- 19th September 2006, 09:40
Wow! Thanks Squib.

That just might save me some time programming external EEPROMs for my boards. I've been doing it by writing a program for the PIC that it's attached to. Downloading the data to the EEPROM. Then loading the actual program that will run on the PIC. So I have to load 2 or three programs for each board.

I'm feeling pretty dumb today. :o But tomorrow might be better.

For the combo LCD/EEPROM, I can't think of a good way to do that. I think the LCD data might confuse the EEPROM. Just by chance, it might write something you don't want it to. Or worse, cause a short circuit condition since I2C is "open drain" and LCD data is "driven" high and low. But I can say that you aren't limited to the SDA/SCL pins of the PIC, unless you are using the hardware Synchronous Serial Port to interface with it. The I2CREAD/I2CWRITE in PBP can use any pin.

Thanks again,
&nbsp; Darrel

Squibcakes
- 20th September 2006, 00:36
Hi DT,

Well its good to know we can both learn something new, I never knew we could use any pin for I2C... that helps me out big time now. Thanks buddy.

Cheers
Squib

mister_e
- 20th September 2006, 02:18
Well maybe you just forgot, it have been discussed many times.

I2CREAD,I2CWRITE, SERIN, SEROUT, etc etc, are software solution. AND allow you to use the pin you want. It's no coincidence why you can choose your favourite pin.

HPWM, HSERIN, HSEROUT use the internal Hardware AND don't allow to choose specific pins (except for alternate CCP pin in HPWM)

precision
- 20th September 2006, 03:29
This is also simple 24lc programmer without extrnal power ,with icprog.

Darrel Taylor
- 20th September 2006, 12:16
That's a little more than 2 resistors. But it looks like it might be a little safer with the voltage clamping.

Hmmm, self powered too. http://www.picbasic.co.uk/forum/images/icons/icon14.gif

I think I'll try it.

mister_e
- 20th September 2006, 14:36
You could save few component by using the USB 5V. I already built this interface with USB power and used IC-PROG AND/OR PonyProg for the on-the-road radio decode service. Worked well before i did the decode dongle.