feat: refactor sgclaw around zeroclaw compat runtime
This commit is contained in:
41
third_party/zeroclaw/examples/hardware/aardvark/devices/aardvark0.md.example
vendored
Normal file
41
third_party/zeroclaw/examples/hardware/aardvark/devices/aardvark0.md.example
vendored
Normal file
@@ -0,0 +1,41 @@
|
||||
# aardvark0 — <Device Name> (<Part Number>)
|
||||
|
||||
<!-- Copy this file to ~/.zeroclaw/hardware/devices/aardvark0.md -->
|
||||
<!-- Fill in the device details from the datasheet. -->
|
||||
|
||||
## Connection
|
||||
|
||||
- Adapter: Total Phase Aardvark (aardvark0)
|
||||
- Protocol: I2C <!-- or SPI -->
|
||||
- I2C Address: 0x48 <!-- change to the actual device address -->
|
||||
- Bitrate: 100 kHz
|
||||
|
||||
## Key Registers (from datasheet)
|
||||
|
||||
<!-- Example for LM75 temperature sensor — replace with your device -->
|
||||
| Register | Address | Description | Notes |
|
||||
|----------|---------|----------------------------------------|------------------------|
|
||||
| Temp | 0x00 | Temperature (2 bytes, big-endian) | MSB × 0.5 °C per LSB |
|
||||
| Config | 0x01 | Configuration register | Read/write |
|
||||
| Thyst | 0x02 | Hysteresis temperature | Read/write |
|
||||
| Tos | 0x03 | Overtemperature shutdown threshold | Read/write |
|
||||
|
||||
## Datasheet
|
||||
|
||||
- File: `~/.zeroclaw/hardware/datasheets/<device>.pdf`
|
||||
- Source: <!-- URL where you downloaded the datasheet -->
|
||||
|
||||
## Verified Working Commands
|
||||
|
||||
```python
|
||||
# Read temperature from LM75 at I2C address 0x48, register 0x00
|
||||
i2c_read(addr=0x48, register=0x00, len=2)
|
||||
|
||||
# Convert two bytes to °C:
|
||||
# raw = (byte[0] << 1) | (byte[1] >> 7)
|
||||
# temp = raw * 0.5 (if byte[0] bit 7 is 1, it's negative: raw - 256)
|
||||
```
|
||||
|
||||
## Notes
|
||||
|
||||
<!-- Add any device-specific quirks, power-on sequences, or gotchas here -->
|
||||
Reference in New Issue
Block a user