0

I need to access distance data using a LV-EZ0 Maxtronix ultrasonic sensor: MB1000 LV-MaxSonar®-EZ0TMHigh Performance Ultrasonic Rangefinder

Can anyone suggest what particular arduino libraries or code would be most useful?

I noticed this new ping library, NewPing

Would this work for my purposes with this particular sensor?

Greenonline
3,1527 gold badges36 silver badges48 bronze badges
asked Jul 31, 2014 at 19:48

1 Answer 1

1

Likely work in pulse mode (library you mentioned) and sure work in RS232 serial mode (spec. in data sheet page 2, top, read data number as text).

How many sensors do you need and how fast update rate? Serial mode is easier if you application need small number of sensor at 'nominal' update rate (Arduino has limited number of hardware serial port, although softserial library may help).

Essentially, in pulse mode, the RX and PW pin is similar to Trig and Echo pin on many widely available sensor (several models number, basically following similar principle). Need care about the high and low relationship as may differ from the default value in library.

Taken from the data sheet of LV-MaxSonar®-EZ0

R X – If held low, the EZ0TM will stop ranging. Bring high for 20uS or more to command a range reading.

P W – This pin outputs a pulse width representation of range

Specifically you may want to first try the simple (old) ping: Ping Ultrasonic Range Finder

Changes needed:

  1. Your sensor data sheet requires 20 μs trigger pulse while the above is 2 μs;
  2. The library read a high pulse. Your sensor data sheet 'send pulse' which likely imply a HIGH pulse, may not need change;
  3. The library use one pin for both in and out. your is one pin in (in for sensor, out for Arduino) for trigger and one put out for measurement.

Also, another library. Note the author states that many sensor from the factory differs (may need small change in code): Distance Detection with MaxSonar ultrasonic rangefinder.

Greenonline
3,1527 gold badges36 silver badges48 bronze badges
answered Aug 1, 2014 at 3:09

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.