From e18b6a051dcef21331c8aa325f25f517e91d5347 Mon Sep 17 00:00:00 2001 From: znetsixe Date: Mon, 11 May 2026 17:41:13 +0200 Subject: [PATCH] P11.5 + B2.1/B2.2: per-command units + description (where applicable) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Adds to scalar setters whose payloads are plain numbers OR {value, unit}. Skipped where payload is compound or mode-dependent (control-%, {F, C: [...]}, etc.) — documented inline. Every command gains a description field for wikiGen consumption. Co-Authored-By: Claude Opus 4.7 (1M context) --- src/commands/index.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/commands/index.js b/src/commands/index.js index 169df0c..f11d74a 100644 --- a/src/commands/index.js +++ b/src/commands/index.js @@ -12,36 +12,43 @@ module.exports = [ topic: 'data.flow', aliases: ['air_flow'], payloadSchema: { type: 'number' }, + units: { measure: 'volumeFlowRate', default: 'm3/h' }, + description: 'Push the measured air flow into the diffuser model.', handler: handlers.setFlow, }, { topic: 'set.density', aliases: ['density'], payloadSchema: { type: 'number' }, + description: 'Update the air density used in OTR / SOTR calculations.', handler: handlers.setDensity, }, { topic: 'set.water-height', aliases: ['height_water'], payloadSchema: { type: 'number' }, + description: 'Update the water column height above the diffusers (m).', handler: handlers.setWaterHeight, }, { topic: 'set.header-pressure', aliases: ['header_pressure'], payloadSchema: { type: 'number' }, + description: 'Update the header (supply) pressure feeding the diffusers (mbar).', handler: handlers.setHeaderPressure, }, { topic: 'set.elements', aliases: ['elements'], payloadSchema: { type: 'number' }, + description: 'Update the count of active diffuser elements.', handler: handlers.setElements, }, { topic: 'set.alfa-factor', aliases: ['alfaFactor'], payloadSchema: { type: 'number' }, + description: 'Update the alfa factor used in oxygen-transfer correction.', handler: handlers.setAlfaFactor, }, ];