Go to Post This will likely fall on deaf eyes but - - JaneYoung [more]
Home
Go Back   Chief Delphi > FIRST > General Forum
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 14-01-2012, 19:15
TheGuyz TheGuyz is offline
Registered User
FRC #2443
 
Join Date: Jan 2011
Location: Hawaii
Posts: 36
TheGuyz is an unknown quantity at this point
Programming Ultrasonic Sensor

How would you program the ultrasonic sensor in Java. The sensor is an analog sensor I believe, but the class says it takes a digital input.
Reply With Quote
  #2   Spotlight this post!  
Unread 14-01-2012, 19:21
DonRotolo's Avatar
DonRotolo DonRotolo is offline
Back to humble
FRC #0832
Team Role: Mentor
 
Join Date: Jan 2005
Rookie Year: 2005
Location: Atlanta GA
Posts: 6,995
DonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond reputeDonRotolo has a reputation beyond repute
Re: Programming Ultrasonic Sensor

The sensor has three outputs, one of which is analog and one of which is digital (serial, 9600 Baud 8N1).
Or just say it is some other Analog sensor and use it that way.

www.maxbotix.com
__________________

I am N2IRZ - What's your callsign?

Last edited by DonRotolo : 14-01-2012 at 19:23.
Reply With Quote
  #3   Spotlight this post!  
Unread 14-01-2012, 20:48
TheGuyz TheGuyz is offline
Registered User
FRC #2443
 
Join Date: Jan 2011
Location: Hawaii
Posts: 36
TheGuyz is an unknown quantity at this point
Is there a guide or some out there that we can use as a guide to show us how to solder the sensor
Reply With Quote
  #4   Spotlight this post!  
Unread 15-01-2012, 02:01
theprgramerdude theprgramerdude is offline
WPI Freshman
AKA: Alex
FRC #2503 (Warrior Robotics)
Team Role: Mentor
 
Join Date: Feb 2010
Rookie Year: 2008
Location: Brainerd, Minnesota
Posts: 347
theprgramerdude has much to be proud oftheprgramerdude has much to be proud oftheprgramerdude has much to be proud oftheprgramerdude has much to be proud oftheprgramerdude has much to be proud oftheprgramerdude has much to be proud oftheprgramerdude has much to be proud oftheprgramerdude has much to be proud oftheprgramerdude has much to be proud oftheprgramerdude has much to be proud of
Re: Programming Ultrasonic Sensor

The ultrasonic sensor class is meant to be used with a different ultrasonic sensor that is not found in the Kit of Parts.

To use the analog voltage output on the sensor, just created an AnalogChannel object with the given channel, and call getVoltage(). You can then translate that voltage into distance as you want.

As for soldering... There might be one on their website. I know, it's a pain.
__________________
Attending: MN Duluth Regional
Reply With Quote
  #5   Spotlight this post!  
Unread 15-01-2012, 02:12
carrillo694's Avatar
carrillo694 carrillo694 is offline
Alex Carrillo
FRC #0694 (Stuypulse)
Team Role: Programmer
 
Join Date: Jan 2011
Rookie Year: 2009
Location: New York, NY
Posts: 66
carrillo694 is a jewel in the roughcarrillo694 is a jewel in the roughcarrillo694 is a jewel in the roughcarrillo694 is a jewel in the rough
Re: Programming Ultrasonic Sensor

Quote:
Originally Posted by TheGuyz View Post
Is there a guide or some out there that we can use as a guide to show us how to solder the sensor
Here is one option as to how you can solder it: http://www.adafruit.com/adablog/wp-c...06/pt-2002.jpg

As for soldering tips -- I prefer to apply the solder to the side opposite the wires. In that picture, you can see they threaded the stranded wire through, then applied the solder in between the board and the wire's insulator. I prefer to apply the solder to the OTHER side of the board, so that there is less chance of me accidentally burning the insulator.

If you do not want to solder it directly to the board, you can always solder two PWM cables to it. In other words, take the PWM cables, put then through the holes, then solder the PWM leads to the board's vias on the other side. From there, you might find the PWM leads on the other side more manageable.

Either way, connect the GND to ground, +5 to the +5 channel on your cRIO's Analog Module, and AN to an analog channel on your analog module.
Reply With Quote
  #6   Spotlight this post!  
Unread 15-01-2012, 04:15
Bill Tompkins's Avatar
Bill Tompkins Bill Tompkins is offline
LRI/MAR Board of Directors/Engineer
AKA: Bill Tompkins
FRC #1279 (Cold Fusion)
Team Role: Mentor
 
Join Date: Dec 2007
Rookie Year: 2005
Location: Princeton, NJ
Posts: 10
Bill Tompkins is a splendid one to beholdBill Tompkins is a splendid one to beholdBill Tompkins is a splendid one to beholdBill Tompkins is a splendid one to beholdBill Tompkins is a splendid one to beholdBill Tompkins is a splendid one to behold
Re: Programming Ultrasonic Sensor

The sensors have multiple outputs, analog, digital (pulse width modulated) and serial. There are also other ultrasonics sensors out there.

Call MaxBotixs, there have some excellent support people there. Good to talk with.

Last edited by Bill Tompkins : 15-01-2012 at 04:42.
Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 05:25.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


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