How can I use the mass of a quadrotor?

Hi, guys

I am trying to modify the firmware, PX4 1.7.0 and want to implement my own control law instead of PID.

But I faced some problems. To implement my control law, I need the mass of the object and moment of inertia.

In my opinion, It seems that the simulator, for example, JMavSim or Gazebo provides parameters related to the vehicle.

How can I use those values provided by simulator in mc_att_control_main.cpp?

If my guess is not correct, can you tell me how to do it?

Thanks.