Arm command causes takeoff in Gazebo

Hi,

I’m trying to develop an coaxial octocopter, and is setting up a simulation in Gazebo. I set everything up, but when I use the command “commander arm” the drone starts taking off, very unstable instead of just arming the drone. I have tried to reduce the “PWM_MAIN_MIN” parameter to reduce the thrust from the propellers when arming, but made no difference. I have not managed to figure out why this happens. Does anyone have ideas what can cause this?

For further information, the drone is able to takeoff and fly fairly stable if I increase the weight of the drone from 3.5 kg to 4 kg in the SDF file. But this causes the drone to use 80% thrust to just hover, which is too high to fly properly.

I have attached the fligh tog of the drone being just armed if that helps. I know the drone starts oscillating in the flight log, but I’m assuming that is not related since the drone is not even supposed to takeoff.

Hey did you ever figure out what was causing this? I am having the same issue with a custom model and have been fighting with it for a little while