Giter Site home page Giter Site logo

py-adxl345's People

Contributors

alexismeneses avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

py-adxl345's Issues

[Feature request] - Tap

Hello Alexis,
i'd like to get working singletap, doubletap and freefall which adxl345 provide as HW features, so i forked your project and looked an old lib [0] trying to re-create the functions used for tapping.
Unlucky i'm a self teached programmer so i was only able to add Pitch&Roll [1] to your code, whilst it get hard to me play with hex address and bitwise operations. After many tries i feel to be close to the solution but it still doesn't work.

Can you please give me an hand and try to add Tap in your code?
Thank you :)

[0] http://think-bowl.com/raspberry-pi/i2c-python-library-3-axis-digital-accelerometer-adxl345-with-the-raspberry-pi/
[1] http://theccontinuum.com/2012/09/24/arduino-imu-pitch-roll-from-accelerometer/

Typo in base.py line 285

base.py >

at line 285:
self.set_offset(offset_x, offest_y, offset_z)

must be:
self.set_offset(offset_x, offset_y, offset_z)

Otherwise

"offest_y" is not defined

Wrong code part in spi.py

spi.py >

at line 30
self.spi.writebytes( [ address & 0x3F ] | READ_MASK | MULTIREAD_MASK )
must be
self.spi.writebytes( [ address & 0x3F | READ_MASK | MULTIREAD_MASK ])

otherwise it raises TypeError

TypeError: unsupported operand type(s) for |: 'list' and 'int'

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.