---
title: "Command Set for CoolMasterNet"
canonical: "https://docs.cuesystem.com/space/CVCDD/439779432/Command%20Set%20for%20CoolMasterNet"
format: markdown
---
The general functionality of the command set for of either CoolMasterNetSerial or CoolMasterNetTCPclient device and CoolMasterNetIndoorUnit are more and less identical and differs only partly and in their parameters identifying the selected Indoor Unit. By CoolMasterNetIndoorUnit instance the selection of particular indoor unit is done by driver property UID while by commands of CoolMasterNetSerial or CoolMasterNetTCPclient devices is the UID as command parameter.

# UID - Indoor Unit identification

The commands are providing wide variety possibilities to set the indoor HVAC units into different operation modes or set their parameters. The identification of the controlled Indoor Unit is done by so-called **UID** parameter.

**UID** is used to identify Indoor Unit or a set of Indoor Units. UID is of **Text** data type and has the following format: 

|  |  |  |
| --- | --- | --- |
| Line | Dot | Indoor Numer |
| “**Ln** | **.** | X | YY“ |

- Line is a CooLinkNet HVAC Line number in range L1..L4. **L*** means "any line".
- Dot is a separator between Line and Indoor Number. If Line is omitted or has a **L* **form, dot must also be omitted.
- Indoor Number is an Indoor Unit numer in HVAC system. Indoor Number can be '*' that means "any"

Examples:

|  |  |
| --- | --- |
| “L1.102“ | Indoor Unit 102 on line L1 |
| “L2.003“ | Indoor Unit 003 on line L2 |
| “L*100“ | Set of Indoor Units 100 on all lines |
| “L3.1*: | Set of Indoor Units 1xx on line L3 (L3.100, L3.101, ... ) |
| “L4“ | All Indoors on line L4 |
| “L*“ | All Indoors on all lines |
| “203“ | Similar to L*203 (for backward compatibility only) |

## UID_STRICT

In some cases only specific Indoor Unit should be referenced by UID. In this case it is required to use UID_STRICT in format **“Ln.XYY“ **where '*****' usage is prohibited.

# Commands

Return value - Most of the commands are returning Boolean value

- **True**   – in case the command was successfully send to CoolMasterNet unit and was confirmed as successfully accepted
- **False** – the command was not confirmed or reported as failed

> 📝 **Important note:**  
> 📝 
> 📝 All the processes concerning HVAC are rather slow so the execution of some command (– mainly commands for groups of Indoor Units!!) can be rather slow and take several tens of seconds prior the command is confirmed!

## Commands for Indoor Unit

###  //Mode commands

** SetModeAuto()**     As Boolean

 **SetModeHeat()**     As Boolean

 **SetModeCool()  **   As Boolean

 **SetModeDry()  **     As Boolean

 **SetModeFan() **      As Boolean

### //On/Off commands

 **On() **           As Boolean

 **Off() **          As Boolean

### //Reset Filter Sign commands

 **ResetFilterSign()**            As Boolean

### //Fan speed commands

 **FanSpeedLow()**         As Boolean

 **FanSpeedMiddle()**    As Boolean

 **FanSpeedHigh()**        As Boolean

 **FanSpeedAuto()**       As Boolean

 **FanSpeedTop()**         As Boolean 

### // Temperature commands

 **SetTemperature**(TemperatureInDegrees As Byte)                As Boolean

 **IncrementTemperature**(IncrementInDegrees As Byte)        As Boolean

 **DecrementTemperature**( DecrementInDegrees As Byte)    As Boolean

### // Set Swing commands

 **SetSwingAuto()**           As Boolean

 **SetSwingVertical()**       As Boolean

 **SetSwingHorizontal()**  As Boolean

** SetSwing30Degrees() ** As Boolean

 **SetSwing45Degrees() ** As Boolean

** SetSwing60Degrees()**  As Boolean

### // Status Query

> 📝 Following commands can not be used for groups of Indoor Units – so these are applicable only by objects where UID is set in form of **UID_STRICT**!

 **Query**(param As Text, ByRef replyStr As ByteString)  As Boolean - returns status of Indoor Unit in ByteString 

