Jump to content

As of July 17, 2015, the LabJack forums here at forums.labjack.com are shut down. New registrations, topics, and replies are disabled. All forums are in a read-only state for archive purposes.

Please visit our current forums at labjack.com/forums to view and make new posts. To post on the current forums, use your labjack.com login account. Your old LabJack forums login credentials have been retired. There are no longer separate logins for labjack.com and LabJack forums.


Photo

Max Speed for I2C


  • Please log in to reply
3 replies to this topic

#1 MarcoAndarcia

MarcoAndarcia
  • Members
  • 17 posts

Posted 15 March 2013 - 02:35 PM

Hi, I am trying to interface my PCF8575 16 bit IO expander with my labjack. I am going trough the user guide of the labjack, and I can't find at which speeds the labjack runs. I know the PCF runs at 400 KHz, on the .NET exmaple ofr the I2C it says that the maximum speed is 130KHz but since I don't see it in the datasheet I don't trust it. Thanks in advance.

#2 LabJack Support

LabJack Support
  • Admin
  • 8677 posts

Posted 15 March 2013 - 04:30 PM

I2C on the U6 is software generated. 130kHz is about as fast as it can go.

#3 MarcoAndarcia

MarcoAndarcia
  • Members
  • 17 posts

Posted 18 March 2013 - 08:24 AM

I2C on the U6 is software generated. 130kHz is about as fast as it can go.


I am trying to find what are the speeds for the I2C on the LAbjack but I can't find it on the datasheet. I want to set the I2C to 100KHz. i know the function to set it up on C# is
//0 is max speed of about 130kHz
LJUD.AddRequest(LJU6.ljhandle, LJUD.IO.PUT_CONFIG, LJUD.CHANNEL.I2C_SPEED_ADJUST, 0, 0, 0);

from the examples folder.

Thanks in advance.

Marco.

#4 LabJack Support

LabJack Support
  • Admin
  • 8677 posts

Posted 18 March 2013 - 08:39 AM

Keep in mind that your I2C chip is specifying the max speed. If it says it will work up to 400 kHz, then it should be fine with 130 kHz.

If you want to get closer to 100 kHz for some reason, I would try values from 1-19 and see what is closest. Section 4.3.11 refers you to Section 5.2.12 which has the following description:

SpeedAdjust: Allows the communication frequency to be reduced. 0 is the maximum speed of about 150 kHz. 20 is a speed of about 70 kHz. 255 is the minimum speed of about 10 kHz.



BTW: For digital expansion or multiplexing, we and customers have used a port expander IC. SPI is generally simpler and easier to troubleshoot than I2C, so we have used the MCP23S17 before:

http://ww1.microchip...eDoc/21952b.pdf


0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users