Dienstag, 28. Juni 2011

UpDownMeter: how does it work?

Someone recently asked me a how a specific feature of UpDownMeter works and I realized that I so far did not provide any documentation at all (which, of course, is a bad thing). So here we go. (BTW: it does not matter if you use the free or pro version. Besides widgets and ads they are essentially the same app.)

The app consists of two components. A user interface and a measuring service. This enables the app to continually measure the in- and outgoing traffic, even if the user interface is not displayed. The service component starts to measure traffic as soon after your phone is switched on by default. This behaviour can be altered though (see comments on preferences below).

The measuring of traffic works like this:
  1. get amount of traffic of currently active network device (i.e. mobile/wifi) since it was last activated
  2. if this is not the first measurement
    • calculate the difference between the last measurement and this one
    • store the difference
    • if any notifications (or widgets in the pro version) are active calculate the throughput per second and update the respective notifications

Which means that frequent measuring is only needed if any notifications or widgets are enabled. That is why there are two intervals that can be set in the preferences (see comments on preferences and additional notes below).

User Interface
The user interface is pretty straight forward (I hope):

The tabs let you switch between the traffic statistics of the different network devices and applications respectively. In the Mobile and WiFi tabs you'll see the amount of traffic (caused by apps and the system) that went over the respective network interface. If you press and hold of the interval items (today, this month, total) you'll get a context menu that allows you to set or clear an alarm or clear the traffic related to the respective interval.

The update button will instantly carry out a measurement (see above) and update the user interface to display the updated traffic data.

A note on units: UpDownMeter uses binary prefix units. If you want to be able to switch between binary and decimal units (e.g. kibibyte/kilobyte) let me know and I'll consider adding it as a feature.

The Apps tab will show the the amount of traffic caused by individual apps (if supported), regardless of the utilized network interface.

The preferences can be accessed by pressing the menu button of your android device while in the main user interface.

Autostart: If activated the measuring service (see above) will start measuring automatically after you switched on your android device.

Run service in foreground: The android system kills services when it is low on memory. If you enable this, the measuring service will more likely survive.

Incoming, Outgoing, In/Out Notifications: Enable or disable the notifications you (don't) want to be displayed.

Notification/Widget update interval: If any notifications are enabled or widgets are active this will specify how often traffic will be measured (interval in seconds)

Measuring interval: If no notifications are enabled and no widgets are active this will specify how often traffic will be measured (interval in minutes)

First day of month: If your plan starts new months on a different day than the first you can specify this here.

The rest should be self explanatory.

Additional notes
About the measuring interval: Should you set the measuring interval higher because of battery consumption? No. The battery usage of the measuring task is very low and setting a high measuring interval bears the following risk: If you deactivate the network device in between two measurements, all traffic since the last measurement will be lost. This of course is irrelevant as long as you have at least one notification/widget enabled.

Keine Kommentare:

Kommentar veröffentlichen