|  |  |  |
| --- | --- | --- |
| Parameter | reply meaning | value |
| o | On/Off | 0 - Off |
|  |  | 1 – On |
| m | Operation Mode | 0 - Cool |
|  |  | 1 - Heat |
|  |  | 2 - Auto |
|  |  | 3 - Dry |
|  |  | 4 - Haux |
|  |  | 5 – Fan |
| f | Fan Speed | 0 - Low |
|  |  | 1 - Medium |
|  |  | 2 – High |
|  |  | 3 – Auto |
|  |  | 4 - Top |
| t | Set Temperature | Natural |
| e | Failure Code | 0 – No failure, otherwise failure code |
| a | Ambient Temperature | Natural |
| h | Set Temperature | 0.01º Precision |
| s | Louver Positron | 0 - No Louver Control |
|  |  | a - auto (swing) |
|  |  | h - horizontal |
|  |  | 3 - 30º |
|  |  | 4 - 45º |
|  |  | 6 - 60º |
|  |  | v - vertical |

> ℹ️ This command based on command “query”  with parameter  set in param Text - for parameters meaning and details concerning reply data see [https://coolautomation.com/lib/doc/prm/HTML/CMNet_PRM/index.html](https://coolautomation.com/lib/doc/prm/HTML/CMNet_PRM/index.html) - command “query”.

**GetIndoorUnitStatus**( ByRef replyStr   As ByteString)  As Boolean  - returns status of Indoor Unit in ByteString 

Reply consists of : UID, On/Of status, Set and Ambient temperature, Fan speed, Operation Mode, Failure Code, Filter sign

Reply example:  &S”L1.101 OFF 32C 24,08C Low Dry OK 0\0d\0a”

where:

|  |  |  |
| --- | --- | --- |
| Example | Format | Description |
| L1.101 |  | Indoor Unit Address (UID) |
| OFF | ON/OFF | On/Off Status |
| 23C | NNC | Set Temperature C |
| 24,08C | NN,NNC | Room Temperature C |
| Auto | Low, Med, High, Auto, Top | Fan Speed |
| Cool | Cool, Heat, Fan, Dry, Auto, Bps, HExc, AutC, AutH | Operation Mode |
| OK | OK/Xn, Xnn, nnnn | OK Or Failure code |
| 0 | 0/1 | Filter Reset Sign present |
| \0d\0a | CR LF |  |

> ℹ️ This command based on command “stat2” with parameter set in param Text - for parameters meaning and details concerning reply data see [https://coolautomation.com/lib/doc/prm/HTML/CMNet_PRM/index.html](https://coolautomation.com/lib/doc/prm/HTML/CMNet_PRM/index.html)  - command “stat”. 
> ℹ️ 
> ℹ️ Note that in last version of documentation this command is mentioned as “obsolete” - but still supported.

##  Setting commands for CoolMasterNet Unit

> 📝 Following commands are valid for the whole CoolMasterNet unit and so these are available only in **CoolMasterNetSerial** or **CoolMasterNetTCPclient** device driver.

**SetDegreesInCelsius()**  As Boolean    

**SetDegreesInFahrenheit()**  As Boolean

**SetIP(** newip As Text,newmask As Text,newgateway As Text, newport As Long)  As Boolean    - Setting of TCPIP parameters :  **fixed**  IP , TCP port 

> ℹ️ This command based on commands “ifconfig” and ”set aserver port”  note that this setting  makes the CoolMasterNet unit to reboot - so the execution takes some time before the unit is operational again after executing this command!

**GetIPConfig(** ByRef replyStr As ByteString)  As Boolean - returns status in ByteString  the returned data are as in example:

- Example1 of retuned data:

MAC: 28:3B:96:FF:FF:FE\0d\0a Link: Up\0d\0aIP: 192.168.1.109 (DHCP)

Netmask: 255.255.255.0\0d\0a Gateway: 192.168.1.1\0d\0aOK\0d\0a

- Example2 of retuned data:

&S”MAC: 28:3B:96:00:01:9B\0D\0A Link: Up\0D\0AIP: 192.168.137.222 (Static)\0D\0A

Netmask: 255.255.255.0\0D\0A Gateway: 192.168.137.1\0D\0AOK

> ℹ️ This command is based on command “ifconfig” with no parameters - for details concerning reply data see [https://coolautomation.com/lib/doc/prm/HTML/CMNet_PRM/index.html](https://coolautomation.com/lib/doc/prm/HTML/CMNet_PRM/index.html)  - command “ifconfig”

**GetSettings(** ByRef replyStr As ByteString)  As Boolean - returns status in ByteString  as series of Property names followed by their actual value ended by \0D\0A.

The properties are as in following Table:

|  |  |  |  |
| --- | --- | --- | --- |
| Property | Printed as | Value | Description |
| S/N | S/N |  | CoolMasterNet Serial Number |
| Version | Version | X.Y.Z | CoolMasterNet Firmware Version |
| App | Application | string | CoolMasterNet Application |
| Baud | baud rate | 1200...115200 | RS232 Interface baud rate. Default: 9600 |
| Echo | echo | 0 or 1 | RS232 Interface echo control.   
0 - disabled, 1 - enabled |
| Verbose | verbose | 0 0r 1 | 0 - numeric, 1 - verbose |
| Server port | aserver port | integer | aserver TCP port. Default: 10102 |
| Server prompt | aserver prompt | 0 or 1 | aserver prompt kontrol,   
0 - disabled, 1 - enabled |
| Deg | deg C/F | C or F | Temperature scale Celsius or Fahrenheit |
| Filter | filter | 0 or 1 or - | filter sign |

Reply Example:

&S” S/N : 0500019B\0D\0 Aversion: 0.2.1\0D\0 Aapplication: Standard\0D\0 Abaud rate: 9600\0D\0A  
echo: 0\0D\0 Averbose: 1\0D\0 Aaserver port: 10102\0D\0Aaserver prompt: 1\0D\0A  
deg C/F: C\0D\0 Afilter: -\0D\0AHVAC”

> ℹ️ This command is based on command “set” with no parameters - for details concerning reply data see [https://coolautomation.com/lib/doc/prm/HTML/CMNet_PRM/index.html](https://coolautomation.com/lib/doc/prm/HTML/CMNet_PRM/index.html)  - command “set”.

**GetAllLinesStatus(** ByRef replyStr As ByteString)  As Boolean - returns status in ByteString  as series of Property names followed by their actual value

Return value:

|  |  |  |
| --- | --- | --- |
| Property | Value | Description |
| myID | string | CooLinkNet Own address on given HVAC Line. |
| baud | String | <BAUD> <8|9><N|E|O><1|2> For example: 9600 8N1 |
| Tx | Counter | Transmitted messages Printed |
| Rx | Counter | Received messages |
| TO | Counter | Timeout errors |
| CS | Counter | Checksum errors |
| Col | Counter | Collision errors |

Return value example:

&S“L1: Unused\0D\0ATx:0/0 Rx:0/0 TO:0/0 CS:0/0 Col:0/0 NAK:0/0\0D\0A

     L2: TI U00/G00\0D\0ATx:40/40 Rx:0/0 TO:39/39 CS:0/0 Col:0/0 NAK:0/0\0D\0A

     L3: CLMB Address:0x50(80) 9600_8N1\0D\0ATx:0/0 Rx:0/0 TO:0/0 CS:0/0 Col:0/0 NAK:0/0\0D\0A

     L4: FUS Slave U00/G00 Not Connected\0D\0ATx:0/0 Rx:0/0 TO:0/0 CS:0/0 Col:0/0 NAK:0/0\0D\0A

              OK\0D\0A”

> ℹ️ This command is based on command “line” with no parameters - for details concerning reply data see [https://coolautomation.com/lib/doc/prm/HTML/CMNet_PRM/index.html](https://coolautomation.com/lib/doc/prm/HTML/CMNet_PRM/index.html)  - command “line”.

**SimulateON(** lineUnits as Text) As Boolean -Debugging command for Indoor unit simulation. 

> ℹ️ This command based on command “simul” with parameter set in lineUnit Text - Note that Simulation is not persistent and CoolMasterNet reset will terminate it!

Example :

Cool1.SimulateON(“L2 5“) - start simulation of 5 indoor units on HVACline L2 of CoolMasrerNet device Cool1

Cool1.SimulateON(“5“) - start simulation of 5 indoor units on first unused HVACline of CoolMasrerNet device

**Reset(**   ) As Boolean  - reboot CoolMasterNet unit