LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to communicate to an I2C device

Solved!
Go to solution

Hi Sir, 

 

I have an i2c interface temperature sensor, I try to use labview to read the value.

 

I buy a usb-to-i2c tool, after installing the driver, i can only find it in "Computer managment":

Brzhou_0-1677470344863.png

But i cannot find it in NI-Max.

 

Anyone have this kind of experience to handle it ?

 

Thanks.

 

 

Learning from other people
0 Kudos
Message 1 of 15
(4,746 Views)
Solution
Accepted by Brzhou

Please share more information on your Temperature sensor board with the USB to I2C tool - links to user guide/manual or model number and possibly some photos.

 

Typically, these USB to xx protocol chips show up as a VCOM (virtual COM) port and you use VISA libraries to communicate to these USB to xx protocol chips. In some cases, such as the FTDI chips, there are special driver DLL provided by the manufacturer and you call these DLL in LabVIEW to communicate with the USB chip which in turn based on the commands you send will translate into respective protocol commands (like I2C in your case). All these are manufacturer and chip dependent and hence need exact details to guide you.

Santhosh
Soliton Technologies

New to the forum? Please read community guidelines and how to ask smart questions

Only two ways to appreciate someone who spent their free time to reply/answer your question - give them Kudos or mark their reply as the answer/solution.

Finding it hard to source NI hardware? Try NI Trading Post
0 Kudos
Message 2 of 15
(4,727 Views)

Hi Sir, 

 

For i2c chip:

Brzhou_0-1677475841199.png

 

For usb to i2c tool, use CH341 series:

 

Brzhou_1-1677475923659.png

 

So you mean normally, if we choose the right usb-to-i2c tool and driver, we can see it in NI-Max ?

Any recomendation for this tool ?

Thanks.

 

Learning from other people
0 Kudos
Message 3 of 15
(4,713 Views)

@Brzhou wrote:

So you mean normally, if we choose the right usb-to-i2c tool and driver, we can see it in NI-Max ?

 

 


Well, you will never see the I2C device itself in NI-Max.

 

You will only see the Virtual Com port your USB to I2C is using.

 

========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 4 of 15
(4,668 Views)

NI has its own I²C/SPI Interface Device, USB-8452. It comes with native LabVIEW support.

-------------------------------------------------------
Control Lead | Intelline Inc
0 Kudos
Message 5 of 15
(4,631 Views)

@Brzhou wrote:

Hi Sir, 

 

For i2c chip:

Brzhou_0-1677475841199.png

 

For usb to i2c tool, use CH341 series:

 

Brzhou_1-1677475923659.png

 

So you mean normally, if we choose the right usb-to-i2c tool and driver, we can see it in NI-Max ?

Any recomendation for this tool ?

Thanks.

 


Yes, the choice of the right USB-to-I2C tool will make your life easy.

I would suggest USB-8452 due to its native drivers for LabVIEW

Santhosh
Soliton Technologies

New to the forum? Please read community guidelines and how to ask smart questions

Only two ways to appreciate someone who spent their free time to reply/answer your question - give them Kudos or mark their reply as the answer/solution.

Finding it hard to source NI hardware? Try NI Trading Post
0 Kudos
Message 6 of 15
(4,624 Views)

Thanks, i will check this device in website.

Learning from other people
0 Kudos
Message 7 of 15
(4,618 Views)

But i guess usb8452 is costly, any cheap solutions ?

Thanks.

Learning from other people
0 Kudos
Message 8 of 15
(4,617 Views)

I see, thanks Sir.

Learning from other people
0 Kudos
Message 9 of 15
(4,616 Views)

@Brzhou wrote:

But i guess usb8452 is costly, any cheap solutions ?

Thanks.


There are of course cheap solutions, then you will spend engineering time in developing code to automate it and debug hardware issues. Considering the engineering cost to get it up and running, it would be wise to get off the shelf solution that is proven to work.

 

This seems to be cheap option - https://www.adafruit.com/product/2264?gclid=EAIaIQobChMI-5fip7y3_QIVcQNlCh0GbgnVEAQYASABEgIB9PD_BwE

 

Now you've to look for LabVIEW drivers for FT232H with wrappers for I2C functionality, if not available, you could develop your own and debug it to working state.

Santhosh
Soliton Technologies

New to the forum? Please read community guidelines and how to ask smart questions

Only two ways to appreciate someone who spent their free time to reply/answer your question - give them Kudos or mark their reply as the answer/solution.

Finding it hard to source NI hardware? Try NI Trading Post
0 Kudos
Message 10 of 15
(4,600 Views)