Emergency stop - immediately halt all motion.
(self)
| 557 | print(f"Failed to send gripper command: {e}") |
| 558 | |
| 559 | def emergency_stop(self) -> bool: |
| 560 | """Emergency stop - immediately halt all motion.""" |
| 561 | try: |
| 562 | print("🚨 EMERGENCY STOP!") |
| 563 | |
| 564 | # Send emergency stop commands to hardware |
| 565 | self.piper.MotionCtrl_1(0x02, 0, 0) |
| 566 | self.piper.GripperCtrl(0, 0, 0x00, 0) |
| 567 | |
| 568 | # Disable robot hardware |
| 569 | self._disable_robot() |
| 570 | |
| 571 | print("✓ Emergency stop completed") |
| 572 | return True |
| 573 | |
| 574 | except Exception as e: |
| 575 | print(f"✗ Emergency stop error: {e}") |
| 576 | return False |
| 577 | |
| 578 | def graceful_stop(self) -> bool: |
| 579 | """Gracefully stop the robot and move to home position.""" |
nothing calls this directly
no test coverage detected