Automotive and Embedded Networks

cancel
Showing results for 
Search instead for 
Did you mean: 

8452 I2C Clock Streching

Solved!
Go to solution

 

Hi,

 

We are looking to emulate a I2C sensor that is doing clock streching while doing his measurement. Does the NI-USB-8452 support clock streching in slave mode ?

 

Thank you 

0 Kudos
Message 1 of 4
(5,469 Views)
Solution
Accepted by topic author blanchards

Hi Blanchards,

 

Our 845x manual states that "the I2C specification provides a mechanism to allow the slave to slow down the bus traffic when it is not ready.  This mechanism is known as clock stretching." Additionally, it states that the behavior is different if the device is in High Speed mode. The USB-8452 is built in accordance with that specification. Therefore, we can conclude that it does clock stretching when necessary.

 

There is an example of the NI-8452 doing clock stretching in the following forum post: http://forums.ni.com/t5/Instrument-Control-GPIB-Serial/Use-NI-8452-be-a-Slave-device-in-SMBUS-NI-845...

 

Please note that the USB-8452 supports the following (as defined in I2C 4.0 specifications):

 

1. Standard mode

2. Fast mode

3. Fast mode Plus

4. High Speed mode

 

The manual I referenced can be found at the following URL: http://www.ni.com/pdf/manuals/371746e.pdf

 

Regards,

 

Kyle S. 
Applications Engineer
National Instruments
http://www.ni.com/support

 

 

 

Message 2 of 4
(5,442 Views)
Solution
Accepted by topic author blanchards

The 8452 as a slave in general ALWAYS does clock stretching. This is how we allow you to respond in real time (vs a predefined buffer). We notify the host of the request and start the stretch. Once the host replies with the requried data the stretch is removed and the data is placed on the bus.

Message 3 of 4
(5,433 Views)

Thank you

0 Kudos
Message 4 of 4
(5,336 Views)