Sensor Analyzer

To see more JOM Software applications, click here.


sensor_analyzer_v2_0_0.sis v2.0 (black UI, SIS file) v1.2 (white UI, source code only)

Sensor Analyzer

Sensor Analyzer is a little tool to experiment how built-in sensors work in your device. You can see in real-time how your beloved phone reacts to shakes, tilts, rotation and changes in position.


Download: sensor_analyzer_v2_0_0.sis for PyS60 1.4.5 to be used on  any Nokia non-touch UI device. This application uses Sensor API, which exists only in Nokia N95, N82, N93i and 5500 devices.

Make sure you install this on same disk as PyS60 runtime. I used memory card, no problems.

NOTE: this application does NOT work with Sensor Framework. Version which supports Sensor Framework and Touch UI will be released after PyS60 1.9.7.

Main Features

  • Show sensor events as real-time bars, vectors or graph line
  • Control each sensor channel separately (ON/OFF)
  • Zoom in and out
  • Key shortcuts
    • Key Zero: reset all data
    • Key 1: toggle X channel on/off
    • Key 2: toggle Y channel on/off
    • Key 3: toggle Z channel on/off
    • Key Star: zoom out
    • Key Hash: zoom in
    • Arrow up/down: zoom out/in
    • Arrow left/right: change view (bar/vector/graph)
    • Select key: reset all data

Version History

Version 2.00, release date 2009-11-27
  • New: UI Look & Feel white -> black
  • Fix: Dynamic screen size
  • Fix: Screensaver disabled while app running
  • Fix: Zooming now works
  • Fix: All operations via Options menu
Version 1.20
, release date 2008-05-12
  • Sensor data visualization with vectors and moving dot graph
  • Possibility to change zoom level (1 - 10)
  • Switch views with left and right arrow.
Version 1.10, release date 2008-05-08
  • Visualize raw sensor data.
  • Bars idea based on Aapo Rista modified
Version 1.00, release date 2008-05-07
  • Based on Sensor Sample
  • Debug code to see raw sensor data
  • Tested with pyS60 1.4.3 in N82.

Sample Code (1.2)

  • Quick and dirty tool to figure out raw Sensor API data.
  • Debug code is included, but beware: it generates a HUGE file on your phone. By default debugging is turned off.
  • How to do tab views without using tabs.
  • How to scale data.
  • How to create scrolling dotted graph.

Sensor Analyzer

Can be used to see what kind of raw data values Sensor API gives, when you move, turn and shake the device.

First bar is data_1 (RED), second bar is data_2 (GREEN) and third bar is data_3 (BLUE). At top you see max value for each data and at bottom min value. Bottom row shows current value for each.

You can reset the recorded max/min limits by pressing zero number key at any time.

Uses cases:

  • Try to document Sensor API
  • Experiment with movement related algorithms
  • Search for limits

Usage - Keyboard shortcuts:

1 - Toggle data channel 1 on/off
2 - Toggle data channel 2 on/off
3 - Toggle data channel 3 on/off
0 - Reset collected data, start again
* - Zoom more
# - Zoom less
Right Arrow - Switch view Bars->Vector->Graph
Left Arrow - Switch view Graph->Vector->Bars
9 - Save screen snapshot on disk (debug mode only)

Initial Analysis

Sensor API callback receives following data (sample):

{'data_3': -287, 'data_2': -10, 'data_1': -31, 'sensor_id': 271003684}

  • Bar 1 presents data_1: Phone is standing vertically on table, red bar goes down (negative data_1 values). Turn upsidedown, red bar goes up (positive data_1 values). Values are close to zero, when device is lying on it's side or on it's back.
  • Bar 2 presents data_2: Phone is lying horizontally sideways on table on right side, green bar goes down (negative data_2 values). Turn on left side, green bar goes up (positive data_2 values). Values are close to zero, when device is standing vertically or lying on it's back.
  • Bar 3 presents data_3: Phone is lying horizontally on back on table, blue bar goes down (negative data_3 values). Turn face downwards, blue bar goes up (positive data_3 values). Values are close to zero, when device is standing vertically or lying on it's side.
  • Earth gravity seems to be about +/- 300.
  • Static gravity "background noice" seems to be about +/- 5.
  • Managed to wave the device for "1200", so values might be linear data (4G force could be within my human waving capability limits). Afterwards somehow introduced a BUG which limits max values at 680!