diff --git a/content/docs/development/extending-the-runtime.mdx b/content/docs/development/extending-the-runtime.mdx index e12d7da2..d96601b8 100644 --- a/content/docs/development/extending-the-runtime.mdx +++ b/content/docs/development/extending-the-runtime.mdx @@ -326,11 +326,9 @@ that pins the behaviour is `register_overwrites` at `:190-197`). An unknown `use` value is a hard error listing what is registered (`drivers/mod.rs:232-247`). If the registry is empty the message instead reads -"No node types are registered. Call `register!()` or `terra_horus::register_all()` -first" (`drivers/mod.rs:238`) — and there is no `register!` macro: the only -`macro_rules!` in `horus_core` on this path is `register_driver!` -(`registry.rs:123`). Ignore the name in the message and use `register_driver!` -or `registry::register`. +"No node types are registered. Call `register_driver!()` first, or depend on a +crate that registers its driver types." (`drivers/mod.rs:286`) — the same macro +this page uses, so there is nothing to translate. The macro registers by emitting a static into `.init_array` — the ELF diff --git a/content/docs/examples/index.mdx b/content/docs/examples/index.mdx index 85461ea3..bd7a730e 100644 --- a/content/docs/examples/index.mdx +++ b/content/docs/examples/index.mdx @@ -53,7 +53,7 @@ on the pull request that caused it, not a day later. | Example | Language | What it teaches | |---------|----------|-----------------| -| [driver_integration](https://github.com/softmata/horus/tree/main/examples/driver_integration) | Rust | Hardware drivers from the manifest, Terra HAL, custom driver nodes | +| [driver_integration](https://github.com/softmata/horus/tree/main/examples/driver_integration) | Rust | Hardware drivers from the manifest, custom driver nodes | | [record_replay](https://github.com/softmata/horus/tree/main/examples/record_replay) | Rust | Session recording, blackbox forensics, deterministic replay | ## Coming from ROS 2 diff --git a/content/docs/package-management/configuration.mdx b/content/docs/package-management/configuration.mdx index 80ef69e3..cc8518da 100644 --- a/content/docs/package-management/configuration.mdx +++ b/content/docs/package-management/configuration.mdx @@ -746,7 +746,7 @@ topic_state = "arm/state" | `crate` | string | Legacy source key: Rust crate | | `pip` | string | Legacy source key: PyPI distribution | | `exec` | string | Legacy source key: run an external executable | -| `terra` | string | Legacy source key: Terra driver shortname | +| `terra` | string | Legacy source key: driver shortname — prefer `use` | | `source` | string | Where to resolve the package from | | `simulated` | bool | Alias of `sim` — substitute the simulated stub under `horus run --sim`. This is the key `horus add --driver --source sim` writes. An explicit `sim` wins if both are present | diff --git a/public/schema/horus.toml.schema.json b/public/schema/horus.toml.schema.json index 78cd3bb9..e9a6c0d5 100644 --- a/public/schema/horus.toml.schema.json +++ b/public/schema/horus.toml.schema.json @@ -312,7 +312,7 @@ } }, "DriverTableConfig": { - "description": "Structured driver configuration from a `[drivers.NAME]` TOML table.\n\nExactly one of `terra`, `package`, or `node` should be present to identify\nthe driver source. All other keys are captured in `params` and passed to\nthe driver factory at runtime.\n\n# Examples\n\n```toml\n# Terra driver (pre-built hardware support)\n[drivers.arm]\nterra = \"dynamixel\"\nport = \"/dev/ttyUSB0\"\nbaudrate = 1000000\nservo_ids = [1, 2, 3, 4, 5, 6]\n\n# Registry package (community/vendor driver)\n[drivers.force_sensor]\npackage = \"horus-driver-ati-netft\"\naddress = \"192.168.1.100\"\n\n# Local code (user's own driver registered via register_driver!)\n[drivers.conveyor]\nnode = \"ConveyorDriver\"\nport = \"/dev/ttyACM0\"\nbaudrate = 57600\n```", + "description": "Structured driver configuration from a `[drivers.NAME]` TOML table.\n\nUse exactly one source key — `use` (the unified key), `package`, or `node`.\nThe legacy shortname key is read as a fallback for `use`. All other keys are\ncaptured in `params` and passed to the driver factory at runtime.\n\n# Examples\n\n```toml\n# Built-in driver (pre-installed hardware support)\n[drivers.arm]\nuse = \"dynamixel\"\nport = \"/dev/ttyUSB0\"\nbaudrate = 1000000\nservo_ids = [1, 2, 3, 4, 5, 6]\n\n# Registry package (community/vendor driver)\n[drivers.force_sensor]\npackage = \"horus-driver-ati-netft\"\naddress = \"192.168.1.100\"\n\n# Local code (user's own driver registered via register_driver!)\n[drivers.conveyor]\nnode = \"ConveyorDriver\"\nport = \"/dev/ttyACM0\"\nbaudrate = 57600\n```", "type": "object", "properties": { "args": { @@ -382,7 +382,7 @@ ] }, "terra": { - "description": "Terra driver shortname (legacy — use `use` instead).", + "description": "Legacy driver shortname — use `use` instead.", "type": [ "string", "null" @@ -410,7 +410,7 @@ ] }, "use": { - "description": "Node type name — the new unified source key (e.g., `\"dynamixel\"`, `\"rplidar\"`).\nReplaces the 6 legacy keys (terra, package, node, crate, pip, exec).", + "description": "Node type name — the new unified source key (e.g., `\"dynamixel\"`, `\"rplidar\"`).\nReplaces the legacy source keys.", "type": [ "string", "null" @@ -420,10 +420,10 @@ "additionalProperties": true }, "DriverValue": { - "description": "Driver configuration value.\n\nThree forms:\n- Config table: `[drivers.arm]` with `terra`/`package`/`node` key + params\n- Simple string: `camera = \"opencv\"` (backend name → feature flags)\n- Enable bool: `camera = true` (enable with default backend)\n\nThe `Config` variant must be first — `#[serde(untagged)]` tries variants\nin order, and TOML tables must match before scalar strings/bools.", + "description": "Driver configuration value.\n\nThree forms:\n- Config table: `[drivers.arm]` with a source key (`use`/`package`/`node`) + params\n- Simple string: `camera = \"opencv\"` (backend name → feature flags)\n- Enable bool: `camera = true` (enable with default backend)\n\nThe `Config` variant must be first — `#[serde(untagged)]` tries variants\nin order, and TOML tables must match before scalar strings/bools.", "anyOf": [ { - "description": "Config table: `[drivers.arm]` with terra/package/node key + params.", + "description": "Config table: `[drivers.arm]` with a source key + params.", "$ref": "#/$defs/DriverTableConfig" }, {