core/accelerometer/accelero.h File Reference

Go to the source code of this file.

Defines

#define ACCELEROMETER_OFF   0
#define ACCELEROMETER_ON   1

Functions

void accelero_init (int adc_clock)
void accelero_sleep (int sleep)
float accelero_read_one (int channel)
int accelero_read (float *p_dst)

Detailed Description

Low level accelerometer driver interface.

Definition in file accelero.h.


Function Documentation

void accelero_init ( int  adc_clock  ) 

Initialize the accelerometer.

Parameters:
adc_clock Clock frequency of the A/D converter.

Definition at line 38 of file accelero.c.

int accelero_read ( float *  p_dst  ) 

Read all channels of the accelerometer.

Parameters:
p_dst Address to write the accelerometer data to.
Returns:
The number of bytes written.

Definition at line 90 of file accelero.c.

float accelero_read_one ( int  channel  ) 

Read one channel of the accelerometer.

Parameters:
channel Accelerometer channel to read.
Returns:
The value of the accelerometer channel.

Definition at line 70 of file accelero.c.

void accelero_sleep ( int  sleep  ) 

Control the accelerometer's sleep mode.

Parameters:
sleep ACCELEROMETER_OFF or ACCELEROMETER_ON

Definition at line 57 of file accelero.c.

 All Data Structures Files Functions Variables Typedefs Enumerations Defines

Generated by  doxygen 1.6.2