Overview
The Material Action Client is a simple test node that executes a complete excavation-then-deposition sequence. It is primarily used for bench testing, CI smoke checks, and verifying the material handling system integration. Package:lunabot_controlNode Name:
material_action_clientSource:
src/lunabot_control/lunabot_control/material_action_client.py
Purpose
This client node provides:- Automated testing of the excavation and deposition action sequence
- Validation that both action servers are available and responding
- Configurable timeout and goal parameters for testing
- Clear success/failure reporting for CI integration
Parameters
Maximum time allowed for the excavation operation in seconds
Maximum time allowed for the deposition operation in seconds
Duration to hold the dump position before closing in seconds
Action Clients
The node creates action clients for:/mission/excavate- Excavate action interface/mission/deposit- Deposit action interface
Execution Sequence
Wait for servers
The client waits up to 5 seconds for both action servers to become available. If either server is unavailable, the sequence fails immediately.
Send excavation goal
Sends an excavation goal with:
- Mode:
MODE_AUTO - Timeout: Configured
excavate_timeout_s - Target fill: 0.8 (80% capacity)
- Max speed: 0.2 m/s
Wait for excavation result
Blocks until the excavation action completes. If the action is rejected or fails, the sequence terminates with an error.
Send deposition goal
Sends a deposition goal with:
- Mode:
MODE_AUTO - Timeout: Configured
deposit_timeout_s - Dump duration: Configured
dump_duration_s - Require close:
true
Wait for deposition result
Blocks until the deposition action completes. If the action is rejected or fails, the sequence terminates with an error.
Usage
Launch the client
Launch with custom parameters
Check exit status
The node exits with status code 0 on success, non-zero on failure:Exit Codes
| Code | Meaning |
|---|---|
| 0 | Sequence completed successfully |
| 1 | Action server unavailable, goal rejected, or operation failed |
Integration Testing
This client is designed for automated testing workflows:Source Reference
Seesrc/lunabot_control/lunabot_control/material_action_client.py:10-114 for the complete implementation.
Related
- Material Action Server - The server implementation
- Excavate Action - Excavation action interface
- Deposit Action - Deposition action interface