https://github.com/sameer/bq24195-i2c
I2C driver for Texas Instruments BQ24195 Single Cell Charger
https://github.com/sameer/bq24195-i2c
bq24195 charger embedded i2c power rust texas-instruments
Last synced: 6 months ago
JSON representation
I2C driver for Texas Instruments BQ24195 Single Cell Charger
- Host: GitHub
- URL: https://github.com/sameer/bq24195-i2c
- Owner: sameer
- License: other
- Created: 2020-03-30T04:19:56.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2020-04-04T14:51:18.000Z (over 5 years ago)
- Last Synced: 2025-04-02T11:54:18.950Z (6 months ago)
- Topics: bq24195, charger, embedded, i2c, power, rust, texas-instruments
- Language: Rust
- Size: 24.4 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE-APACHE
Awesome Lists containing this project
README
# BQ24195 i2c driver
[](https://crates.io/crates/bq24195-i2c)
[](https://docs.rs/bq24195-i2c)
The documentation for this library should cover everything you need to know about the chip and its i2c registers.
## Usage
A usage example is given in the `examples` folder.
### Requirements
* Embedded Hardware Abstraction Layer support crate for your device (i.e. atsamd for SAM family devices)
* A bq24195 chip connected over I2C### Building and Flashing
#### Arduino MKR Vidor 4000
This should also work on other SAMD21 boards.
```bash
RUSTFLAGS='-C link-arg=-Tlink.x' cargo build --release --target thumbv6m-none-eabi --example arduino_mkrvidor4000
arm-none-eabi-objcopy -O binary target/thumbv6m-none-eabi/release/usbblaster-rs target/usbblaster-rs.bin
# Manual step: push reset button twice in quick succession to enter flash mode
bossac -i -d -U true -i -e -w -v target/usbblaster-rs.bin -R
```## Reference documents
* [BQ24195 Datasheet](https://www.ti.com/lit/ds/symlink/bq24195l.pdf)