NI Home
Cart Cart | Help
Hello Events Academic NI Developer Zone Support Solutions Products & Services Contact NI MyNI
You are here: 
NI Home > NI Developer Zone > NI Discussion Forums


Reply
Member
ksquared
Posts: 2
0 Kudos
Accepted Solution

Using Sharp 2Y0A21 IR sensor to input data into a labview program using mydaq

Hi,

I am working on a LabVIEW project. For a part of it (creating a subVI) I want to make use of an IR sensor (SHARP 2Y0A21), in order to measure the proximity of my hand from the sensor. I also have the myDAQ to aid me with the sensor inputs. I want to make a program that lights up an LED boolean when my hand goes out of the sensor's range. Please guide me as to what should i do in order to get it working. A few steps on how to make my program will be highly appreciated!

 

Thanks,

 

Ksquared.

Member
Joseph-S
Posts: 117
0 Kudos

Re: Using Sharp 2Y0A21 IR sensor to input data into a labview program using mydaq

Hi KSquared,

 

This DeveloperZone article, Measuring Distance with myDAQ and Sharp Infrared Proximity Sensor should help you get started. Although the sensor model used in this article is different, the specifications appear to be very similar from a quick glance at the datasheet. If you follow this article, you should be able to acquire the voltage output from the sensor, filter it and convert the voltage to a distance. From here, the rest of your program should be fairly simple to complete. Feel free to post any further questions you may have regarding the article or your application. Hope you find the article helpful!

Regards,

Joseph S
Applications Engineer
National Instruments
Member
ksquared
Posts: 2
0 Kudos

Re: Using Sharp 2Y0A21 IR sensor to input data into a labview program using mydaq

Thank you very much! 

By using this web site, you accept the Terms of Use for this web site. Please read these Terms of Use carefully before using any part of this site. Please go here for information on ni.com's copyright infringement policy.
My Profile | Privacy | Legal | Contact NI © 2011 National Instruments Corporation. All rights reserved.    |    E-Mail this Page E-Mail this Page