API Reference
This page describes the concepts and operations needed to implement a client application for the Anova Precision Cooker Mini, independent of any specific programming language.
Core Components
Any implementation should include these key components:
Device Scanner
Functionality for discovering compatible devices:
Operation | Description |
---|---|
Scan for devices | Look for devices advertising the Gen 3 service UUID |
Filter devices | Optional filtering by device name |
Select device | Select appropriate device from scan results |
Device Client
Core functionality for device communication:
Operation | Description |
---|---|
Connect | Establish connection and verify characteristics |
Disconnect | Safely disconnect from device |
Encode command | Convert command object to Base64 encoded format |
Decode response | Convert Base64 encoded response to object |
Read characteristic | Read data from specified characteristic |
Write characteristic | Write data to specified characteristic |
Command Handler
Higher-level operations for device control:
Operation | Description |
---|---|
Get system info | Read and decode system information |
Get device state | Read current device state |
Get current temperature | Read current temperature value |
Get timer | Read timer status |
Get full state | Collect and merge all state information |
Set clock | Set device clock to current time |
Set unit | Change temperature unit |
Set temperature | Set target temperature |
Start cook | Start cooking process |
Stop cook | Stop cooking process |
Device Operations
Device Discovery
1. Create BLE scanner
2. Filter for service UUID "910772a8-a5e7-49a7-bc6d-701e9a783a5c"
3. Optional: Filter by device name prefix
4. Return list of matching devices
Connection
1. Select device from discovery results
2. Establish connection
3. Verify all required characteristics
4. Set device clock
Command/Response Flow
1. Create command object
2. Convert to JSON
3. Base64 encode
4. Write to appropriate characteristic
5. For read operations:
a. Read from characteristic
b. Base64 decode
c. Parse JSON
d. Return result object
Command Formats
System Info Read
Read from SYSTEM_INFO characteristic:
Response:
{
"deviceName": "Anova Precision Cooker Mini",
"firmwareVersion": "1.2.3",
"serialNumber": "ANV00123456789",
// Additional system information
}
Device State Read
Read from STATE characteristic:
Response:
{
"state": "idle|cooking|...",
"temperatureUnit": "C|F",
// Additional state fields
}
Current Temperature Read
Read from CURRENT_TEMPERATURE characteristic:
Response:
{
"current": 65.0
}
Timer Read
Read from TIMER characteristic:
Response:
{
"running": true|false,
"remaining": 3600
}
Set Temperature
Write to SET_TEMPERATURE characteristic:
Request:
{
"setpoint": 65.0
}
Set Clock
Write to SET_CLOCK characteristic:
Request:
{
"currentTime": "2024-02-06T12:00:00Z"
}
Change Unit
Write to STATE characteristic:
Request:
{
"command": "changeUnit",
"payload": {
"temperatureUnit": "C"
}
}
Start Cook
Write to STATE characteristic:
Request:
{
"command": "start",
"payload": {
"setpoint": 65.0,
"timer": 3600,
"cookableId": "recipe123",
"cookableType": "recipe"
}
}
Stop Cook
Write to STATE characteristic:
Request:
{
"command": "stop"
}
UUID Reference
Service UUID
GEN_3_SERVICE_UUID = "910772a8-a5e7-49a7-bc6d-701e9a783a5c"
Characteristic UUIDs
SET_TEMPERATURE: "0f5639f7-3c4e-47d0-9496-0672c89ea48a"
CURRENT_TEMPERATURE: "6ffdca46-d6a8-4fb2-8fd9-c6330f1939e3"
TIMER: "a2b179f8-944e-436f-a246-c66caaf7061f"
STATE: "54e53c60-367a-4783-a5c1-b1770c54142b"
SET_CLOCK: "d8a89692-cae8-4b74-96e3-0b99d3637793"
SYSTEM_INFO: "153c9432-7c83-4b88-9252-7588229d5473"
Remember that all communications use Base64 encoding of JSON payloads. Implement robust encoding/decoding functions to handle this consistently.
Implement appropriate error handling, especially for encoding/decoding operations and connection issues. Be prepared to handle timeouts and retry operations when appropriate.
Note that the STATE characteristic serves dual purposes - both reading the device state and sending control commands. Context is important when interacting with this characteristic.