Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

Parallax P8X32A/Propeller, P2X8C4M64P/Propeller 2 driver object for the ST LIS3DH 3DoF Accelerometer

License

NotificationsYou must be signed in to change notification settings

avsa242/lis3dh-spin

Repository files navigation


This is a P8X32A/Propeller, P2X8C4M64P/Propeller 2 driver object for the ST LIS3DH 3DoF accelerometer

IMPORTANT: This software is meant to be used with thespin-standard-library (P8X32A) orp2-spin-standard-library (P2X8C4M64P). Please install the applicable library first before attempting to use this code, otherwise you will be missing several files required to build the project.

Salient Features

  • I2C connection at up to 400kHz (P1, P2)
  • SPI connection (3w, 4w) at ~4MHz (P1), up to 5MHz (P2)
  • Read raw or scaled accelerometer data output
  • Set output data rate
  • Set full-scale range
  • Enable per-axis output
  • Flags to indicate data is ready, or has overrun
  • Set calibration offsets
  • FIFO control and flag reading (empty, full, number of unread samples)
  • Set interrupt sources by mask, set threshold level, read interrupt flags
  • Single and double-click detection
  • Free-fall detection

Requirements

P1/SPIN1:

  • spin-standard-library
  • 1 extra core/cog for the PASM I2C or SPI engine (none, if bytecode engine is used)
  • sensor.accel.common.spinh (provided by spin-standard-library)

P2/SPIN2:

  • p2-spin-standard-library
  • sensor.accel.common.spin2h (provided by p2-spin-standard-library)

Compiler Compatibility

ProcessorLanguageCompilerBackendStatus
P1SPIN1FlexSpin (6.9.4)BytecodeOK
P1SPIN1FlexSpin (6.9.4)Native/PASMOK
P2SPIN2FlexSpin (6.9.4)NuCodeSome runtime issues
P2SPIN2FlexSpin (6.9.4)Native/PASM2OK

(other versions or toolchains not listed arenot supported, andmay or may not work)

Limitations

  • TBD

About

Parallax P8X32A/Propeller, P2X8C4M64P/Propeller 2 driver object for the ST LIS3DH 3DoF Accelerometer

Topics

Resources

License

Stars

Watchers

Forks


[8]ページ先頭

©2009-2025 Movatter.jp