Altitude hold error

Hey i have built a drone on dji f450 frame and using some cheap esc the problem im facing is this:
Initially i have used apm2.8 i have done all calibration and got it to arm and spin in stabilise mode (not so stable and glitchy) and when i try to switch to alt hold mode the drone falls down and suddenly climbs uncontrollably .so i changed the apm for a pixhawk and still getting the same problem also getting baro alt error 5880 and gps alt error after first flight (this first flight with pixhawk is unstable in stabilise mode and behaves the same as apm when changed to alt hold mode what should i do??

Have you done all the basic calibrations?
Can you please provide the .bin file so we can see what is going on.

Yes i have done all the intitial calibration and this issue occured only after switching it to alt hold mode

Without a .bin log file we can not give you any answers.

High levels of vibration can cause that. Which is often seen on those cheap F450 frames.

Similar setups on same frame work great

I want to know if esc play a role in that or transmitter

Post a link to the .bin log file as suggested.