Problem in quad with my custom controller

Iam developing controllers for quad. I have nearly completed my own controller and before it was working fine but the same code is not working fine with little change in controller now(the quad is giving abnormal behaviour (i.e) all four motors are rotating at different speeds).

So I uploaded my previous code which was working also now not working .

I uploaded default px4 default stack and its working fine. It means my hardware is fine.

I have done calibration also.

Iam doubting the memory part of PX4 but i dont have any clear idea about the memory part of px4.

Hi, i’m trying to use a customized controller too, the problem is that i cannot handle the scaled control value used by PX4, how you scale your control action accordingly?