ArmorLinkModule
ArmorLinkModule describes one ArmorLink node: its name, type, profile metadata, actions, configuration and telemetry.
Basic Usage
#include <ArmorLink.h>
ArmorLinkModule module(
"Helmet",
ArmorLinkModuleType::Helmet
);
void setup()
{
ArmorLinkOptions options;
options.nodeName = "Helmet";
options.enableEspNow = true;
ArmorLink.begin(module, options);
}
Constructor
ArmorLinkModule module("Module Name", ArmorLinkModuleType::Generic);
The constructor defines the initial module name and module type. ArmorLinkOptions::nodeName can override the runtime node name.
Module Types
Supported built-in types:
ArmorLinkModuleType::GenericArmorLinkModuleType::ChestArmorLinkModuleType::HelmetArmorLinkModuleType::BackArmorLinkModuleType::ArmArmorLinkModuleType::HandArmorLinkModuleType::LegArmorLinkModuleType::Prop
Types are descriptive. They help the App choose labels and icons, but do not change routing behavior.
Version Metadata
A descriptor contains both the firmware module version and the ArmorLink library version.
{
"moduleVersion": "1.0",
"armorLinkVersion": "0.4.0"
}
The module version comes from the module instance. The ArmorLink version comes from the library.
Profiles
Modules can declare profile compatibility:
module.profileTarget("muehliindustries.armorlink.helmet.v1");
module.profileName("Iron Patriot Generic Helmet");
| Method | Description |
|---|---|
profileTarget(...) | Stable identifier used to find compatible profiles. |
profileName(...) | Active or default profile name shown by setup tools. |
defaultProfileName(...) | Optional default profile label. |
A profile target should be stable across firmware releases that support the same configuration shape.
Exposed Functionality
A module can expose:
module.config(); // Persistent settings and descriptor fields
module.actions(); // Commands shown as App/configurator actions
module.serial(); // Optional serial commands
Actions
module.actions()
.add("toggleFaceplate")
.label("Toggle Faceplate")
.section("Faceplate")
.command("Facemask", "toggle")
.stylePrimary()
.onExecute([] {
toggleFaceplate();
});
See Actions API.
Configuration
module.config()
.addInt("openingDurationMs", &openingDurationMs, 700)
.label("Opening Duration")
.section("Faceplate")
.range(100, 5000)
.step(50);
See Configuration API.
Servo Configuration
module.config()
.addServoConfig("servo1", &servo1)
.section("Servo 1")
.gpio(16)
.openPosition(10)
.closedPosition(158)
.pulseRange(500, 2400);
See Servo Config API.
Gateway Role
A Gateway is a role enabled through ArmorLinkOptions, not a separate module type.
ArmorLinkOptions options;
options.enableGateway = true;
options.enableBle = true;
options.enableEspNow = true;
A Helmet can be a Gateway in a single-node setup, and a Chest can be a Gateway in a multi-node suit.
Summary
ArmorLinkModule defines the firmware-facing identity and capabilities of a node. ArmorLink 0.4.0 descriptors expose this information to the App and Web Node Configurator.