Why am I running out of power so quickly?

I am running out of power very rapidly (within 20 minutes). This code barely uses the LEDs yet the power consumption is incredible. Any ideas?

I am using an Arduino Pro Mini 3.3v with an ATMEGA 328.
I am using these batteries: http://www.coolcomponents.co.uk/catalog/lithium-polymer-battery-110mah-p-778.html

// Limpet Tracker

//include generic libraries
#include <Wire.h>
// Include the Love Electronics HMC5883L library so we can use the accelerometer.
#include <HMC5883L.h>
 
//Talk to card
#include <SdFat.h>
#include <SdFatUtil.h>  // define FreeRam()
   
  //Define stuff
  #define ECHO_TO_SERIAL 1   // 1=echo is on, 0=echo is off
  #define CHIP_SELECT 10  // SD chip select pin
  #define LOG_INTERVAL 250   // mills between entries
  #define WAIT_TO_START 0     // Wait for serial input in setup()
  
  #define DEVICE (0x53) // Device address as specified in data sheet 
  
  byte _buff[6];
  
  char POWER_CTL = 0x2D;	//Power Control Register
  char DATA_FORMAT = 0x31;
  char DATAX0 = 0x32;	//X-Axis Data 0
  char DATAX1 = 0x33;	//X-Axis Data 1
  char DATAY0 = 0x34;	//Y-Axis Data 0
  char DATAY1 = 0x35;	//Y-Axis Data 1
  char DATAZ0 = 0x36;	//Z-Axis Data 0
  char DATAZ1 = 0x37;	//Z-Axis Data 1
  
  //COMPASS
  HMC5883L compass;
   
  // Set up a pin to indicate our status.
  int statusPin = 8; 
  int errorPin = 6;
  int areConnected = 0;
  int error;
  int flash = 0;
  // cs pin
  const int chipSelect = 10;
   
  // file system object
  SdFat sd;
  SdFile file;
   
  // text file for logging
  ofstream logfile;
   
  // Serial print stream
  ArduinoOutStream cout(Serial);
   
  // buffer to format data - makes it eaiser to echo to Serial
  char buf[120];
   
  //------------------------------------------------------------------------------
  // store error strings in flash to save RAM
  #define error(s) sd.errorHalt_P(PSTR(s))
  //------------------------------------------------------------------------------
   
