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

I2C Master-Slave Inquiry

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



Joined: 13 Sep 2003
Posts: 87

View user's profile Send private message

I2C Master-Slave Inquiry
PostPosted: Mon Jun 06, 2005 7:49 am     Reply with quote

I understand there are mnay information about I2C in this forum. Anyway, my question: Is it possible to communicate two PIC one master and one slave using software based I2C implmentation?

Wud the code provided by Mark can be a gud source of information in doing a software based I2C for Master/Slave communication.

Any suggestion is appreciated.

Thank you.
valemike
Guest







Re: I2C Master-Slave Inquiry
PostPosted: Mon Jun 06, 2005 8:35 am     Reply with quote

ritchie wrote:
I understand there are mnay information about I2C in this forum. Anyway, my question: Is it possible to communicate two PIC one master and one slave using software based I2C implmentation?


The master can use the software-based i2c implementation or the MSSP module implementation. However, the slave must use the MSSP module based implementation.

Quote:

Wud the code provided by Mark can be a gud source of information in doing a software based I2C for Master/Slave communication.

Any suggestion is appreciated.


When Mark posted code for i2c a while back, it is robust in that it handles errors.
Thank you.[/quote]
kender



Joined: 09 Aug 2004
Posts: 768
Location: Silicon Valley

View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger

PostPosted: Mon Jun 06, 2005 10:20 am     Reply with quote

valemike,

Where to look for Mark's code?
Mark



Joined: 07 Sep 2003
Posts: 2838
Location: Atlanta, GA

View user's profile Send private message Send e-mail

PostPosted: Mon Jun 06, 2005 10:56 am     Reply with quote

That would be in the code library. It is written for multi-master. It was not designed to read data back from slaves but rather send a command to the slave and have the slave turn around and transmit data (if required) back. If you are just sending commands then it will work for you.
ritchie



Joined: 13 Sep 2003
Posts: 87

View user's profile Send private message

PostPosted: Mon Jun 06, 2005 4:29 pm     Reply with quote

Mark wrote:
That would be in the code library. It is written for multi-master. It was not designed to read data back from slaves but rather send a command to the slave and have the slave turn around and transmit data (if required) back. If you are just sending commands then it will work for you.


I plan that my slave device will only accept data and never to transmit back.

Accdg, to Valemike I need to have an MSSP module for my slave device since it is is not possible to have a software based I2C on the slave.

The master device is possible to use software based I2C.

Thanks.
ritchie



Joined: 13 Sep 2003
Posts: 87

View user's profile Send private message

PostPosted: Mon Jun 06, 2005 4:30 pm     Reply with quote

Mark wrote:
That would be in the code library. It is written for multi-master. It was not designed to read data back from slaves but rather send a command to the slave and have the slave turn around and transmit data (if required) back. If you are just sending commands then it will work for you.


I plan that my slave device will only accept data and never to transmit back.

Accdg, to Valemike I need to have an MSSP module for my slave device since it is is not possible to have a software based I2C on the slave.

The master device is possible to use software based I2C.

Thanks.
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