Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   NI LabVIEW (http://www.chiefdelphi.com/forums/forumdisplay.php?f=182)
-   -   LabVIEW Ultrasonic Sensor (http://www.chiefdelphi.com/forums/showthread.php?t=141889)

chubchub5577 01-16-2016 04:15 PM

LabVIEW Ultrasonic Sensor
 
I want to use an ultrasonic sensor so that i have my motor unable to turn on until I get close enough to the wall. I have never used this sensor before and this is my first year ever using labview. If you have any sources or just any help I would love the feedback thanks!

sraque 01-16-2016 09:03 PM

Re: LabVIEW Ultrasonic Sensor
 
Which model ultrasonic sensor are you using or wish to use? If you do not have one already, I can provide some guidance on using a Maxbotix one (coupon in KOP).

Greg McKaskle 01-17-2016 08:39 AM

Re: LabVIEW Ultrasonic Sensor
 
I suggest you select to the Help>>Find Examples in the menubar. See if there is an example for the specific sensor. Use that example's panel and code to explore its capabilities and how to use it. If you decide it is the right one to put on your root, there is a tutorial in the Getting Started window about the specifics of integrating example code into your robot code.

Greg McKaskle

Bpk9p4 01-17-2016 08:11 PM

Re: LabVIEW Ultrasonic Sensor
 
We just put together a video on how to do this. Here is the link to it http://youtu.be/npkDcDyke48. Let me know how it goes

chubchub5577 01-18-2016 11:49 AM

Re: LabVIEW Ultrasonic Sensor
 
Quote:

Originally Posted by sraque (Post 1525095)
Which model ultrasonic sensor are you using or wish to use? If you do not have one already, I can provide some guidance on using a Maxbotix one (coupon in KOP).

We are using this sensor http://www.amazon.com/SainSmart-HC-S.../dp/B004U8TOE6 How ever we do have the maxbotix sensor if that is an easier sensor to code I would be happy to use it (maybe a little help with wiring please! :p)
I have some pictures of my code that (I thought it would work this way) so maybe just helping edit that would be helpful!
Thanks very much!!

chubchub5577 01-18-2016 12:03 PM

Re: LabVIEW Ultrasonic Sensor
 
Here are some screenshots of my code so far hope this helps! http://imgur.com/a/yPXoB

Doug Norman 01-19-2016 09:25 AM

Re: LabVIEW Ultrasonic Sensor
 
As Greg mentioned above, in LabVIEW you can use Help>>Find Examples... and then look at the Ultrasonic example.

yara92 01-23-2016 11:58 AM

Re: LabVIEW Ultrasonic Sensor
 
How I can read Sensor like HC-SR04 WITH LABVIEW, Just a simple code for beginner.
I try to study https://wpilib.screenstepslive.com/s...from-bad-loops
did not help

Omar 01-23-2016 12:31 PM

Re: LabVIEW Ultrasonic Sensor
 
Quote:

Originally Posted by yara92 (Post 1528875)
How I can read Sensor like HC-SR04 WITH LABVIEW, Just a simple code for beginner.
I try to study https://wpilib.screenstepslive.com/s...from-bad-loops
did not help

Follow the advice from Greg McKaskle and Doug Norman above!

LabVIEW Help>> Find Examples
Study the examples that are included in the FRC updates.

Are you having problems with endless loops?

yara92 01-23-2016 01:11 PM

Re: LabVIEW Ultrasonic Sensor
 
I am so far from that just how to write code to read the Ultrasonic Sensor HC-SR04 by LABVIEW, Just a simple code for beginner.

Greg McKaskle 01-24-2016 10:30 AM

Re: LabVIEW Ultrasonic Sensor
 
If you are trying to use the ultrasonic sensor, there are a total of five icons.

Open tells the SW what pins you have wired the sensor to and what kind of sensor it is.

GetRange returns a distance number based on how it is configured.

Get and Set Refnum allow you to store and retrieve the opened refnum so that you can use it other places.

Close is how you release the pins so they could be reopened for something else.

It sounds like you may have other, more basic issues, but I can't be sure what they are.

Feel free to ask more basic questions. Everyone has to start in the way that is right for them, and that is easier with good questions.

Without knowing more, I'd suggest that you go through the tutorials on the Getting Started tab. It will help with imaging the hardware, installing the software, and opening template and example code and making use of it. Also, consider doing these tasks with a mentor or other students.

Good luck,
Greg McKaskle

yara92 01-25-2016 05:43 PM

Re: LabVIEW Ultrasonic Sensor
 
thanks I found a nice Example in LV and in fourm NI
Arduino sensor code.txt (583 bytes)
ultrasonic sonar module 1r0.pdf (321.7 K)
US-100 ultrasonic my code.vi (41.2 K) https://decibel.ni.com/content/servl...20my%20code.vi

Greg McKaskle 01-25-2016 09:31 PM

Re: LabVIEW Ultrasonic Sensor
 
The code you found will help you to read a value from an arduino mounted ultrasonic sensor.

The code for LabVIEW FRC examples will help with one connected to a roboRIO. Do you have all of the software installed so that you can look at examples and tutorials? If not, be sure to install the software update after installing the DVD.

Greg McKaskle

yara92 02-01-2016 11:40 AM

Re: LabVIEW Ultrasonic Sensor
 
Yes I have every thing now it is clear with nice Example


All times are GMT -5. The time now is 06:12 PM.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi