Jump to content

Hooking Up An Eeprom To A 16f877a

Recommended Posts

I have the chip's SDA and SCL lines connected to my 16F877A pins, A0-2

and WP are grounded, and I have the pull-ups in place. When I use

hardware mode, my entire program fails to run, and when I use the software

mode it runs, it fails to write (or fails to read) the data back from the

eeprom (just returning all bytes as 0xFF). I am using a hardware code of

1010b as defined in the eeprom's notes. Do I need to configure the PortC

ports myself, or is it just suffiicient to call i2c_init.

Link to post
Share on other sites

I have taken the i2c example code and included it in with some code for RS232 (from and MAX7219. It uses the i2c_init and readXEE and writeXEE from the i2c example shipped with SB combined with the code from serial_test.c and some code I grabbed from the web for the 7219.




What code are you using for i2c comms?





Link to post
Share on other sites
  • 1 month later...

Join the conversation

You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...