Skip to content
forked from aschulm/battor

BattOr - Power monitor for smartphones and tablets

License

Notifications You must be signed in to change notification settings

direvius/battor

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Table of Contents generated with DocToc

BattOr: Mobile device power monitor

Directory structure

  • sw - PC software for collecting power measurements from the BattOr
  • fw - Atmel XMega192A3 firmware for the BattOr hardware
  • systrace - Fork of Android systrace for visualizing power measurments synced with phone events

Installation

Software

The software should build and run on most variants of Linux. The build and install instructions are as follows:

$ ./bootstrap
$ ./configure
$ make
$ sudo make install

To run BattOr without root on Linux you will need to add your user to the "dialout" group. You need to logout and login for these settings to take effect.

$ sudo usermod -a -G dialout <userName>

Systrace

Dependencies

  • Chrome
  • Android adb

Systrace collects trace data from BattOr and Android and produces an interactive timeline view of the data in html using trace-viewer.

Firmware

Dependencies

The firmware currently only builds on Linux. The BattOr software must be in $PATH to flash the firmware.

$ make
$ make flash

Usage

LED status codes

  • Fast blinking YELLOW: In bootloader
  • Slow blinking YELLOW: Idle
  • Blinking RED: Buffering to SD card
  • Solid RED: Downloading from SD card
  • Blinking GREEN: Streaming over USB

Software

Streaming

To stream samples from the BattOr over USB, run the following on the command line. Often you will want to redirect the output to a file.

$ battor -s

Buffering

To start buffering power measurements, run the following on the command line. Once the BattOr has a blinking RED LED, it can be disconnected from USB so power can be measured while on the move.

$ battor -b

To end buffering and download the trace, run the following on the command line. Often you will want to redirect the output to a file. The BattOr will have a solid RED LED until the download is completed. Note that currently downloading buffered power measurements takes approximately 1/4 of time that the samples were buffered.

$ battor -d

About

BattOr - Power monitor for smartphones and tablets

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • HTML 85.7%
  • C 10.1%
  • Shell 2.7%
  • Python 1.1%
  • Makefile 0.2%
  • C++ 0.1%
  • Other 0.1%