Merge pull request #11610 from Freeviv/bugfix-2.0.x
[2.0.x] Editable servo angles
This commit is contained in:
commit
8e18e48d49
82 changed files with 469 additions and 233 deletions
|
@ -1947,9 +1947,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1946,9 +1946,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1966,9 +1966,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1946,9 +1946,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -2101,9 +2101,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1955,9 +1955,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1966,9 +1966,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1920,9 +1920,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1920,9 +1920,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1934,9 +1934,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1946,9 +1946,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1934,9 +1934,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1945,9 +1945,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1956,9 +1956,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1951,9 +1951,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1965,9 +1965,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1956,9 +1956,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1950,9 +1950,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1950,9 +1950,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1956,9 +1956,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1935,9 +1935,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1928,9 +1928,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1928,9 +1928,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1952,9 +1952,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 500, 500 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1961,9 +1961,7 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
/**
|
||||
|
@ -1975,4 +1973,7 @@
|
|||
#define LCD_WIDTH_OVERRIDE 20 // Default is 22. For this Geeetech use 20.
|
||||
#endif
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1946,9 +1946,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1962,9 +1962,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1961,9 +1961,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1946,9 +1946,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1946,9 +1946,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1950,9 +1950,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1957,9 +1957,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1966,9 +1966,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1948,9 +1948,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1945,9 +1945,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1950,9 +1950,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1950,9 +1950,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1946,9 +1946,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1995,9 +1995,10 @@ Black rubber belt(MXL), 18 - tooth aluminium pulley : 87.489 step per mm (Huxley
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1946,9 +1946,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1946,9 +1946,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1959,9 +1959,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1948,9 +1948,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1946,9 +1946,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1977,9 +1977,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1946,9 +1946,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -2002,9 +2002,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1946,9 +1946,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1951,9 +1951,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1946,9 +1946,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1957,9 +1957,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1946,9 +1946,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1981,9 +1981,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1947,9 +1947,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1947,9 +1947,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1959,9 +1959,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1952,9 +1952,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -2082,9 +2082,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -2081,9 +2081,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -2080,9 +2080,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -2083,9 +2083,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -2068,9 +2068,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -2070,9 +2070,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -2071,9 +2071,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -2071,9 +2071,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1960,9 +1960,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300, 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1949,9 +1949,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1948,9 +1948,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1941,9 +1941,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
|
@ -1951,9 +1951,10 @@
|
|||
// If the servo can't reach the requested position, increase it.
|
||||
#define SERVO_DELAY { 300 }
|
||||
|
||||
// Servo deactivation
|
||||
//
|
||||
// With this option servos are powered only during movement, then turned off to prevent jitter.
|
||||
// Only power servos during movement, otherwise leave off to prevent jitter
|
||||
//#define DEACTIVATE_SERVOS_AFTER_MOVE
|
||||
|
||||
// Allow servo angle to be edited and saved to EEPROM
|
||||
//#define EDITABLE_SERVO_ANGLES
|
||||
|
||||
#endif // CONFIGURATION_H
|
||||
|
|
56
Marlin/src/gcode/config/M281.cpp
Normal file
56
Marlin/src/gcode/config/M281.cpp
Normal file
|
@ -0,0 +1,56 @@
|
|||
/**
|
||||
* Marlin 3D Printer Firmware
|
||||
* Copyright (C) 2016 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
|
||||
*
|
||||
* Based on Sprinter and grbl.
|
||||
* Copyright (C) 2011 Camiel Gubbels / Erik van der Zalm
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*
|
||||
*/
|
||||
#include "../../inc/MarlinConfig.h"
|
||||
|
||||
#if HAS_SERVOS && ENABLED(EDITABLE_SERVO_ANGLES)
|
||||
|
||||
#include "../gcode.h"
|
||||
#include "../../module/servo.h"
|
||||
|
||||
void GcodeSuite::M281() {
|
||||
if (!parser.seenval('P')) return;
|
||||
const int servo_index = parser.value_int();
|
||||
if (WITHIN(servo_index, 0, NUM_SERVOS - 1)) {
|
||||
bool angle_change = false;
|
||||
if (parser.seen('L')) {
|
||||
servo_angles[servo_index][0] = parser.value_int();
|
||||
angle_change = true;
|
||||
}
|
||||
if (parser.seen('U')) {
|
||||
servo_angles[servo_index][1] = parser.value_int();
|
||||
angle_change = true;
|
||||
}
|
||||
if (!angle_change) {
|
||||
SERIAL_ECHO_START();
|
||||
SERIAL_ECHOPAIR(" Servo ", servo_index);
|
||||
SERIAL_ECHOPAIR(" L", servo_angles[servo_index][0]);
|
||||
SERIAL_ECHOLNPAIR(" U", servo_angles[servo_index][1]);
|
||||
}
|
||||
}
|
||||
else {
|
||||
SERIAL_ERROR_START();
|
||||
SERIAL_ECHOPAIR("Servo ", servo_index);
|
||||
SERIAL_ECHOLNPGM(" out of range");
|
||||
}
|
||||
}
|
||||
|
||||
#endif // HAS_SERVOS && EDITABLE_SERVO_ANGLES
|
|
@ -103,8 +103,8 @@ inline void servo_probe_test() {
|
|||
|
||||
SERIAL_PROTOCOLLNPGM("Servo probe test");
|
||||
SERIAL_PROTOCOLLNPAIR(". using index: ", probe_index);
|
||||
SERIAL_PROTOCOLLNPAIR(". deploy angle: ", z_servo_angle[0]);
|
||||
SERIAL_PROTOCOLLNPAIR(". stow angle: ", z_servo_angle[1]);
|
||||
SERIAL_PROTOCOLLNPAIR(". deploy angle: ", servo_angles[probe_index][0]);
|
||||
SERIAL_PROTOCOLLNPAIR(". stow angle: ", servo_angles[probe_index][1]);
|
||||
|
||||
bool probe_inverting;
|
||||
|
||||
|
@ -146,10 +146,10 @@ inline void servo_probe_test() {
|
|||
uint8_t i = 0;
|
||||
bool deploy_state, stow_state;
|
||||
do {
|
||||
MOVE_SERVO(probe_index, z_servo_angle[0]); //deploy
|
||||
MOVE_SERVO(probe_index, servo_angles[Z_PROBE_SERVO_NR][0]); // Deploy
|
||||
safe_delay(500);
|
||||
deploy_state = READ(PROBE_TEST_PIN);
|
||||
MOVE_SERVO(probe_index, z_servo_angle[1]); //stow
|
||||
MOVE_SERVO(probe_index, servo_angles[Z_PROBE_SERVO_NR][1]); // Stow
|
||||
safe_delay(500);
|
||||
stow_state = READ(PROBE_TEST_PIN);
|
||||
} while (++i < 4);
|
||||
|
@ -170,7 +170,7 @@ inline void servo_probe_test() {
|
|||
#endif
|
||||
}
|
||||
else { // measure active signal length
|
||||
MOVE_SERVO(probe_index, z_servo_angle[0]); // deploy
|
||||
MOVE_SERVO(probe_index, servo_angles[Z_PROBE_SERVO_NR][0]); // Deploy
|
||||
safe_delay(500);
|
||||
SERIAL_PROTOCOLLNPGM("please trigger probe");
|
||||
uint16_t probe_counter = 0;
|
||||
|
@ -194,7 +194,7 @@ inline void servo_probe_test() {
|
|||
else
|
||||
SERIAL_PROTOCOLLNPGM("noise detected - please re-run test"); // less than 2mS pulse
|
||||
|
||||
MOVE_SERVO(probe_index, z_servo_angle[1]); //stow
|
||||
MOVE_SERVO(probe_index, servo_angles[Z_PROBE_SERVO_NR][1]); // Stow
|
||||
|
||||
} // pulse detected
|
||||
|
||||
|
|
|
@ -487,6 +487,9 @@ void GcodeSuite::process_parsed_command(
|
|||
|
||||
#if HAS_SERVOS
|
||||
case 280: M280(); break; // M280: Set servo position absolute
|
||||
#if ENABLED(EDITABLE_SERVO_ANGLES)
|
||||
case 281: M281(); break; // M281: Set servo angles
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#if ENABLED(BABYSTEPPING)
|
||||
|
|
|
@ -172,6 +172,7 @@
|
|||
* M260 - i2c Send Data (Requires EXPERIMENTAL_I2CBUS)
|
||||
* M261 - i2c Request Data (Requires EXPERIMENTAL_I2CBUS)
|
||||
* M280 - Set servo position absolute: "M280 P<index> S<angle|µs>". (Requires servos)
|
||||
* M281 - Set servo min|max position: "M281 P<index> L<min> U<max>". (Requires EDITABLE_SERVO_ANGLES)
|
||||
* M290 - Babystepping (Requires BABYSTEPPING)
|
||||
* M300 - Play beep sound S<frequency Hz> P<duration ms>
|
||||
* M301 - Set PID parameters P I and D. (Requires PIDTEMP)
|
||||
|
@ -627,6 +628,9 @@ private:
|
|||
|
||||
#if HAS_SERVOS
|
||||
static void M280();
|
||||
#if ENABLED(EDITABLE_SERVO_ANGLES)
|
||||
static void M281();
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#if ENABLED(BABYSTEPPING)
|
||||
|
|
|
@ -720,8 +720,8 @@ static_assert(X_MAX_LENGTH >= X_BED_SIZE && Y_MAX_LENGTH >= Y_BED_SIZE,
|
|||
/**
|
||||
* Limited number of servos
|
||||
*/
|
||||
#if NUM_SERVOS > 4
|
||||
#error "The maximum number of SERVOS in Marlin is 4."
|
||||
#if NUM_SERVOS > MAX_SERVOS
|
||||
#error "The selected board doesn't support enough servos for your configuration. Reduce NUM_SERVOS."
|
||||
#endif
|
||||
|
||||
/**
|
||||
|
|
|
@ -37,7 +37,7 @@
|
|||
*/
|
||||
|
||||
// Change EEPROM version if the structure changes
|
||||
#define EEPROM_VERSION "V55"
|
||||
#define EEPROM_VERSION "V56"
|
||||
#define EEPROM_OFFSET 100
|
||||
|
||||
// Check the integrity of data offsets.
|
||||
|
@ -70,6 +70,10 @@
|
|||
#include "../feature/bedlevel/bedlevel.h"
|
||||
#endif
|
||||
|
||||
#if HAS_SERVOS
|
||||
#include "servo.h"
|
||||
#endif
|
||||
|
||||
#if HAS_BED_PROBE
|
||||
#include "../module/probe.h"
|
||||
#endif
|
||||
|
@ -174,6 +178,11 @@ typedef struct SettingsDataStruct {
|
|||
bool planner_leveling_active; // M420 S planner.leveling_active
|
||||
int8_t ubl_storage_slot; // ubl.storage_slot
|
||||
|
||||
//
|
||||
// SERVO_ANGLES
|
||||
//
|
||||
uint16_t servo_angles[MAX_SERVOS][2]; // M281 P L U
|
||||
|
||||
//
|
||||
// DELTA / [XYZ]_DUAL_ENDSTOPS
|
||||
//
|
||||
|
@ -532,6 +541,26 @@ void MarlinSettings::postprocess() {
|
|||
EEPROM_WRITE(storage_slot);
|
||||
#endif // AUTO_BED_LEVELING_UBL
|
||||
|
||||
#if !HAS_SERVOS || DISABLED(EDITABLE_SERVO_ANGLES)
|
||||
#if ENABLED(SWITCHING_EXTRUDER)
|
||||
constexpr uint16_t sesa[][2] = SWITCHING_EXTRUDER_SERVO_ANGLES;
|
||||
#endif
|
||||
constexpr uint16_t servo_angles[MAX_SERVOS][2] = {
|
||||
#if ENABLED(SWITCHING_EXTRUDER)
|
||||
[SWITCHING_EXTRUDER_SERVO_NR] = { sesa[0], sesa[1] }
|
||||
#if EXTRUDERS > 3
|
||||
, [SWITCHING_EXTRUDER_E23_SERVO_NR] = { sesa[2], sesa[3] }
|
||||
#endif
|
||||
#elif ENABLED(SWITCHING_NOZZLE)
|
||||
[SWITCHING_NOZZLE_SERVO_NR] = SWITCHING_NOZZLE_SERVO_ANGLES
|
||||
#elif defined(Z_SERVO_ANGLES) && defined(Z_PROBE_SERVO_NR)
|
||||
[Z_PROBE_SERVO_NR] = Z_SERVO_ANGLES
|
||||
#endif
|
||||
};
|
||||
#endif
|
||||
|
||||
EEPROM_WRITE(servo_angles);
|
||||
|
||||
// 11 floats for DELTA / [XYZ]_DUAL_ENDSTOPS
|
||||
#if ENABLED(DELTA)
|
||||
|
||||
|
@ -1135,6 +1164,14 @@ void MarlinSettings::postprocess() {
|
|||
EEPROM_READ(dummyui8);
|
||||
#endif // AUTO_BED_LEVELING_UBL
|
||||
|
||||
//
|
||||
// SERVO_ANGLES
|
||||
//
|
||||
#if !HAS_SERVOS || DISABLED(EDITABLE_SERVO_ANGLES)
|
||||
uint16_t servo_angles[MAX_SERVOS][2];
|
||||
#endif
|
||||
EEPROM_READ(servo_angles);
|
||||
|
||||
//
|
||||
// DELTA Geometry or Dual Endstops offsets
|
||||
//
|
||||
|
@ -1774,6 +1811,44 @@ void MarlinSettings::reset(PORTARG_SOLO) {
|
|||
zprobe_zoffset = Z_PROBE_OFFSET_FROM_EXTRUDER;
|
||||
#endif
|
||||
|
||||
//
|
||||
// Servo Angles
|
||||
//
|
||||
|
||||
#if HAS_SERVOS && ENABLED(EDITABLE_SERVO_ANGLES)
|
||||
|
||||
#if ENABLED(SWITCHING_EXTRUDER)
|
||||
|
||||
#if EXTRUDERS > 3
|
||||
#define REQ_ANGLES 4
|
||||
#else
|
||||
#define REQ_ANGLES 2
|
||||
#endif
|
||||
constexpr uint16_t extruder_angles[] = SWITCHING_EXTRUDER_SERVO_ANGLES;
|
||||
static_assert(COUNT(extruder_angles) == REQ_ANGLES, "SWITCHING_EXTRUDER_SERVO_ANGLES needs " STRINGIFY(REQ_ANGLES) " angles.");
|
||||
servo_angles[SWITCHING_EXTRUDER_SERVO_NR][0] = extruder_angles[0];
|
||||
servo_angles[SWITCHING_EXTRUDER_SERVO_NR][1] = extruder_angles[1];
|
||||
#if EXTRUDERS > 3
|
||||
servo_angles[SWITCHING_EXTRUDER_E23_SERVO_NR][0] = extruder_angles[2];
|
||||
servo_angles[SWITCHING_EXTRUDER_E23_SERVO_NR][1] = extruder_angles[3];
|
||||
#endif
|
||||
|
||||
#elif ENABLED(SWITCHING_NOZZLE)
|
||||
|
||||
constexpr uint16_t nozzle_angles[2] = SWITCHING_NOZZLE_SERVO_ANGLES;
|
||||
servo_angles[SWITCHING_NOZZLE_SERVO_NR][0] = nozzle_angles[0];
|
||||
servo_angles[SWITCHING_NOZZLE_SERVO_NR][1] = nozzle_angles[1];
|
||||
|
||||
#elif defined(Z_SERVO_ANGLES) && defined(Z_PROBE_SERVO_NR)
|
||||
|
||||
constexpr uint16_t z_probe_angles[2] = Z_SERVO_ANGLES;
|
||||
servo_angles[Z_PROBE_SERVO_NR][0] = z_probe_angles[0];
|
||||
servo_angles[Z_PROBE_SERVO_NR][1] = z_probe_angles[1];
|
||||
|
||||
#endif
|
||||
|
||||
#endif // HAS_SERVOS && EDITABLE_SERVO_ANGLES
|
||||
|
||||
#if ENABLED(DELTA)
|
||||
const float adj[ABC] = DELTA_ENDSTOP_ADJ,
|
||||
dta[ABC] = DELTA_TOWER_ANGLE_TRIM;
|
||||
|
@ -2253,6 +2328,35 @@ void MarlinSettings::reset(PORTARG_SOLO) {
|
|||
|
||||
#endif // HAS_LEVELING
|
||||
|
||||
#if HAS_SERVOS && ENABLED(EDITABLE_SERVO_ANGLES)
|
||||
|
||||
if (!forReplay) {
|
||||
CONFIG_ECHO_START;
|
||||
SERIAL_ECHOLNPGM_P(port, "Servo Angles:");
|
||||
}
|
||||
for (uint8_t i = 0; i < NUM_SERVOS; i++) {
|
||||
switch (i) {
|
||||
#if ENABLED(SWITCHING_EXTRUDER)
|
||||
case SWITCHING_EXTRUDER_SERVO_NR:
|
||||
#if EXTRUDERS > 3
|
||||
case SWITCHING_EXTRUDER_E23_SERVO_NR:
|
||||
#endif
|
||||
#elif ENABLED(SWITCHING_NOZZLE)
|
||||
case SWITCHING_NOZZLE_SERVO_NR:
|
||||
#elif defined(Z_SERVO_ANGLES) && defined(Z_PROBE_SERVO_NR)
|
||||
case Z_PROBE_SERVO_NR:
|
||||
#endif
|
||||
CONFIG_ECHO_START;
|
||||
SERIAL_ECHOPAIR_P(port, " M281 P", int(i));
|
||||
SERIAL_ECHOPAIR_P(port, " L", servo_angles[i][0]);
|
||||
SERIAL_ECHOPAIR_P(port, " U", servo_angles[i][1]);
|
||||
SERIAL_EOL_P(port);
|
||||
default: break;
|
||||
}
|
||||
}
|
||||
|
||||
#endif // HAS_SERVOS && EDITABLE_SERVO_ANGLES
|
||||
|
||||
#if ENABLED(DELTA)
|
||||
|
||||
if (!forReplay) {
|
||||
|
|
|
@ -54,7 +54,6 @@ float zprobe_zoffset; // Initialized by settings.load()
|
|||
|
||||
#if HAS_Z_SERVO_PROBE
|
||||
#include "../module/servo.h"
|
||||
const int z_servo_angle[2] = Z_SERVO_ANGLES;
|
||||
#endif
|
||||
|
||||
#if ENABLED(Z_PROBE_SLED)
|
||||
|
@ -435,7 +434,7 @@ bool set_probe_deployed(const bool deploy) {
|
|||
|
||||
#elif HAS_Z_SERVO_PROBE && DISABLED(BLTOUCH)
|
||||
|
||||
MOVE_SERVO(Z_PROBE_SERVO_NR, z_servo_angle[deploy ? 0 : 1]);
|
||||
MOVE_SERVO(Z_PROBE_SERVO_NR, servo_angles[Z_PROBE_SERVO_NR][deploy ? 0 : 1]);
|
||||
|
||||
#elif ENABLED(Z_PROBE_ALLEN_KEY)
|
||||
|
||||
|
|
|
@ -53,7 +53,6 @@
|
|||
#endif
|
||||
|
||||
#if HAS_Z_SERVO_PROBE
|
||||
extern const int z_servo_angle[2];
|
||||
void servo_probe_init();
|
||||
#endif
|
||||
|
||||
|
|
|
@ -31,6 +31,7 @@
|
|||
#include "servo.h"
|
||||
|
||||
HAL_SERVO_LIB servo[NUM_SERVOS];
|
||||
uint16_t servo_angles[NUM_SERVOS][2];
|
||||
|
||||
void servo_init() {
|
||||
#if NUM_SERVOS >= 1 && HAS_SERVO_0
|
||||
|
|
|
@ -30,6 +30,7 @@
|
|||
#include "../HAL/shared/servo.h"
|
||||
|
||||
extern HAL_SERVO_LIB servo[NUM_SERVOS];
|
||||
extern uint16_t servo_angles[NUM_SERVOS][2];
|
||||
extern void servo_init();
|
||||
|
||||
#define MOVE_SERVO(I, P) servo[I].move(P)
|
||||
|
@ -37,8 +38,8 @@ extern void servo_init();
|
|||
#include "../inc/MarlinConfig.h"
|
||||
|
||||
#if HAS_Z_SERVO_PROBE
|
||||
#define DEPLOY_Z_SERVO() MOVE_SERVO(Z_PROBE_SERVO_NR, z_servo_angle[0])
|
||||
#define STOW_Z_SERVO() MOVE_SERVO(Z_PROBE_SERVO_NR, z_servo_angle[1])
|
||||
#define DEPLOY_Z_SERVO() MOVE_SERVO(Z_PROBE_SERVO_NR, servo_angles[Z_PROBE_SERVO_NR][0])
|
||||
#define STOW_Z_SERVO() MOVE_SERVO(Z_PROBE_SERVO_NR, servo_angles[Z_PROBE_SERVO_NR][1])
|
||||
#endif
|
||||
|
||||
#endif // _SERVO_H_
|
||||
|
|
|
@ -60,22 +60,18 @@
|
|||
#if DO_SWITCH_EXTRUDER
|
||||
|
||||
#if EXTRUDERS > 3
|
||||
#define REQ_ANGLES 4
|
||||
#define _SERVO_NR (e < 2 ? SWITCHING_EXTRUDER_SERVO_NR : SWITCHING_EXTRUDER_E23_SERVO_NR)
|
||||
#define _SERVO_NR(E) ((E) < 2 ? SWITCHING_EXTRUDER_SERVO_NR : SWITCHING_EXTRUDER_E23_SERVO_NR)
|
||||
#else
|
||||
#define REQ_ANGLES 2
|
||||
#define _SERVO_NR SWITCHING_EXTRUDER_SERVO_NR
|
||||
#define _SERVO_NR(E) SWITCHING_EXTRUDER_SERVO_NR
|
||||
#endif
|
||||
|
||||
void move_extruder_servo(const uint8_t e) {
|
||||
constexpr int16_t angles[] = SWITCHING_EXTRUDER_SERVO_ANGLES;
|
||||
static_assert(COUNT(angles) == REQ_ANGLES, "SWITCHING_EXTRUDER_SERVO_ANGLES needs " STRINGIFY(REQ_ANGLES) " angles.");
|
||||
planner.synchronize();
|
||||
#if EXTRUDERS & 1
|
||||
if (e < EXTRUDERS - 1)
|
||||
#endif
|
||||
{
|
||||
MOVE_SERVO(_SERVO_NR, angles[e]);
|
||||
MOVE_SERVO(_SERVO_NR(e), servo_angles[_SERVO_NR(e)][e]);
|
||||
safe_delay(500);
|
||||
}
|
||||
}
|
||||
|
@ -85,9 +81,8 @@
|
|||
#if ENABLED(SWITCHING_NOZZLE)
|
||||
|
||||
void move_nozzle_servo(const uint8_t e) {
|
||||
const int16_t angles[2] = SWITCHING_NOZZLE_SERVO_ANGLES;
|
||||
planner.synchronize();
|
||||
MOVE_SERVO(SWITCHING_NOZZLE_SERVO_NR, angles[e]);
|
||||
MOVE_SERVO(SWITCHING_NOZZLE_SERVO_NR, servo_angles[SWITCHING_NOZZLE_SERVO_NR][e]);
|
||||
safe_delay(500);
|
||||
}
|
||||
|
||||
|
|
|
@ -625,6 +625,10 @@
|
|||
#define MAX_EXTRUDERS 5
|
||||
#endif
|
||||
|
||||
#ifndef MAX_SERVOS
|
||||
#define MAX_SERVOS 4
|
||||
#endif
|
||||
|
||||
//
|
||||
// Assign auto fan pins if needed
|
||||
//
|
||||
|
|
Reference in a new issue