I2C with any PIC?


Closed Thread
Results 1 to 13 of 13

Hybrid View

  1. #1
    Join Date
    Aug 2006
    Location
    SWITZERLAND (french speaking)
    Posts
    938

    Default I2C with any PIC?

    Hello,

    I'm not used to handle I2C communication.

    In several datasheets, I've seen some specific information about the I2C capability of this or that chip.

    My question is: what makes the difference between PICs that have a I2C capacity described in their datasheet and the other ones that don't?

    (...i just have the feeling my question is not clear enough...)
    Roger

  2. #2
    Join Date
    Feb 2005
    Location
    Kolkata-India
    Posts
    563


    Did you find this post helpful? Yes | No

    Default PBP uses a software I2C

    Hi,

    PBP uses a software based I2C so it does not actually matter if your chip has an onboard hardware I2C. It will never use it.
    Regards

    Sougata

  3. #3
    Join Date
    Aug 2006
    Location
    SWITZERLAND (french speaking)
    Posts
    938


    Did you find this post helpful? Yes | No

    Default

    Thanks Sougata,

    This is what I thought since I use a 12F675 and a 24LCxxx memory via I2C and this PIC has no specific I2C interface (...and, of course, it works).

    So what is the "advantage" or simply the reason for certain PICs to have a I2C interface?
    Roger

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


    Did you find this post helpful? Yes | No

    Default

    well, usually faster than most software solution, usually provide interrupts triggers, etc etc etc. Same for USART (HSERIN/HSEROUT) against SEROUT/SERIN etc etc.
    Steve

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

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


    Did you find this post helpful? Yes | No

    Talking

    ...just try to code a slave-I2C !

    Then you will see, what advantages a hardware-modul can give to you !

    ...and it gives you so much performance, if you use the hardware in an intelligent way!
    PBP 2.50C, MCS+ 3.0.0.5, MPLAB 8, MPASM 5.14, ASIX Presto, PoScope, mE mikroBasic V7.2, PICKIT2

  6. #6
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by BigWumpus View Post
    ...just try to code a slave-I2C !

    Then you will see, what advantages a hardware-modul can give to you !

    ...and it gives you so much performance, if you use the hardware in an intelligent way!
    Somewhere out there, is a site with practically complete I2C-slave code, uses the hardware and PBP to handle things. Apparently it works like a champ. A 2nd PIC18F452 is slave-I2C programmed to act just like a 24LC256 and it's accessed by the 1st 18F452 using PBP's I2C commands. Wish I remembered where that was...

Similar Threads

  1. I2C Master/Slave 16F88/16F767 working code
    By DanPBP in forum Code Examples
    Replies: 2
    Last Post: - 23rd October 2012, 22:31
  2. HARDWARE I2C SAMPLE CODE question
    By Michael Wakileh in forum Code Examples
    Replies: 2
    Last Post: - 16th June 2009, 21:07
  3. I2C Master Slave issues.
    By cpayne in forum mel PIC BASIC Pro
    Replies: 9
    Last Post: - 29th March 2008, 19:33
  4. Use pic as slave in I2C
    By robert0 in forum General
    Replies: 2
    Last Post: - 3rd February 2006, 19:26
  5. Adding a pic in I2C network....
    By robert0 in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 2nd May 2005, 12:07

Members who have read this thread : 0

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