Move servo code to modules/servo.*

This commit is contained in:
Scott Lahteine
2017-11-19 13:39:46 -06:00
parent 81bc428b48
commit c0000a0cdc
8 changed files with 110 additions and 41 deletions

View File

@@ -186,16 +186,6 @@ extern volatile bool wait_for_heatup;
// Inactivity shutdown timer
extern millis_t max_inactive_time, stepper_inactive_time;
#if HAS_SERVOS
#include "HAL/servo.h"
extern HAL_SERVO_LIB servo[NUM_SERVOS];
#define MOVE_SERVO(I, P) servo[I].move(P)
#if HAS_Z_SERVO_ENDSTOP
#define DEPLOY_Z_SERVO() MOVE_SERVO(Z_ENDSTOP_SERVO_NR, z_servo_angle[0])
#define STOW_Z_SERVO() MOVE_SERVO(Z_ENDSTOP_SERVO_NR, z_servo_angle[1])
#endif
#endif
#if FAN_COUNT > 0
extern int16_t fanSpeeds[FAN_COUNT];
#if ENABLED(EXTRA_FAN_SPEED)