void setup() {
  Serial.begin(9600);
   // Start the I2C Wire library so we can use I2C to talk to the accelerometer.
  Wire.begin();

  pinMode(statusPin, OUTPUT);
  pinMode(errorPin, OUTPUT);

  pinMode(chipSelect, OUTPUT);
 
  for(int i = 30; i >= 0; i--) {
  digitalWrite(statusPin, HIGH);  
  delay(10);
  digitalWrite(statusPin, LOW);  
  delay(3000);
  Serial.println(i);  
 }
  // pstr stores strings in flash to save RAM
  cout << endl << pstr("FreeRam: ") << FreeRam() << endl;
 
  // initialize the SD card at SPI_HALF_SPEED to avoid bus errors with
  // breadboards.  use SPI_FULL_SPEED for better performance.
  // if SD chip select is not SS, the second argument to init is CS pin number
  sd.init(SPI_HALF_SPEED, 10);
  if (!sd.init(SPI_HALF_SPEED, 10)) {
   Serial.println("ooops!"); 
   digitalWrite(errorPin, HIGH);
   digitalWrite(statusPin, LOW);     
   sd.initErrorHalt();   
  }
   
  int namenum1;
  int namenum2;
  
    char name[] = "LOGGER00.CSV";
   
    for (uint8_t i = 0; i < 100; i++) {
      namenum1 = i/10;
      namenum2 = i%10;
      name[6] = i/10 + '0';
      name[7] = i%10 + '0';
 
    if (sd.exists(name)) continue;
    logfile.open(name);
    break;
  }
  digitalWrite(statusPin, HIGH);  
  if (!logfile.is_open()){
  digitalWrite(errorPin, HIGH);
  digitalWrite(statusPin, LOW);    
  error("file.open");
  }
 
  cout << pstr("Logging to: ") << name << endl;
 
  // format header in buffer
  obufstream bout(buf, sizeof(buf));
 
  bout << pstr("Mag: x-scaled, y-scaled, z-scaled Acc: x-scaled, y-scaled, z-scaled");
  logfile << buf << endl;
 
  #if ECHO_TO_SERIAL
    cout << buf << endl;
  #endif  // ECHO_TO_SERIAL
 
  //Create sensor components
  Serial.println(F("Constructing new HMC5883L"));
  compass = HMC5883L();
  
  Serial.println(F("Constructing new ADXL345"));
  //Put the ADXL345 into +/- 4G range by writing the value 0x01 to the DATA_FORMAT register.
  Serial.println(F("Setting Accelerometer scale to +/- 2G"));
  writeTo(DATA_FORMAT, 0x00);
  //Put the ADXL345 into Measurement Mode by writing 0x08 to the POWER_CTL register.
  writeTo(POWER_CTL, 0x08);
  
  //Mag setup
  Serial.println(F("Setting Magnetometer scale to +/- 1.3 Ga"));
  error = compass.SetScale(1.3);
  if(error != 0)
    Serial.println(compass.GetErrorText(error));
    digitalWrite(statusPin, LOW);
  
  Serial.println(F("Setting measurement mode to continous."));
  error = compass.SetMeasurementMode(Measurement_Continuous);
  if(error != 0){
    Serial.println(compass.GetErrorText(error));
    digitalWrite(statusPin, LOW);
    }
}
 
 
void loop() {
  obufstream bout(buf, sizeof(buf));
  
  MagnetometerRaw magRaw = compass.ReadRawAxis();
  MagnetometerScaled magScl = compass.ReadScaledAxis();
  
  int MilliGauss_OnThe_XAxis = magScl.XAxis;

  // Calculate heading when the magnetometer is level, then correct for signs of axis.
  float heading = atan2(magScl.YAxis, magScl.XAxis);

  uint8_t howManyBytesToRead = 6;
  readFrom( DATAX0, howManyBytesToRead, _buff);

  int x = (((int)_buff[1]) << 8) | _buff[0];  
  int y = (((int)_buff[3]) << 8) | _buff[2];
  int z = (((int)_buff[5]) << 8) | _buff[4];
  
  //Taken from Love Electronics ADXL345 Library, this value scales to +/- 2G 
  float sclAccX =(x * 0.0039);
  float  sclAccY =(y * 0.0039);
  float sclAccZ =(z * 0.0039);
  
  //Axis are swapped and inverted to account for physical orientation of the Accelerometer and Magnetometer chips
  float invAccX = -sclAccY;
  float invAccY = -sclAccX;
  
  if(flash <120) {
    bout << flash << ", " << magScl.XAxis << ", " << magScl.YAxis << ", " << magScl.ZAxis << ", " << invAccX << ", " << invAccY << ", " << sclAccZ << endl;
    logfile << buf << flush;
    flash++;
    
  }else{
      digitalWrite(errorPin, HIGH);
      bout << flash << ", " << magScl.XAxis << ", " << magScl.YAxis << ", " << magScl.ZAxis << ", " << invAccX << ", " << invAccY << ", " << sclAccZ << endl;
      logfile << buf << flush;
      digitalWrite(errorPin, LOW);
      flash = 1;
  }
  
  if (!logfile) {
    digitalWrite(errorPin, HIGH);
    error("write data failed");
  }
  
  delay(LOG_INTERVAL); 

  
  #if ECHO_TO_SERIAL
  cout << buf;
  #endif
 }
  
  
 void writeTo(byte address, byte val) {
  Wire.beginTransmission(DEVICE); 
  Wire.send(address);
  Wire.send(val);
  Wire.endTransmission();
 }
  
 void readFrom(byte address, int num, byte _buff[]) {
  Wire.beginTransmission(DEVICE);
  Wire.send(address);
  Wire.endTransmission();

  Wire.beginTransmission(DEVICE);
  Wire.requestFrom(DEVICE, num);

  int i = 0;
  while(Wire.available())
  { 
    _buff[i] = Wire.receive();
    i++;
  }
  Wire.endTransmission();
 }

Those potato batteries are useless :)

...R

Updated thread with component and battery info.

You need more power. I guess you can't use a non-battery supply. Whats your system doing?

You are using a very small battery but presumably you had worked out that it should have been enough - it may be useful to see your assumptions.

Have you measured the current drawn by the Arduino, and how many mAh are actually used before the system stops?

...R