Files
JackBot/RobotState/idle.py
T
JackM323 1e660fcdb6 Add copy methods, fix state imports, pass lock
Add copy() to PosArray, DegArray and RadArray to allow easy shallow copies. Change RobotState imports in idle.py and walking.py to use explicit 'from RobotState.RobotState import RobotState' to avoid import issues. In main.py create a threading.Lock and pass it into the controller thread args to prepare for synchronized access in controller_loop.
2026-07-29 22:17:28 +02:00

7 lines
192 B
Python

from RobotState.RobotState import RobotState
class IdleState(RobotState):
def update(self, ctx, intent, dt):
if intent.walk:
return "walking"
return None