ServoKit.Servo behaviour (servo_kit v0.0.5) View Source
Defines a behaviour required for a servo.
Link to this section Summary
Link to this section Types
Link to this section Callbacks
Specs
Executes the specified command and returns the updated state.
Examples
ServoKit.StandardServo.call(state, {:set_angle, [0, 90]})
Specs
Initializes the servo.
Examples
%{i2c_bus: "i2c-1"}
|> ServoKit.PCA9685.new()
|> ServoKit.StandardServo.new(%{
angle_max: 180,
duty_cycle_minmax: {2.5, 12.5}
})