j5.backends.console.sr.v4.motor_board module¶
Console Backend for the SR v4 Motor Board.
-
class
j5.backends.console.sr.v4.motor_board.
SRV4MotorBoardConsoleBackend
(serial: str, console_class: Type[j5.backends.console.console.Console] = <class 'j5.backends.console.console.Console'>)[source]¶ Bases:
j5.components.motor.MotorInterface
,j5.backends.backend.Backend
The console implementation of the SR v4 motor board.
-
board
¶
-
classmethod
discover
() → Set[j5.boards.board.Board][source]¶ Discover boards that this backend can control.
Returns: set of boards that this backend can control.
-
firmware_version
¶ The firmware version reported by the board.
Returns: firmware version reported by the board, if any.
-
get_motor_state
(identifier: int) → Union[float, j5.components.motor.MotorSpecialState][source]¶ Get the current motor state.
Parameters: identifier – identifier of the motor Returns: state of the motor.
-
serial
¶ The serial number reported by the board.
Returns: serial number reported by the board.
-
set_motor_state
(identifier: int, power: Union[float, j5.components.motor.MotorSpecialState]) → None[source]¶ Set the state of a motor.
Parameters: - identifier – identifier of the motor
- power – state of the motor.
Raises: ValueError – invalid motor identifier.
-