public static interface BrickServo.PositionReachedListener extends DeviceListener
BrickServo.setPosition(short, short)
is reached. If the new position matches the current position then the
listener is not triggered, because the servo didn't move.
The parameters are the servo and the position that is reached.
You can enable this listener with BrickServo.enablePositionReachedCallback()
.
\note
Since we can't get any feedback from the servo, this only works if the
velocity (see BrickServo.setVelocity(short, int)
) is set smaller or equal to the
maximum velocity of the servo. Otherwise the servo will lag behind the
control value and the listener will be triggered too early.Modifier and Type | Method and Description |
---|---|
void |
positionReached(short servoNum,
short position) |
Copyright © 2021 Tinkerforge GmbH. All rights reserved.