Maxbotix I2CXL-MaxSonar EZ4

Hi,

I’ve bought Maxbotix Sonar I2CXL EZ4 and having problem to make it work on Navio2/Pi3. I have followed all the installation instructions according to Ardupilot Copter document and change the I2C speed to 400KHz. The sonarrange and sonarvoltage are both 0. I’m using the latest RC4 image. What should I do? Thanks

What does i2cdetect show?

I’ve managed to make it work finally. After a few reboots suddenly it came alive. Do you know what is the units of sonarrange? Is it in meter? Im getting values between 0.2 - 1.5 while pointing the sonar around my office.

Will be measured in meters. Minimum range is 20cm, so anything below that will register as 0.2m.

Datasheet:

Thank you for the information.

Hi @fadilrosli,

I’m trying to do the same thing without any success.
What did you change exactly?
Did you install pullup resistors?

Thank you,
Tobias

Hi @tobias-dahms,

You need to change the i2c speed to 400khz and set RNGFND_TYPE = “2". Also make sure the wiring is correct. No need resistor. Hope it helps.

1 Like

Hi @fadilrosli,

thank you for your reply! :+1:

Did you change the speed as described here?:


Testing the speed always gives back “0”, may be there is the problem?

Didn’t check up to know wether
dtparam=i2c1=on
dtparam=i2c_arm=on
is already in the file or whether I habe to add that myself?

Hi @tobias-dahms,

Yes, you can follow the guide. In the latest firmware you can change the i2c speed using the built-in configuration file, more easier. Just change the speed to 400000.

1 Like

I’m still figthing with the sensor. @400,000 hz the sensor works with irregular update rates. @100,000hz it works with regular update rates but the result in mission planner is always 328 or 330.

That is a very good sensor, I don’t understand why emlid makes it so hard to use it.