#include <Wire.h>
#include <bmp085.h>


void setup()
{
  Serial.begin(9600);
  Serial.println("Test af tryk/temp maaler bmp085 paa Arduino CANSAT shield");
  Serial.println("(C) Simon og Jens es.aau.dk");
  Serial.println(" du kan i koden aendre dagens luftryk aht hojde");
  bmp085_init();
}

float temp,atm,alt;
long pres;
 
#define LOOPTIME 200
unsigned long t1,t3;
void loop()
{
 //  bmp085_init();
  temp = bmp085Temp(); 
  pres = bmp085Pressure(); 

  atm = pres / 101325; // "standard atmosphere"
  alt = bmp085PascalToMeter(pres,101325);  
  Serial.print(temp);
  Serial.print(" (C) ");

  Serial.print(pres);
  Serial.print(" ( ");
  Serial.print(atm);
  Serial.print(" , tryk ");

  Serial.println(alt);
  Serial.print( " (m) ");
 
}






