Academic Hardware Products (myDAQ, myRIO)

cancel
Showing results for 
Search instead for 
Did you mean: 

help to connect LM35 to my Vi

Hello every body i need help about the vi that i download in this conversation  it dosen't work with the sensor LM35 when i connect it to Ni mydaq i don't know where is the problem exactly because when i connect sensor and i use vi (just an example for demonstration) that read only the LM35 sensor it work perfectly please i just want to know why this vi dosen't work ? 

 
0 Kudos
Message 1 of 8
(8,208 Views)

Hi,

 

You have your DAQmx timing VI configured for Continuous Samples, but you have the DAQmx read VI configured for 1 Channel/1 Sample. You can fix this by clicking on the drop down arrow underneath the DAQmx Read VI. Navigate to Analog  » Single Channel » Multiple Samples » 1D DBL to collect your data into an array. You'll also need to specify the "number of samples per channel" input on the DAQmx read function (this parameter appears when you configure the VI for multiple reads per loop iteration). 

Kelsey W.
National Instruments
Applications Engineer
0 Kudos
Message 2 of 8
(8,169 Views)

thanks for your help but unfortunately it doesn't work for only one sample so there is a mistake in the VI can you help me to correct it and there for it will read the LM 35 

0 Kudos
Message 3 of 8
(8,152 Views)

Can you explain a bit more what the mistake is that you're referencing? It's hard for me to make suggestions if I don't know what problems you're having. Snapshots and VI Snippets are usually a good method of demonstrating what you're seeing.

Kelsey W.
National Instruments
Applications Engineer
0 Kudos
Message 4 of 8
(8,137 Views)

when i connect the LM35 only and i want to get data in the jauge it doesn't work it give just data in th le Label Data of the VI (0.27) i'm using another VI just for reading LM35 it work very good and i test the sensor and everything alright my teacher ask me to do the same thing and aquire data for the (LDR sensor) for sunshine and take measerment and save it in a database with date everyday to compare results in the next year i'm really blocked and confused after he ask me to not using humidty sensor so i must delete just the part of humidity sensor and replace it with diagram aquiring sunshine data (LDR sensor) SO help me please i need you brother can you please modify the VI to get these result 

0 Kudos
Message 5 of 8
(8,131 Views)

In the VI you attached, you are wiring a Voltage Task from something previously created in MAX (I'm guessing). If the sensor changes, you'll likely have to change the DAQmx task. Since I do not know what settings you have configured in this task I cannot tell you how to change the task. Please consult the following resource:

 

Getting Started with NI-DAQmx:

http://www.ni.com/white-paper/5434/en/

 

Using a DAQmx Task in LabVIEW Community Example:

https://decibel.ni.com/content/docs/DOC-2316

 

 

Kelsey W.
National Instruments
Applications Engineer
0 Kudos
Message 6 of 8
(8,115 Views)

hello thank you for answering me but i have not much time to read i supposed to give solution to my teacher next week and i'm really blocked and i don't know what i supposed to do please if you don't mind can you modifiy the VI how you can and i will appreciate you work however is it and thank you for helping friend 🙂

0 Kudos
Message 7 of 8
(8,091 Views)

Hello,

 

I'm sure if your teacher gave you this assignment, she probably wanted you to complete it using your own brain. Take a bit of time and look at the resources I provided you with. The DAQmx API is fairly simple to understand and will help you move forward in the future without having to depend on other people.

Kelsey W.
National Instruments
Applications Engineer
0 Kudos
Message 8 of 8
(8,064 Views)