USB Hub Port Power
uhubctl_powerPower a USB hub port on or off to reset or isolate attached Meshtastic devices, targeting it by location/port or device role; turning off requires confirmation.
Instructions
Power a USB hub port on or off (uhubctl -a on|off, or vhfilter --switch-port on Windows).
Target the port by either (location, port), e.g. location="1-1.3", port=2 as
uhubctl_list reports it, OR by role, never both. action="off" requires
confirm=True, or the user's answer when the client can ask: the attached device
disappears from the OS at once. on never asks.
Returns {action, location, port, delay_s, duration_s, ...}.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"action": "<action>"
},
"name": "uhubctl_power"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| port | No | The port number on that hub. | |
| role | No | A device role ("nrf52", "esp32s3"). Role lookup honors `MESHTASTIC_UHUBCTL_LOCATION_<ROLE>` + `_PORT_<ROLE>` env vars first, then falls back to VID auto-detection. | |
| action | Yes | `on` or `off`. | |
| confirm | No | `True` once the user agreed; omitted, a client that can ask prompts the human. Only `off` asks. | |
| location | No | The hub location from `uhubctl_list`: uhubctl notation, or a PnP device path on Windows. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||