Available Commands
The Anova Precision® Cooker Nano uses a structured command system based on Protocol Buffers, organized by domain and message type.
Command Structure
Each command consists of:
- Domain byte (function category)
- Message type byte (specific command)
- Optional Protocol Buffer payload
Domain Categories
Domain | Value | Description |
---|---|---|
CONFIG | 0x01 | Device configuration commands |
Available Commands
Configuration Domain (0x01)
Command | Message Type | Payload | Description |
---|---|---|---|
GET_TEMP_UNITS | 0x04 | None | Read temperature unit |
SET_TEMP_UNITS | 0x03 | IntegerValue | Set temperature unit (0=C, 1=F) |
GET_TEMP_SETPOINT | 0x02 | None | Read target temperature |
SET_TEMP_SETPOINT | 0x01 | IntegerValue | Set target temperature (scaled ×10) |
GET_COOKING_TIMER | 0x06 | None | Read current timer value |
SET_COOKING_TIMER | 0x05 | IntegerValue | Set timer in minutes |
GET_FIRMWARE_INFO | 0x01 | None | Read firmware information |
GET_SENSORS | 0x01 | None | Read all sensor values |
START_COOKING | 0x01 | None | Start cooking process |
STOP_COOKING | 0x02 | None | Stop cooking process |
Command Examples
Setting Temperature
To set the temperature to 65.5°C:
- Create an IntegerValue with value 655 (65.5 × 10)
- Construct command: [CONFIG_DOMAIN, SET_TEMP_SETPOINT, serialized_value]
- COBS encode the command
- Append terminator byte (0x00)
- Send to TX characteristic
Starting a Cook
To start cooking:
- Construct command: [CONFIG_DOMAIN, START_COOKING]
- COBS encode the command
- Append terminator byte (0x00)
- Send to TX characteristic
Reading Sensors
To request sensor values:
- Construct command: [CONFIG_DOMAIN, GET_SENSORS]
- COBS encode the command
- Append terminator byte (0x00)
- Send to TX characteristic
- Receive and decode response as SensorValueList protocol buffer
Response Formats
Temperature Reading
message SensorValue {
int32 value = 1; // Scaled by 10
UnitType units = 2; // 0=C, 1=F
SensorType type = 3; // Sensor identifier
}
Firmware Information
message FirmwareInfo {
string commit_id = 1;
string tag = 2;
int32 date_code = 3;
}
Scale Factors
Remember to apply appropriate scaling when working with temperature values:
Value Type | Scale Factor | Example |
---|---|---|
Target Temperature | ×10 | 65.5°C → 655 |
Sensor Temperature | ×10 | 24.7°C → 247 |
Command Data Flow
The following steps outline a typical data flow when issuing a command:
-
Encoding the Command:
- Construct a 2-byte header: [Domain, MessageType]
- Append any required payload data
- Encode using COBS algorithm
- Append trailing zero byte
-
Transmitting the Command:
- Split the encoded command into chunks (≤ 20 bytes)
- Write chunks sequentially to TX characteristic
-
Receiving the Response:
- Listen for notifications on RX characteristic
- Aggregate chunks until complete message is received
- COBS decode the complete message
- Parse using appropriate protocol buffer type
Command Validation
The device validates both the command structure and payload values. Invalid commands will return an error response.
Temperature Scaling
Remember that temperature values use a scale factor of 10 when communicating with the device.
Protocol Buffers
Refer to the Protocol Buffer Definitions page for detailed message type specifications.