CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

Program I2C device

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
edi



Joined: 22 Dec 2003
Posts: 82

View user's profile Send private message

Program I2C device
PostPosted: Wed Mar 02, 2005 9:45 am     Reply with quote

I use the 12F629 & exteranl I2C eeprom (of 8Kb or 16Kb)
Can someone please recommend a way I can program the device without external programmer.
I have a text file with 1000xbytes, and I want to program these bytes to the I2C eeprom.

Thanks in advance.
Humberto



Joined: 08 Sep 2003
Posts: 1215
Location: Buenos Aires, La Reina del Plata

View user's profile Send private message

PostPosted: Wed Mar 02, 2005 10:24 am     Reply with quote

I made a program that using a terminal to dialogue you can read/write
strings of 16 char long in an external 32K Flash EEPROM .

I made a Menu like this:

1) "R/W?" (expect 'R' 'r' 'W' 'w' ONLY)
2) address: _ _ _ _ (expecting 4 digits)
3) after received 4 digit confirm this showing on the screen

If selected WRITE:
4). If ok, pressing ENTER will validate the address
.... If wrong address, pressing ESC go to step 2.
5) "Text":[_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _] Here you need a char counter
and keep the string <= 15, after completing the line generate a CR/LF
and position the cursor in next line column 0 after auto-increment the
address and so on...


If selected READ:
4) Read the addressed location and show in screen.
..."SMILE YOUR WIFE" (pressing ENTER auto-increment address)
..."LOVE ME..." Cool
5) Pressing ESC go to step 1.



Humberto
edi



Joined: 22 Dec 2003
Posts: 82

View user's profile Send private message

PostPosted: Thu Mar 03, 2005 1:27 am     Reply with quote

Thanks,

Can you post the code please.

Edi
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group