Fixed various bugs that led to maximum current being unexpectedly drawn; misc others
Fix calibration bugs