| """ | |
| π€ ReachyMini Simulator Launcher | |
| Run this FIRST in a separate terminal before starting the Haven app! | |
| """ | |
| import asyncio | |
| from reachy_mini.daemon.daemon import Daemon | |
| async def main(): | |
| print("π Starting ReachyMini MuJoCo Simulator...") | |
| print(" (Keep this terminal open while using Haven)") | |
| print() | |
| daemon = Daemon() | |
| await daemon.start( | |
| sim=True, # Use MuJoCo simulation | |
| headless=False, # Show the GUI window | |
| localhost_only=True, | |
| wake_up_on_start=True | |
| ) | |
| # Keep running until Ctrl+C | |
| try: | |
| while True: | |
| await asyncio.sleep(1) | |
| except KeyboardInterrupt: | |
| print("\nπ Shutting down simulator...") | |
| await daemon.stop() | |
| if __name__ == "__main__": | |
| asyncio.run(main()) | |