I2c Studio,I2C technology and applications FAQs

Otherwise, if this error occures although I2C Studio is not installed on your computer, please deinstall the “Visual Studio C++ 2015 Redistributable” via “Control Panel|Software” and then run the Setup again.

Can I add my own test cases into the I2C Studio GUI for the Negative Tester?

Typically the users of the Negative Tester are using the GUI for their first tests. Afterwards the customers typically write the own test cases use the I2C APIs. Most users integrate these test cases into their own testing framework, which communicates with the Negative Tester on one side and with the DUT on the other side.

There are two versions of the I2C.NET API: i2capi_dotnet_net20.dll and i2capi_dotnet_net40.dll. Which one should I use?

This depends on the used runtime environment. Applications using .NET 2.0, NET 3.0, or NET 3.5 should use the i2capi_dotnet_net20.dll. For .NET 4.0, NET 4.5, and .NET 4.6 you will need the i2capi_dotnet_net40.dll.

I am using I2C Studio on a PC without an Internet connection. I2C Studio starts unexpectedly slow. During the start-up my PC tries to connect “crl.globalsign.net”.

All executables of I2C Studio have been signed with a digital signature. This digital signature has been issued by Globalsign. Windows tries to read the “Certificate Revocation List” from the CRL server of Globalsign.
This default behaviour of Windows can be disabled using the “Internet Explorer”. Go to “Tools/Internet Options” and choose the “Advanced” tab page. Here you can change this behaviour with the check box “Check for publisher’s certificate revocation”.

When I try to open a new window in I2C Studio I get an error message like “I2C scheduler does not respond”. What is the I2C scheduler and what is the reason for the I2C scheduler not to answer request of I2C Studio?

I2C Studio does not communicate directly with the drivers of the I2C boards. Instead I2C Studio communicates with the I2C scheduler. The I2C scheduler acts as a kind of multiplexer/demultiplexer (connects I2C boards and I2C software clients).
I2C Studio and the I2C scheduler are using a TCP/IP connection (local loopback device, port 3000) for the communication. Maybe there is a firewall software on your PC which blocks this TCP port and makes it impossible for I2C Studio to communicate with the I2C Scheduler. Another reason could be another process, which uses the same TCP port.You could use a tool like TCPView to monitor the used TCP ports.

When entering addresses in I2C address fields a dialog pops-up providing different kinds of I2C address formats as 7, 8, 10 bit in decimal / hex or binary notation.
To supress the pop-up please click the checkbox in the dialog. To re-enable it use the checkbox in the I2C Studio-options accessible from the toolbar via “Options/I2C Studio”.

I want to keep track of the number of NAKs returned from our test board via the Tracii XL. Currently an exception is thrown and the program exits. I need to be able to detect a NAK, increment a counter, and then return to the program where it left off. I do not want it to exit because I want to know how many NAKs I get after 1000 writes and reads. How do I do this?

You simply have to use the try/catch commands of C++ or C#. You can increment a counter in the catch handler.
How do I exit the catch without exiting the program? I want to catch the NAK, increment the counter, and then try again. Can I use a goto statement? I am not familiar with object oriented programming. I prefer in-line code like C and assembly. They are much more straight forward.
As most software is written today using OOP languages, we do not support ANSI C.
I would recommend to have a look into a C++ book for beginners. Maybe Bruce Eckel's free “Thinking in C++” book could be interesting for you:http://mindview.net/Books/TICPP/ThinkingInCPP2e.html

I am not familiar with C# nor .NET code. I know C and assembly only.I need example I2C code written with the I2C Studio script that communicates with the Tracii XL at various bitrates between 100K and 105K and writes/reads 16 bytes for 1000 loops and keeps track of NAKs and displays the results.Are there any examples that I can use?

If you know C, I would recommend to use the C++ API of our products.
There are examples in the documentation (in the installation directory). I would recommend to have a look to the master example.

This is a valid bitrate for the Tracii XL, so why do I get an error message?

Please, read the I2C.NET API documentation.
The HardwareInfo::master_sampling_rate array list does *not* contain the value “105260”. So it is not a valid speed for the XL hardware. You could use for example “105263” with Tracii XL.

Why do we not list all the possible bitrates?

Well, there are up to 2^16 valid values and these values depend on the used I2C board. All valid values for a board are stored in the mentioned variable. So output the variable and you have the bitrates you can use.

I need to be able to set the I2C bitrate between 100000 and 110000, but I get an invlaid master.bitrate when I run the MasterExample.cs code with anything other than 100000. What are all the possible I2C bitrates? Why are they not the same as those used in I2C Studio?

The possible values for the bitrate depend on the used telos I2C Interface. The possible values can be determined using the “HardwareInfo” object, which can be received using the Board.HardwareInfoOfOpenBoard property.
All bitrates are stored in the master_sampling_rate array list (see documentation of I2C.NET API)

I am using telos Tracii XL 2.0. There is no documentation for the master_sampling_rate that came with the I2C Studio. There is just this code sample:

The two wire interface (TWI) is used by several companies including Atmel. Even though this is not officially mentioned, the two buses are compatible with respect to practical use. Since the I2C name and logo are protected by Philips, the “new” name might have been choosen for non-technical reasons. In addition, the I2C specification includes a number of features which are rarely used e.g. 10-bit addressing, general call etc. The TWI cores may not support these features.
We found that there are no problems related to connecting EEPROMs, digital potentiometers and other slave devices to an Atmel TWI-enabled microcontroller. It is also possible to use telos Tracii XL to monitor the TWI traffic.

The I2C bus can be used for on-board communication as well as for talking to externally connected devices. In the latter case a cable is used to connect the two or more ICs involved in that communication and one frequent question we receive is: “What is the maximum cable length for this purpose?”

There is no such thing as an absolute maximum distance between two I2C bus devices, however, there are two major considerations.

Capacitance

The I2C specification defines a maximum capacitance depending on transmission speed. Up to 1.7 MHz (which is well in the high-speed range) this maximum is at 400 pF. This limit drops dramatically at higher speeds.

Our experience shows that these ratings are not just safety suggestions, but hard limits. 400 pF is not that much if you keep in mind that each and every component connected to the bus adds to this “pollution”. Yes, even connectors and cables.

You can buy a round cable with approx. 40 pF per meter and this is about as good as you can get. In other words, one meter of cable brings you 10 % closer toward the absolute limit.
If you consider that 100 to 200 pF are easily added by typical I2C components (controllers, radio and TV chassis etc.), it is obvious that the cable length is a critical factor in communication.

I2C Protocol

Unlike other bus systems like CAN the I2C bus does not provide error checking and/or recovery mechanisms making it necessary to implement this functionality in higher protocol layers.
This often means in practice to read back the contents previously written to a device and checking for equal values.
If such a test fails, it means that considerable writing and reading needs to be repeated.
This may be fatal in a time-critical environment. Therefore, it is wise to calculate a generous safety margin when it comes to electrical limits.
Long cables are frequently subject to EMC influence and should therefore be avoided whenever possible.

As a rule of thumb I2C cables should be as short as possible but not longer than one meter.
By the way: telos Tracii XL has been designed for low capacitance and adds only 50 pF to the bus.

For lab environments where occasional errors are acceptable we heard of set-ups with 4 meters of cable length. This is certainly not advisable.

We recommend to use USB devices like telos Tracii XL 2.0 or telos Connii MM 2.0 in conjunction with an active USB extension if you need to place your I2C equipment apart from the PC. With this method you can easily reach 5 to 7 metres and there are even solutions for 50 meters.