Sensor Simulator
Took a sidestep here. I decided to investigate using the sensor capabilities of the Android. This is a native functionality that I potentially could store the data into a Drupal “warehouse” capability.
- SensorSimulator describes the functions of the simulator.
- video – Android Tutorial Get Sensors List From Your Phone
- Download the latest sensorsimulator-x.x.x.zip from the download tab and unzip (if you didn’t already).
- In Eclipse
- make sure the Google APIs are loaded
- To access the Eclipse AVD Manage windows->AVD manager. My avd name was “my_avd”
- Start the Android emulator by selecting the avd and click “Start”, On the next screen click “Launch”.
- Start sensorsimulator-2.0-rc1/bin/sensorsimulator-x.x.x.jar (Java standalone application) in the bin folder.
- Install apk file in emulayot
./adb -e install -r ~/downloads/sensorsimulator-2.0-rc1/bin/SensorSimulatorSettings-2.0-rc1.apk
The message that returns is:
“455 KB/s (49681 bytes in 0.106s)
pkg: /data/local/tmp/SensorSimulatorSettings-2.0-rc1.apk
Success” - Launch SensorSimulator on the emulator. I had to fool around with the apps fumction in the emulator. I finally went to application manager and found that the sensor simulator was installed. It eventualy showed up in the apps screen (I don’t know what I did). I clicked “test” and used the default IP and Port values that were set. I then did a “connect” and all the vaues read fine. The IP address and socket (port) number can be changed, if desired.
The sensor simulator jar file allows the user to set various sensor test values
The sensor simulator android app connects to the ip/port and reads the values set.