Public Types | Public Member Functions | Protected Member Functions | Protected Attributes
BMA180Parameters Class Reference

#include <bma180_parameters.hpp>

Inheritance diagram for BMA180Parameters:
Inheritance graph
[legend]

List of all members.

Public Types

enum  accel_range {
  RANGE_1 = 0x00, RANGE_1_5 = 0x01, RANGE_2 = 0x02, RANGE_3 = 0x03,
  RANGE_4 = 0x04, RANGE_8 = 0x05, RANGE_16 = 0x06
}
 Write these to <3:1> in ADDRESS_RANGE_REG to change sensitivity. More...
enum  bandwidth {
  BW_10, BW_20, BW_40, BW_75,
  BW_150, BW_300, BW_600, BW_1200,
  BW_HIGH_PASS, BW_BAND_PASS
}
 Write these to <7:4> in ADDRESS_BWTCS to change bandwidth filter. More...

Public Member Functions

 BMA180Parameters ()
int * getFlags ()
int getFrequency ()
int getPin ()
interface_protocol getProtocol ()
double getSensitivity ()
uint8_t getSlaveAddressBit ()
bool setAccelRange (accel_range new_range)
 Set the sensing range. See accel_range.
void setBandwidth (bandwidth bw)
 Set the internal filter on the sensor to the specified bandwidth.
bool setFrequency (int frequency)
bool setPin (uint8_t pin)
void setPreCalOffsets (bool choice)
bool setProtocol (interface_protocol protocol)
bool setSlaveAddressBit (bool choice)
 Set the driver to the correct device address of the sensor.
 ~BMA180Parameters ()

Protected Member Functions

bool setByteOrder (uint8_t value)
 Adjust the byte is the order of the transmission.
bool setSpiMode (uint8_t mode)
 Set the SPI mode (0 -- 4).

Protected Attributes

accel_range accel_range_
bandwidth bandwidth_
bool offsetsEnabled_
double sensitivity_
uint8_t slave_address_bit_
bool useFilter_

Detailed Description

Definition at line 62 of file bma180_parameters.hpp.


Member Enumeration Documentation

Write these to <3:1> in ADDRESS_RANGE_REG to change sensitivity.

Enumerator:
RANGE_1 
Note:
±1 [g] at 0.13 [mg/LSB]
RANGE_1_5 
Note:
±1.5 [g] at 0.19 [mg/LSB]
RANGE_2 
Note:
±2 [g] at 0.25 [mg/LSB]
RANGE_3 
Note:
±3 [g] at 0.38 [mg/LSB]
RANGE_4 
Note:
±4 [g] at 0.50 [mg/LSB]
RANGE_8 
Note:
±8 [g] at 0.99 [mg/LSB]
RANGE_16 
Note:
±16 [g] at 1.98 [mg/LSB]

Definition at line 69 of file bma180_parameters.hpp.

Write these to <7:4> in ADDRESS_BWTCS to change bandwidth filter.

Enumerator:
BW_10 
BW_20 
BW_40 
BW_75 
BW_150 
BW_300 
BW_600 
BW_1200 
BW_HIGH_PASS 
BW_BAND_PASS 

Definition at line 90 of file bma180_parameters.hpp.


Constructor & Destructor Documentation

Warning:
flags_ MUST be cleared BEFORE changing any SPI settings!

Definition at line 55 of file bma180_parameters.cpp.

Definition at line 75 of file bma180_parameters.cpp.


Member Function Documentation

int * BMA180Parameters::getFlags ( ) [virtual]

Implements bosch_drivers_common::Parameters.

Definition at line 148 of file bma180_parameters.cpp.

int BMA180Parameters::getFrequency ( ) [virtual]

Implements bosch_drivers_common::Parameters.

Definition at line 119 of file bma180_parameters.cpp.

int BMA180Parameters::getPin ( ) [virtual]

Implements bosch_drivers_common::Parameters.

Definition at line 140 of file bma180_parameters.cpp.

Implements bosch_drivers_common::Parameters.

Definition at line 111 of file bma180_parameters.cpp.

Definition at line 259 of file bma180_parameters.cpp.

Definition at line 165 of file bma180_parameters.cpp.

Set the sensing range. See accel_range.

Definition at line 210 of file bma180_parameters.cpp.

Set the internal filter on the sensor to the specified bandwidth.

Definition at line 251 of file bma180_parameters.cpp.

bool BMA180Parameters::setByteOrder ( uint8_t  value) [protected]

Adjust the byte is the order of the transmission.

Definition at line 173 of file bma180_parameters.cpp.

bool BMA180Parameters::setFrequency ( int  frequency) [virtual]

Implements bosch_drivers_common::Parameters.

Definition at line 102 of file bma180_parameters.cpp.

bool BMA180Parameters::setPin ( uint8_t  pin) [virtual]

Implements bosch_drivers_common::Parameters.

Definition at line 127 of file bma180_parameters.cpp.

void BMA180Parameters::setPreCalOffsets ( bool  choice)

Definition at line 267 of file bma180_parameters.cpp.

Definition at line 82 of file bma180_parameters.cpp.

bool BMA180Parameters::setSlaveAddressBit ( bool  choice)

Set the driver to the correct device address of the sensor.

Definition at line 156 of file bma180_parameters.cpp.

bool BMA180Parameters::setSpiMode ( uint8_t  mode) [protected]

Set the SPI mode (0 -- 4).

Definition at line 189 of file bma180_parameters.cpp.


Member Data Documentation

Definition at line 151 of file bma180_parameters.hpp.

Definition at line 152 of file bma180_parameters.hpp.

Definition at line 154 of file bma180_parameters.hpp.

double BMA180Parameters::sensitivity_ [protected]

Definition at line 150 of file bma180_parameters.hpp.

Definition at line 149 of file bma180_parameters.hpp.

bool BMA180Parameters::useFilter_ [protected]

Definition at line 153 of file bma180_parameters.hpp.


The documentation for this class was generated from the following files:


bma180_driver
Author(s): Joshua Vasquez, Philip Roan. Maintained by Philip Roan
autogenerated on Sat Dec 28 2013 16:49:14