diff --git a/MiniFork_Bluepad2.0/MiniFork_Bluepad2.0.ino b/MiniFork_Bluepad2.0/MiniFork_Bluepad2.0.ino index fa34c60..44b1a16 100644 --- a/MiniFork_Bluepad2.0/MiniFork_Bluepad2.0.ino +++ b/MiniFork_Bluepad2.0/MiniFork_Bluepad2.0.ino @@ -106,7 +106,8 @@ void processGamepad(ControllerPtr ctl) { void processThrottle(int axisYValue) { float adjustedThrottleValue = axisYValue / 2; - if (adjustedThrottleValue > 15 || adjustedThrottleValue < -15) { + int deadZoneValue = 60; + if (adjustedThrottleValue > deadZoneValue || adjustedThrottleValue < -deadZoneValue) { if (hardRight) { moveMotor(rightMotor0, rightMotor1, -1 * (adjustedThrottleValue * steeringAdjustment)); } else if (hardLeft) { diff --git a/MiniFork_PS3_Controller/MiniFork_PS3_Controller.ino b/MiniFork_PS3_Controller/MiniFork_PS3_Controller.ino index b71f341..fd6f941 100644 --- a/MiniFork_PS3_Controller/MiniFork_PS3_Controller.ino +++ b/MiniFork_PS3_Controller/MiniFork_PS3_Controller.ino @@ -167,7 +167,8 @@ void notify() { } void processThrottle(int throttleValue) { adjustedThrottleValue = throttleValue; - if (adjustedThrottleValue > 15 || adjustedThrottleValue < -15) { + int deadZoneValue = 60; + if (adjustedThrottleValue > deadZoneValue || adjustedThrottleValue < -deadZoneValue) { if (hardRight) { moveMotor(rightMotor0, rightMotor1, -1 * (adjustedThrottleValue * steeringAdjustment)); } else if (hardLeft) {