I2C Slave and 16F84A


Closed Thread
Results 1 to 7 of 7
  1. #1
    Join Date
    Aug 2005
    Location
    Vermont
    Posts
    15

    Question I2C Slave and 16F84A

    Does anyone have any ideas on how to implement an I2C Slave using an 84A? I have read the PBP thread and examples for master/slave and the slave is accomplished using the hardware I2C port. Th 84A doesn't have one. I want to use an 84A for a remote keypad and have the master poll the 84A once in a while to check for keypresses. I would rather not use rs232 if I can avoid it since I already have the I2C and several devices on the bus.

    I would appreciate any ideas.

  2. #2
    Join Date
    Jul 2003
    Posts
    2,358


    Did you find this post helpful? Yes | No

    Default

    This request must be asked at least once every week. Please do a search on the forum for 'I2CSlave' or just the word 'Slave' and you will eventually find links to PBP Code.

  3. #3
    Join Date
    Aug 2005
    Location
    Vermont
    Posts
    15


    Did you find this post helpful? Yes | No

    Default

    Thank you Melanie. I know this has been beaten to death. All the info I have uncovered while searching 'I2Cslave' and 'Slave' etc... Just explains implementing it using the built in SSP. The examples called I2CSlave.bas and I2CMast.bas are great examples but the I2CSlave.bas (unless I am mistaken) uses the SSP of the 16F877. This routine is looking for the SSPIF to be set so it knows to check to see if there is new communications for the slave. Without an SSP I don't see how to implement a slave using this as an example. I'm sure I'm missing something important here. I'll keep studying this. Thanks.

  4. #4
    Join Date
    Jul 2003
    Posts
    2,358


    Did you find this post helpful? Yes | No

    Default

    I wouldn't say there are LINKS TO PBP CODE if there wasn't any...

    http://www.picbasic.co.uk/forum/show...ighlight=Slave

  5. #5
    Join Date
    Oct 2004
    Location
    Hangover, Germany
    Posts
    289


    Did you find this post helpful? Yes | No

    Default

    Hello Melanie,

    MITH just doesn't want to realize, that an 16F84 can't run as a I2C-slave !
    There is no software-solution for I2C-Slave for any PIC!

  6. #6
    Join Date
    Sep 2004
    Location
    montreal, canada
    Posts
    6,898


    Did you find this post helpful? Yes | No

    Default

    I disagree, everything is possible. It's just not one of those COPY/PASTE solution.

    Usually, those who did will keep it for them. As GLCD and such other.
    Steve

    It's not a bug, it's a random feature.
    There's no problem, only learning opportunities.

  7. #7
    Join Date
    Aug 2005
    Location
    Vermont
    Posts
    15


    Did you find this post helpful? Yes | No

    Default

    BigWumpus, it's not that I don't want to realize it. It's that I didn't realize it. I went back again to the link that Melanie sent and looked line by line at the code there and now I understand the limitations to the 16f84. I wasn't trying to be a burden. I thought when I etched my board that the 84 would be adaquate but it just isn't up to the task.

    Thanks again Melanie. Your posts are always the most educational. I especially like the RTC example!

    Mith

Similar Threads

  1. Adventures in I2C Communications...
    By SmugWimp in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 5th February 2009, 13:16

Members who have read this thread : 1

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts