Line: 1 to 1 | ||||||||
---|---|---|---|---|---|---|---|---|
The driver for BMA423 Triaxial Acceleration Sensor | ||||||||
Changed: | ||||||||
< < | I use the bma423 API from Bosch with Daniel Thomson's upy interface: | |||||||
> > | I found that MicroPython layer in bma423 from https://github.com/OPHoperHPO/lilygo-ttgo-twatch-2020-micropython because it uses deprecated calls to I2C in MicroPython. However, I found that Daniel Thomson has also written a MicroPython interface to the BMA423 API from Bosch SensorTec, which was easier to adapt to the t-watch. | |||||||
https://github.com/daniel-thompson/bma42x-upy | ||||||||
Changed: | ||||||||
< < | The BMA42x driver uses the | |||||||
> > | I had to make only a few modifications: Daniel uses a BMA421 while the t-watch uses a BMA423. I therefore had to replace all occurrences of "bma421" in bma42x.c by "bma423". In addition the t-watch uses the secondary I2C address 0x19 for the chip (the primary address is 0x18) and I therefore had to replace ic2_addr in the device descriptor to BMA4_I2C_ADDR_SECONDARY.
Daniel also supplies a few example programs, which are essentially ports of the Bosch examples ported from C to MicroPython
The BMA42X driver uses the
| |||||||
| ||||||||
Changed: | ||||||||
< < |
| |||||||
> > |
| |||||||
| ||||||||
Line: 26 to 33 | ||||||||
| ||||||||
Added: | ||||||||
> > | The driver also defines the following constants:
The registers:
| |||||||
-- Uli Raich - 2021-01-27 |