Shop OBEX P1 Docs P2 Docs Learn Events
Ok....new question.....(I2C) — Parallax Forums

Ok....new question.....(I2C)

James LongJames Long Posts: 1,181
edited 2006-09-30 15:09 in Propeller 1
Ok....for my next major feat....I would like to use I2C.....

Now for the question........

How fast does the Propeller communicate on the I2C network?

This is not that important..... just for information type thing.

I know there are 400kHZ I2C components .....just wondering if the Propeller communicates on the I2C network that fast....or is it throttled down.

James L

Master of questions smile.gif

Comments

  • Peter JakackiPeter Jakacki Posts: 10,193
    edited 2006-09-30 03:37
    It is the master of questions who is sure to become the master of answers.

    The I2C is strictly software and 400KHz is when you hobble a cog, at least in assembler to make it go slow enough so that it's not too fast for the I2C bus.
    So yes, it is throttled down [noparse]:)[/noparse] but not in the way you were asking.

    *Peter*
  • James LongJames Long Posts: 1,181
    edited 2006-09-30 04:10
    Ok...I see....so the I2C object would never run that fast unless it was reassembled in C and run it's own cog.

    So how fast would it run in it's present state....on it's own cog?...I know this is an estimate.....but hey I'm inquisitive.



    James
  • Mike GreenMike Green Posts: 23,101
    edited 2006-09-30 04:27
    James,
    Download a copy of my Propeller OS and look at the module OS_loaderInit. It includes an assembly I2C driver that is configurable to run at 400kHz or 100kHz. The link is <http://forums.parallax.com/forums/attach.aspx?a=9168>. There is one bug that I've since corrected that involves reading from devices that don't use a register address, just a device select code. There also is a bug that I'm still hunting where I2C works fine on pins with pullups on both the clock and data lines (as there is supposed to be). The boot EEPROM on pins 28/29 is treated as a special case because the Demo Board doesn't have a pullup on the clock line and that special case does work, but not if there actually is a pullup. I'll get to that maybe Sunday night or Monday.
    Mike
  • James LongJames Long Posts: 1,181
    edited 2006-09-30 15:09
    Mike,

    I'll check it out.....should be interesting.

    James
Sign In or Register to comment.