Files
node-intellicenter/messages/get-heater.ts
Parnic e306a62e24 Add messages, cleanup
This adds a bunch of messages to retrieve and set various things on the controller. It also groups the messages under one export to simplify the process of using and discovering many of them from one location.

Some of these are WIP/probably not portable to other systems.

This also adds the ability to set multiple circuits at once.
2025-01-03 20:27:30 -06:00

25 lines
734 B
TypeScript

import { GetRequest, ICRequest, ICRequestObj } from "./request.js";
/**
* Requests the list of heaters known to this controller.
*
* The response contains an `objectList` populated with heater information.
*
* @returns the object used to issue this request
*/
export function GetHeaters(): ICRequest {
const req = GetRequest();
req.command = "GetParamList";
req.condition = "OBJTYP = HEATER";
req.objectList = [];
const reqObj = new ICRequestObj();
reqObj.objnam = "ALL";
reqObj.keys = [
"OBJTYP: SUBTYP: SNAME: LISTORD: STATUS: PERMIT: TIMOUT: READY: HTMODE : SHOMNU : COOL : COMUART : BODY : HNAME : START : STOP : HEATING : BOOST : TIME : DLY : MODE",
];
req.objectList.push(reqObj);
return req;
}