whatever

Dependencies:   C027 C027_Support M2XStreamClient PowerControl jsonlite mbed-rtos mbed

Fork of PONY_Ph0-uAXIS by Sean McBeath

PONY_sense.h

Committer:
sgmcb
Date:
2016-01-20
Revision:
54:6ce53a145fa0
Parent:
51:61a1ec3c56fc

File content as of revision 54:6ce53a145fa0:

/*

PONY_sense.h
(C) 2015 Igor Institute

*/
#include "mbed.h"
#include <math.h>
#include "M2XStreamClient.h"

// Sensor pin definitions
#define AINTOV(c) 3.3*c // Our A2D has a default reference voltage of 3.3V




// Define a structure to hold temperature tuples
struct tempstamp {
    float temp;
    //struct tm stamp;
} ;

float thermistorToTemp(float thermVoltage);
float getTemp(AnalogIn*);
int logTemp(AnalogIn*, float*, M2XStreamClient*);

float getWeight(AnalogIn*);


void LIS331write(I2C*, int, int);
int LIS331read(I2C*, const int, int*);
int LIS331read(I2C*, const int);




int configureAccel(I2C*);
int accelWhoAmI (I2C*);


int accelX (I2C*);
int accelY (I2C*);
int accelZ (I2C*);