To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.roboticsOpen lugnet.robotics in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / 27673
27672  |  27674
Subject: 
How can I set inch unit or metric(cm) unit to Sonar sensor?
Newsgroups: 
lugnet.robotics
Date: 
Sat, 7 Mar 2009 15:11:35 GMT
Original-From: 
NXTelectroneer <technia21@yahoo[spamless].co.kr>
Viewed: 
10207 times
  
Hi,

I am building a NXT remote control program but atempt a problem.

I am now success to reading sensors even ultrasonic(sonar) sensor.

But I want to set the sonar to imperial(inch) unit or metric(Centimeter)
unit.

Or, want to know how to reading from the sonar in inch or cm unit.

Of course, I am reffered the Direct command documentation, Ultrasonic I2C
protocol document...and so on

but it is so difficulty to understand and use it's contents.

anyway, I try it, but failure.

I also search for google and some famous LEGO NXT web site, but can't find
exactly answer.

They say with some lib or tool like NXC, java, C++ lib... etc. but I don't
have them.

What I want to know is the data give the sonar in LSWRITE command or in the
return package.

aaaaaahh... I am tired... please let me know...
--
View this message in context: http://www.nabble.com/How-can-I-set-inch-unit-or-metric%28cm%29-unit-to-Sonar-sensor--tp22388493p22388493.html
Sent from the LEGO Robotics mailing list archive at Nabble.com.



Message has 1 Reply:
  Re: How can I set inch unit or metric(cm) unit to Sonar sensor?
 
(...) The sensor itself returns only cm values. To use inches just multiply the result by 100 and divide by 254 (1 inch = 2.54 cm, but since we are dealing with integers we use 1/2.54 = 100/254) Philo (16 years ago, 7-Mar-09, to lugnet.robotics)

3 Messages in This Thread:

Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    

Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR