PiStorms  4.012
PiStorms Library Reference by mindsensors.com
 All Classes Namespaces Files Functions Variables
MsDevices.AbsoluteIMU Class Reference

AbsoluteIMU: this class provides PiStorms specific interface for all models of the AbsoluteIMU from mindsensors.com for detailed member functions for this class, please refer to mindsensors.ABSIMU. More...

Inheritance diagram for MsDevices.AbsoluteIMU:

Public Member Functions

def __init__
 Initialize the class with the i2c address of your AbsoluteIMU. More...
 
def command
 Writes a value to the command register. More...
 
def get_tiltx
 Reads the tilt value along the x-axis. More...
 
def get_tilty
 Reads the tilt value along the y-axis. More...
 
def get_tiltz
 Reads the tilt value along the z-axis. More...
 
def get_tiltall
 Reads the tilt values. More...
 
def get_accelx
 Reads acceleromter value along the x-axis. More...
 
def get_accely
 Reads acceleromter value along the y-axis. More...
 
def get_accelz
 Reads acceleromter value along the z-axis. More...
 
def get_accelall
 Reads the accelerometer values. More...
 
def get_heading
 Reads compass heading. More...
 
def get_magx
 Reads magnetometer value along the x-axis. More...
 
def get_magy
 Reads magnetometer value along the y-axis. More...
 
def get_magz
 Reads magnetometer value along the z-axis. More...
 
def get_magall
 Reads the magnetometer values. More...
 
def get_gyrox
 Reads gyroscope value along the x-axis. More...
 
def get_gyroy
 Reads gyroscope value along the y-axis. More...
 
def get_gyroz
 Reads gyroscope value along the z-axis. More...
 
def get_gyroall
 Reads the tilt values. More...
 
def start_cmpscal
 Starts the compass calibration process. More...
 
def stop_cmpscal
 Stops the compass calibration process. More...
 
def accel_2G
 Sets accelerometer sensitivity to 2G. More...
 
def accel_4G
 Sets accelerometer sensitivity to 4G. More...
 
def accel_8G
 Sets accelerometer sensitivity to 8G. More...
 
def accel_16G
 Sets accelerometer sensitivity to 16G. More...
 

Static Public Attributes

tuple ABSIMU_ADDRESS = (0x22)
 Default ABSIMU I2C Address.
 
int COMMAND = 0x41
 Command Register.
 
int TILT_X = 0x42
 X-Axis Tilt Register. More...
 
int TILT_Y = 0x43
 Y-Axis Tilt Register. More...
 
int TILT_Z = 0x44
 Z-Axis Tilt Register. More...
 
int ACCEL_X = 0x45
 X-Axis Accelerometer Register. More...
 
int ACCEL_Y = 0x47
 Y-Axis Accelerometer Register. More...
 
int ACCEL_Z = 0x49
 Z-Axis Accelerometer Register. More...
 
int CMPS = 0x4B
 Compass Heading Register. More...
 
int MAG_X = 0x4D
 X-Axis Magnetometer Register. More...
 
int MAG_Y = 0x4F
 Y-Axis Magnetometer Register. More...
 
int MAG_Z = 0x51
 Z-Axis Magnetometer Register. More...
 
int GYRO_X = 0x53
 X-Axis Gyroscope Register. More...
 
int GYRO_Y = 0x55
 Y-Axis Gyroscope Register. More...
 
int GYRO_Z = 0x57
 Z-Axis Gyroscope Register. More...
 

Detailed Description

AbsoluteIMU: this class provides PiStorms specific interface for all models of the AbsoluteIMU from mindsensors.com for detailed member functions for this class, please refer to mindsensors.ABSIMU.

Constructor & Destructor Documentation

def MsDevices.AbsoluteIMU.__init__ (   self,
  port,
  address = ABSIMU_ADDRESS 
)

Initialize the class with the i2c address of your AbsoluteIMU.

Parameters
selfThe object pointer.
portThe PiStorms bank.
addressAddress of your AbsoluteIMU.
Remarks

Member Function Documentation

def MsDevices.AbsoluteIMU.accel_16G (   self)

Sets accelerometer sensitivity to 16G.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.accel_2G (   self)

Sets accelerometer sensitivity to 2G.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.accel_4G (   self)

Sets accelerometer sensitivity to 4G.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.accel_8G (   self)

Sets accelerometer sensitivity to 8G.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.command (   self,
  command 
)

Writes a value to the command register.

Parameters
selfThe object pointer.
commandValue to write to the command register.
def MsDevices.AbsoluteIMU.get_accelall (   self)

Reads the accelerometer values.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.get_accelx (   self)

Reads acceleromter value along the x-axis.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.get_accely (   self)

Reads acceleromter value along the y-axis.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.get_accelz (   self)

Reads acceleromter value along the z-axis.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.get_gyroall (   self)

Reads the tilt values.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.get_gyrox (   self)

Reads gyroscope value along the x-axis.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.get_gyroy (   self)

Reads gyroscope value along the y-axis.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.get_gyroz (   self)

Reads gyroscope value along the z-axis.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.get_heading (   self)

Reads compass heading.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.get_magall (   self)

Reads the magnetometer values.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.get_magx (   self)

Reads magnetometer value along the x-axis.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.get_magy (   self)

Reads magnetometer value along the y-axis.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.get_magz (   self)

Reads magnetometer value along the z-axis.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.get_tiltall (   self)

Reads the tilt values.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.get_tiltx (   self)

Reads the tilt value along the x-axis.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.get_tilty (   self)

Reads the tilt value along the y-axis.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.get_tiltz (   self)

Reads the tilt value along the z-axis.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.start_cmpscal (   self)

Starts the compass calibration process.

Parameters
selfThe object pointer.
def MsDevices.AbsoluteIMU.stop_cmpscal (   self)

Stops the compass calibration process.

Parameters
selfThe object pointer.

Member Data Documentation

int MsDevices.AbsoluteIMU.ACCEL_X = 0x45
static

X-Axis Accelerometer Register.

Will return a signed integer reading (-1050 - 1050)

int MsDevices.AbsoluteIMU.ACCEL_Y = 0x47
static

Y-Axis Accelerometer Register.

Will return a signed integer reading (-1050 - 1050)

int MsDevices.AbsoluteIMU.ACCEL_Z = 0x49
static

Z-Axis Accelerometer Register.

Will return a signed integer reading (-1050 - 1050)

int MsDevices.AbsoluteIMU.CMPS = 0x4B
static

Compass Heading Register.

Will return an unsigned integer reading (0 - 360)

int MsDevices.AbsoluteIMU.GYRO_X = 0x53
static

X-Axis Gyroscope Register.

Will return a signed integer reading

int MsDevices.AbsoluteIMU.GYRO_Y = 0x55
static

Y-Axis Gyroscope Register.

Will return a signed integer reading

int MsDevices.AbsoluteIMU.GYRO_Z = 0x57
static

Z-Axis Gyroscope Register.

Will return a signed integer reading

int MsDevices.AbsoluteIMU.MAG_X = 0x4D
static

X-Axis Magnetometer Register.

Will return a signed integer reading

int MsDevices.AbsoluteIMU.MAG_Y = 0x4F
static

Y-Axis Magnetometer Register.

Will return a signed integer reading

int MsDevices.AbsoluteIMU.MAG_Z = 0x51
static

Z-Axis Magnetometer Register.

Will return a signed integer reading

int MsDevices.AbsoluteIMU.TILT_X = 0x42
static

X-Axis Tilt Register.

Will return a signed integer reading

int MsDevices.AbsoluteIMU.TILT_Y = 0x43
static

Y-Axis Tilt Register.

Will return a signed integer reading

int MsDevices.AbsoluteIMU.TILT_Z = 0x44
static

Z-Axis Tilt Register.

Will return a signed integer reading


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