PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Thu Feb 19, 2009 6:40 pm |
|
|
Use the CCS example file code, Ex_Slave.c, for the Slave PIC.
It's in this directory:
Quote: | c:\Program Files\picc\Examples\Ex_Slave.c |
Use the code in this post for the Master PIC:
http://www.ccsinfo.com/forum/viewtopic.php?t=32368&start=3
This will show how to write and read a byte between the master PIC
and the slave PIC with i2c.
Make sure that you have pull-up resistors on the SDA and SCL lines.
You can use 4.7K (4700 ohms) resistors. |
|