How to use ardupilot_plugin for gazebo?

so i am using gazebo and sitl for simulation of dronekit code.and i am using iris copter which comes in built in gazebo with ardupilot plugin so that i can control it using mavproxy and drone-kit . i have design my own drone in solid works , and convert the cad file into urdf file by providing necessary links and it’s type . now the issue is that how do i integrate the ardupilot plugin with my custom urdf file so that i can simulate my custom drone in gazebo using mavproxy ?

Hi @Dharmil_Patel, you will need to add the plugins used in the iris_with_standoffs and iris_with_ardupilot models to your model. You can either use <gazebo> elements in URDF or convert your model to SDF first then edit (this may be easier to get running initially).

If your drone is a quadcopter then reviewing the iris model and mapping the controllers and lift-drag plugins to the joint names in your drone should be straight forward. If you have additional rotors you will need to add a control element for each one of those following the same pattern. The inertial elements, propeller areas and motor PIDs may all need to be modified depending on the dimensions of your drone.