The device the update is aimed at.
The setpoint to apply, in degrees Celsius, or undefined to leave it unchanged.
The operating mode to apply, or undefined to leave it unchanged.
OptionalcurrentMode: MysaDeviceMode
The device's current mode, used to pick the setpoint section when mode is undefined.
The update body, or undefined when there is nothing to change.
Builds the body of a shadow state update that applies a setpoint and/or an operating mode.
Heating-only devices keep their setpoint in
targetHeat. Devices that can cool keep it intargetCoolwhile cooling, so the section is picked from the requested mode, or from the device's current mode when only a setpoint is being changed.