microbit: changes to the default servo range

Previously the range of the servo API was incorrect and would only
translate to a range 0 degrees - 90 degrees in the real world.

This patch updates the #defines used in the servo api default
calculation to calibrate for the intended range of 0 - 180 degrees.

This was all due to working from a specification that applied to a
subset of servos.
This commit is contained in:
James Devine 2016-02-22 15:34:27 +00:00
parent 5ec546980b
commit aa7ce13e58

View file

@ -35,8 +35,8 @@
#define MICROBIT_PIN_MAX_OUTPUT 1023
#define MICROBIT_PIN_MAX_SERVO_RANGE 180
#define MICROBIT_PIN_DEFAULT_SERVO_RANGE 1000
#define MICROBIT_PIN_DEFAULT_SERVO_CENTER MICROBIT_PIN_DEFAULT_SERVO_RANGE + MICROBIT_PIN_DEFAULT_SERVO_RANGE/2
#define MICROBIT_PIN_DEFAULT_SERVO_RANGE 2000
#define MICROBIT_PIN_DEFAULT_SERVO_CENTER 1500
/**