Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

I2C problem also mis-behaving code PIC16f876a and 24c512

Status
Not open for further replies.

embpic

Advanced Member level 3
Advanced Member level 3
Joined
May 29, 2013
Messages
742
Helped
80
Reputation
160
Reaction score
77
Trophy points
1,308
Location
india
Visit site
Activity points
5,213
I am getting problem while interfacing EEPROM and 16f876a pic controller.I am using MPLAB X IDE and XC compiler.
I have pulled up SDA and SCL with 4k7 resistor.

and also i use function and after blink port with 0x55 and 0xAA in infinite loop.

If i simply use functions
write_eeprom();
read_eeprom();

then LED doesn't get blink for that much delay it just blink for few part of second.

and if i comment the function then it wait for that much delay.
i have posted code here.
 

Attachments

  • I2C_EEPROM.rar
    60.1 KB · Views: 57

Which code did you post, the working or the not working one?

In the posted code, the watchog triggers during your homemade delay.
 

sir this code is not working.
while doing write eeprom and read eeprom controller not working properly even though function finished and entered to infinite loop.
 

what config should i set?
and how i could debug this program as we in KEIL means to check SFR and other bits?
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top