Sonar hc sr04 for apm2.8

Hello,
I want to connect a sonar hcsr04 on my apm2.8 in order to be able to drive in indoor.
How do I go about it?
How are connections made?
Is there a specific program?
What other applications can the sonar perform?
Thank you in advance for the information.
Good evening.
cordially.

We don’t support that sonar, it has pretty bad performance. The supported rangefinders are listed in the wiki: http://ardupilot.org/copter/docs/common-rangefinder-landingpage.html