pamoja.sim
Idiomatic simulated-device facade.
Drive a whole node with no hardware attached: a sensor that drifts, a replay of a
real capture, an actuator that records what it was told, and a robot that moves
only in arithmetic. A lossy link is Transport.degraded, since it wraps a
transport rather than standing alone.
1"""Idiomatic simulated-device facade. 2 3Drive a whole node with no hardware attached: a sensor that drifts, a replay of a 4real capture, an actuator that records what it was told, and a robot that moves 5only in arithmetic. A lossy link is `Transport.degraded`, since it wraps a 6transport rather than standing alone. 7""" 8 9from __future__ import annotations 10 11from pamoja._native import Pose, RecordingActuatorHandle, Replay, SimulatedRobot, SimulatedSensor 12 13__all__ = [ 14 "Pose", 15 "RecordingActuator", 16 "Replay", 17 "SimulatedRobot", 18 "SimulatedSensor", 19] 20 21#: An actuator that records every command instead of acting on one. 22RecordingActuator = RecordingActuatorHandle
class
Pose:
Where a robot is and which way it faces.
RecordingActuator =
<class 'builtins.RecordingActuatorHandle'>
class
Replay:
A sensor that reads back a recorded series.
This is how a caller replays a real capture, so a test asks what the code does with readings that actually happened rather than ones it invented.
class
SimulatedRobot:
A robot that moves only in arithmetic.
class
SimulatedSensor:
A sensor that invents plausible readings.