Hi..
I have a problem..
I would like read and write from 16f84 to 24cxx,but I have some problem..
I define the pin for SCL and SDA, and i have use the CCS's driver, but when I use the function read_ext or write_ext in any address, dont write and dont read from Serial eeprom..
Why?
Anyone can help me?
THX!
___________________________
This message was ported from CCS's old forum
Original Post ID: 10624

TomiGuest

Re: Problem with i2c eeprom.. help me...

Posted: Sun Jan 12, 2003 9:23 am

1. Do you have pullup resistors on both SCL and SDA?
2. Did you call init_ext_eeprom() from your early main() ?

:=Hi..
:=I have a problem..
:=I would like read and write from 16f84 to 24cxx,but I have some problem..
:=I define the pin for SCL and SDA, and i have use the CCS's driver, but when I use the function read_ext or write_ext in any address, dont write and dont read from Serial eeprom..
:=Why?
:=Anyone can help me?
:=THX!
___________________________
This message was ported from CCS's old forum
Original Post ID: 10629

PCM programmer

Joined: 06 Sep 2003Posts: 20477

Re: Problem with i2c eeprom.. help me...

Posted: Sun Jan 12, 2003 4:10 pm

:=Hi..
:=I have a problem..
:=I would like read and write from 16f84 to 24cxx,but I have some problem..
:=I define the pin for SCL and SDA, and i have use the CCS's driver, but when I use the function read_ext or write_ext in any address, dont write and dont read from Serial eeprom..
-------------------------------------------------------

What compiler are you using ? CCS or CC5x ?
___________________________
This message was ported from CCS's old forum
Original Post ID: 10632

MONTECCHI lUCAGuest

Re: Problem with i2c eeprom.. help me...

Posted: Mon Jan 13, 2003 3:08 am

I use CCS but isn't a last version, is 3.048.
Yes,I call init_ext,but I have connect SDA and SCL to RB7 RB6 without pull-up resistor.. Is this the problem? I must use a 10k resistor?
___________________________
This message was ported from CCS's old forum
Original Post ID: 10638

MONTECCHI lUCAGuest

Re: Problem with i2c eeprom.. help me...

Posted: Mon Jan 13, 2003 3:10 am

CCS,but isn't last version. is 3.048
___________________________
This message was ported from CCS's old forum
Original Post ID: 10639

TomiGuest

Re: Problem with i2c eeprom.. help me...

Posted: Mon Jan 13, 2003 3:39 am

Yes, you have to use 2.2kOhm or same because those pins are floating.

:=I use CCS but isn't a last version, is 3.048.
:=Yes,I call init_ext,but I have connect SDA and SCL to RB7 RB6 without pull-up resistor.. Is this the problem? I must use a 10k resistor?
___________________________
This message was ported from CCS's old forum
Original Post ID: 10640

R.J.HamlettGuest

Re: Problem with i2c eeprom.. help me...

Posted: Mon Jan 13, 2003 3:47 am

:=I use CCS but isn't a last version, is 3.048.
:=Yes,I call init_ext,but I have connect SDA and SCL to RB7 RB6 without pull-up resistor.. Is this the problem? I must use a 10k resistor?

Yes. I2C, is defined as an 'open collector' drive bus. The chips, provide no 'pull up', and resistors are _required_. The actual value needed will depend on the capacitance of the lines, and the speed required. Normally a value between about 2.2K, and 4.7K, is typical. The bus 'idles' with the lines high, so power is only drawn through the resistors when data is being teansmitted. Without these, the bus will not work.

Best Wishes
___________________________
This message was ported from CCS's old forum
Original Post ID: 10642

MONTECCHI lUCAGuest

THANKS FOR ALL!! Now read and write OK!!

Posted: Tue Jan 14, 2003 1:40 am

THANKS FOR ALL!!
Now read and write OK!!
___________________________
This message was ported from CCS's old forum
Original Post ID: 10674