sinkuri256 / android-scripting

Automatically exported from code.google.com/p/android-scripting
0 stars 0 forks source link

batteryStartMonitoring() from python crashes sl4a #519

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What device(s) are you experiencing the problem on?
HTC Dream

What firmware version are you running on the device?
JFK 1.5

What steps will reproduce the problem?
Run this (python) script:

import android

droid = android.Android()
droid.batteryStartMonitoring()

What is the expected output? What do you see instead?
Script should finish normally. Instead, I get "The application SL4A .. has 
stopped unexpectedly).

What version of the product are you using? On what operating system?
sl4a_r3

Please provide any additional information below.
Issue 488 looks similar, but there problem only happens in 
batteryStopMonitoring.

Original issue reported on code.google.com by zblab...@gmail.com on 12 Feb 2011 at 9:39

GoogleCodeExporter commented 9 years ago
Please include logcat when reporting these issues.

In any case, I think you'll find it's the same issue as 488. 

Try the latest update: http://www.mithril.com.au/android/sl4a_r4x.apk

(See [http://code.google.com/p/android-scripting/wiki/Unofficial Unofficial 
releases] for more detail)

Let me know if that solves the problem.

Original comment by rjmatthews62 on 13 Feb 2011 at 1:58

GoogleCodeExporter commented 9 years ago
Thanks for pointers.

I tried sl4a_r4x. That one does install, but will crash when clicking on 
script. (Before script is ran). I tried installing experimental python, but it 
did not help.

Next I tried sl4a_r3x. That is refused by installer.

(Sorry for no logcat -- no PC nearby...)

Original comment by zblab...@gmail.com on 13 Feb 2011 at 10:37

GoogleCodeExporter commented 9 years ago
I tried sl4a_r4x. That one installs but crashes when clicking on script.
Crash seems to be before script has chance to run, but I tried installing
experimental python anyway. No change. (Sorry no logcat -- no PC nearby).

Comment #1 on issue 519 by rjmatthews62: batteryStartMonitoring() from
python crashes sl4a
http://code.google.com/p/android-scripting/issues/detail?id=519

Please include logcat when reporting these issues.

In any case, I think you'll find it's the same issue as 488.

Try the latest update: http://www.mithril.com.au/android/sl4a_r4x.apk

(See [http://code.google.com/p/android-scripting/wiki/Unofficial Unofficial
releases] for more detail)

Let me know if that solves the problem.

Original comment by zblab...@gmail.com on 13 Feb 2011 at 10:40

GoogleCodeExporter commented 9 years ago
Then I tried sl4a_r3x. That one is refused by the installer.

Comment #1 on issue 519 by rjmatthews62: batteryStartMonitoring() from
python crashes sl4a
http://code.google.com/p/android-scripting/issues/detail?id=519

Please include logcat when reporting these issues.

In any case, I think you'll find it's the same issue as 488.

Try the latest update: http://www.mithril.com.au/android/sl4a_r4x.apk

(See [http://code.google.com/p/android-scripting/wiki/Unofficial Unofficial
releases] for more detail)

Let me know if that solves the problem.

Original comment by zblab...@gmail.com on 13 Feb 2011 at 10:41

GoogleCodeExporter commented 9 years ago
Hnnn.... the main problem seems to be you're running 1.5.
Quickaction menus seem to be choking when I try running in a 1.5 emulator.
I think I can retrofit a simpler menu, once I get some spare brain space.

What version of SL4A were you using previously? It will help me track down a 
solution.

Original comment by rjmatthews62 on 20 Feb 2011 at 9:08

GoogleCodeExporter commented 9 years ago
Found the bug, which was actually several different issues to do with version 
1.5 of Android. 
  * Fixed menu so it will still work on 1.5
  * Fixed battery output so that it doesn't try to use details not available on 1.5

Fix is in http://www.mithril.com.au/android/sl4a_r4x.apk
Please test. 
PS: Do *not* try to use latest python, it doesn't seem compatible with 1.5. 
Stick with r1.

Original comment by rjmatthews62 on 20 Feb 2011 at 11:20

GoogleCodeExporter commented 9 years ago
I can confirm that fixed sl4a_r4x now runs on 1.5. (Menu is indeed fixed).

Original comment by zblab...@gmail.com on 26 Feb 2011 at 9:43

GoogleCodeExporter commented 9 years ago
And battery monitoring now works. Unfortunately, 1.5 does not support
getting %age, but plugged/unplugged seems ok.

Original comment by zblab...@gmail.com on 26 Feb 2011 at 9:49

GoogleCodeExporter commented 9 years ago
Thanks!

Original comment by zblab...@gmail.com on 26 Feb 2011 at 10:08

GoogleCodeExporter commented 9 years ago
Fixed in sl4a_r4x

Original comment by rjmatthews62 on 5 Mar 2011 at 12:00