Skip to content

Commit

Permalink
Add get_version (#258)
Browse files Browse the repository at this point in the history
  • Loading branch information
npentrel authored Aug 4, 2024
1 parent 6a34ff7 commit eec81ad
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 0 deletions.
20 changes: 20 additions & 0 deletions docs/tildagon-apps/reference/badge-hardware.md
Original file line number Diff line number Diff line change
Expand Up @@ -743,3 +743,23 @@ i2c.writeto_mem(42, 2, b'\x10')
```

For more information, see [MicroPython I2C docs](https://docs.micropython.org/en/latest/library/machine.I2C.html).

## Version

You can use the `ota` package to obtain the insntalled TildagonOS version:

### Usage

To use the buttons:

1. Import the `ota` package:

```python
import ota
```

2. Use the `get_version()` method:

```python
ota.get_version()
```
1 change: 1 addition & 0 deletions docs/tildagon-apps/reference/reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ You can use the following hardware with the inbuilt interfaces:
- [Pins](./badge-hardware.md#pins)
- [IMU](./badge-hardware.md#imu)
- [Power](./badge-hardware.md#power)
- [Version](./badge-hardware.md#over-the-air-ota)

## Using APIs

Expand Down

0 comments on commit eec81ad

Please sign in to comment.