PropWare
3.0.0.229
C++ objects and CMake build system for Parallax Propeller
|
#include <PropWare/serial/spi/spi.h>
Go to the source code of this file.
Namespaces | |
PropWare | |
Generic definitions and functions for the Parallax Propeller. | |
Definition in file adxl345.h.
union PropWare::ADXL345::ActivityDetection |
Bit-mapping for Register::ACT_INACT_CTL.
Class Members | ||
---|---|---|
struct ActivityDetection | fields | |
uint8_t | raw |
union PropWare::ADXL345::TapAxes |
Bit-mapping for Register::TAP_AXES.
Class Members | ||
---|---|---|
struct TapAxes | fields | |
uint8_t | raw |
union PropWare::ADXL345::TapSource |
Bit-mapping for Register::TAP_SOURCE.
Class Members | ||
---|---|---|
struct TapSource | fields | |
uint8_t | raw |
union PropWare::ADXL345::RateAndPowerMode |
Bit-mapping for Register::RATE_AND_POWER_MODE.
Class Members | ||
---|---|---|
struct RateAndPowerMode | fields | |
uint8_t | raw |
union PropWare::ADXL345::PowerControl |
Class Members | ||
---|---|---|
struct PowerControl | fields | |
uint8_t | raw |
union PropWare::ADXL345::InterruptEnable |
Bit-mapping for Register::INTERRUPT_ENABLE.
Class Members | ||
---|---|---|
struct InterruptEnable | fields | |
uint8_t | raw |
union PropWare::ADXL345::InterruptMapping |
Bit-mapping for Register::INTERRUPT_MAPPING.
Class Members | ||
---|---|---|
struct InterruptMapping | fields | |
uint8_t | raw |
union PropWare::ADXL345::InterruptSources |
Bit-mapping for Register::INTERRUPT_SOURCES.
Class Members | ||
---|---|---|
struct InterruptSources | fields | |
uint8_t | raw |
union PropWare::ADXL345::DataFormat |
Bit-mapping for Register::DATA_FORMAT.
Class Members | ||
---|---|---|
struct DataFormat | fields | |
uint8_t | raw |
union PropWare::ADXL345::FIFOControl |
Bit-mapping for Register::FIFO_CONTROL.
Class Members | ||
---|---|---|
struct FIFOControl | fields | |
uint8_t | raw |
union PropWare::ADXL345::FIFOStatus |
Bit-mapping for Register::FIFO_STATUS.
Class Members | ||
---|---|---|
struct FIFOStatus | fields | |
uint8_t | raw |
struct PropWare::ADXL345::ActivityDetection.fields |
struct PropWare::ADXL345::DataFormat.fields |
Class Members | ||
---|---|---|
unsigned int | fullResolution: 1 |
When set high, the resolution will always be 4 mg/LSB no matter the range. When set low, the resolution will change with the range and the data will remain 10 bits wide. |
unsigned int | invertedInterrupts: 1 |
When set high, interrupts will be active high instead of active low. |
unsigned int | justify: 1 |
When set high, data will be left (MSB) justified. When cleared low, it will be right justified and sign extended. |
Range | range: 2 |
Data range of the device |
unsigned int | selfTest |
Setting high will enable self-test mode, causing a shift in the output data. Cleared low for normal operation. |
unsigned int | spiMode |
When set high, the device will work in 3-wire SPI mode. Cleared low for 4-wire SPI mode. |
struct PropWare::ADXL345::FIFOControl.fields |
Class Members | ||
---|---|---|
FIFOMode | fifoMode: 2 |
Set the mode that the FIFO will assume. |
unsigned int | samples: 5 |
The function of these bits depends on the FIFO mode selected via FIFOContro::fifoMode. Entering a value of 0 in the samples bits immediately sets the watermark status bit in Register::INTERRUPT_SOURCE, regardless of which FIFO mode is selected. Undesirable operation may occur if a value of 0 is used for the samples bits when trigger mode is used. |
unsigned int | trigger: 1 |
Clear low to link the trigger event of trigger mode to INT1, and set high to link the trigger event to INT2. |
struct PropWare::ADXL345::FIFOStatus.fields |
struct PropWare::ADXL345::InterruptEnable.fields |
struct PropWare::ADXL345::InterruptMapping.fields |
struct PropWare::ADXL345::InterruptSources.fields |
struct PropWare::ADXL345::PowerControl.fields |
Class Members | ||
---|---|---|
unsigned int | autoSleep: 1 |
When set high, the device will automatically enter a low-power sleep mode any time the sampled activity dips below the threshold configured via Register::INACTIVITY_THRESHOLD for at least the amount of time configured via Register::INACTIVITY_TIME. Clearing the bit low will disable automatic sleep mode. When clearing the AUTO_SLEEP bit, it is recommended that the part be placed into standby mode and then set back to measurement mode with a subsequent write. This is done to ensure that the device is properly biased if sleep mode is manually disabled; otherwise, the first few samples of data after the AUTO_SLEEP bit is cleared may have additional noise, especially if the device was asleep when the bit was cleared. |
unsigned int | link: 1 |
Set high to enable linked mode and clear low for concurrent functionality of inactivity and activity functions. See the datasheet for a far more verbose explanation. |
unsigned int | measure: 1 |
Set high for normal operation and low for standby mode. When in standby mode, power consumption is at a minimum but now measurements can be made. The device is booted in standby mode. |
unsigned int | sleep: 1 |
When set high, the device will be put into sleep mode. Low for normal operation. While in sleep mode, the device's sample rate is set by PowerControl::wakeup. When clearing the sleep bit, it is recommended that the part be placed into standby mode and then set back to measurement mode with a subsequent write. This is done to ensure that the device is properly biased if sleep mode is manually disabled; otherwise, the first few samples of data after the sleep bit is cleared may have additional noise, especially if the device was asleep when the bit was cleared |
WakeupFrequency | wakeup: 2 |
Frequency of reading when in sleep mode |
struct PropWare::ADXL345::RateAndPowerMode.fields |
struct PropWare::ADXL345::TapAxes.fields |
Class Members | ||
---|---|---|
unsigned int | suppress: 1 |
When set high, suppress double-tap detection for too high of an acceleration (as set per Register::TAP_THRESHOLD) |
unsigned int | tapXEnable: 1 |
Enable x-axis participation in tap detection |
unsigned int | tapYEnable: 1 |
Enable y-axis participation in tap detection |
unsigned int | tapZEnable: 1 |
Enable z-axis participation in tap detection |
struct PropWare::ADXL345::TapSource.fields |