New Alpha release, version 1.35.0

311 views
Skip to first unread message

Henrik "The Developer" Lindqvist

unread,
Aug 11, 2022, 12:27:15 PM8/11/22
to Automate
Lots of new feature to test. I really need your feedback on the new Battery properties block as the values returned by the Android API don't seem to be as officially documented and seem to differ by brand/device.

Please test, report any issues, and give feedback. Opt-in for Alpha testing here.

What’s new:
  • The “execute shell command” privilege now enforced by Shell command (superuser) blocks
  • Battery charging block
  • Battery properties block
  • Image crop block
  • Image flip block
  • Image load block
  • Image rescale block
  • Image rotate block
  • Image sample color block
  • Image unload block
  • Image write block
  • App installed block got APK paths output variable
  • Assist request block got Intent and Web URL output variables (Android 6+)
  • Interact block got “Show audio volume UI” action
  • Media tag read block got Orientation output variable
  • colorRecode function support CMYK, Grayscale, YCbCr and YCCK color spaces

Pete

unread,
Aug 16, 2022, 3:26:44 AM8/16/22
to Automate
Results of the battery properties block...

08-16 01:24:46.795 I 212555@1: Flow beginning
08-16 01:24:46.795 I 212555@6: Battery properties
08-16 01:24:46.800 U 212555@10: capacity: 2915
08-16 01:24:46.801 U 212555@11: remaining: 50%
08-16 01:24:46.801 U 212555@12: remaining charge: 1416
08-16 01:24:46.801 U 212555@13: remaining energy: null
08-16 01:24:46.802 U 212555@14: usage current: -354.687
08-16 01:24:46.802 U 212555@15: avg usage current: 278750
08-16 01:24:46.802 U 212555@16: voltage: 38.51
08-16 01:24:46.802 U 212555@17: temp: 34.9
08-16 01:24:46.802 U 212555@18: tech: Li-ion
08-16 01:24:46.803 I 212555@0: Stopped at end

Pete

unread,
Aug 16, 2022, 3:40:21 AM8/16/22
to Automate
Looks ok for the most part but looks like a minus sign and decimal may be missing for average usage current and then an issue with remaining energy returning null. All others results look correct.

Henrik "The Developer" Lindqvist

unread,
Aug 16, 2022, 6:34:56 AM8/16/22
to Automate
Thanks, that's almost perfect.

Device model/brand?
Android version?

I assume your device was NOT charging when getting the properties, then:
  • "remaining charge" seems incorrect, i.e. your device report as officially documented but the block incorrectly negate it
  • "usage current average" seems incorrect, should be divided by 1000 and negated.
  • few devices seem to support "remaining energy", neither does mine

mikael.c....@gmail.com

unread,
Aug 16, 2022, 10:24:57 AM8/16/22
to Automate
I see there is another release coming. Has any progress been made on fixing the bug with the SMS limits? I am still getting issues where the counters have to be manually be reset in order for a script to be able to send SMS automatically.

Kind regards,

Mikael

Henrik "The Developer" Lindqvist

unread,
Aug 16, 2022, 11:03:21 AM8/16/22
to Automate
I did some more testing of the "rate limiting" algorithm and it passed, i.e. i couldn't find any issues with it.
I have however changed so its run-time values (current usage and last time used) should now be saved to disk more often. Did that not have any affect?

Pete

unread,
Aug 16, 2022, 1:15:50 PM8/16/22
to Automate
Google Pixel 3 running android Q...here are the results while charging (previous results were not while charging)...

08-16 11:13:40.053 I 213567@1: Flow beginning
08-16 11:13:40.053 I 213567@6: Battery properties
08-16 11:13:40.057 U 213567@10: capacity: 2915
08-16 11:13:40.057 U 213567@11: remaining: 32%
08-16 11:13:40.057 U 213567@12: remaining charge: 924
08-16 11:13:40.057 U 213567@13: remaining energy: null
08-16 11:13:40.058 U 213567@14: usage current: 1517.187
08-16 11:13:40.058 U 213567@15: avg usage current: -1511562
08-16 11:13:40.058 U 213567@16: voltage: 40.02
08-16 11:13:40.058 U 213567@17: temp: 39.8
08-16 11:13:40.058 U 213567@18: tech: Li-ion
08-16 11:13:40.059 I 213567@0: Stopped at end

Ricardo Fernández Serrata

unread,
Aug 21, 2022, 6:21:54 PM8/21/22
to Automate
I'm testing right now. The new out-var of "App Installed" works fine so far. I'll be testing more features soon.

BTW, this update is AWESOME! Thank you so much!

Ricardo Fernández Serrata

unread,
Aug 25, 2022, 2:17:21 PM8/25/22
to Automate
Sorry for being late. These are my results so far:

Shell permission works perfectly. Only tested standard-user, not SU/root.


Battery Charging doesn't work "When Changed". Goes to "NO" path unconditionally (at "Immediate" mode). Only tested with AC, not USB.


Batt. Props.
Volts aren't actually in "volt" units, they're deciVolts. It seems `avg_current` is correct, but not `current`.

(Disconnected)
capacity 2600mAh
rem_cent 68%
rem_charge 0mAh
rem_energy mWh
current 0.117mA
avg_current -149mA
volt 38.28V
temp 34.5°C
tech Li-ion

(AC charging)
capacity 2600mAh
rem_cent 68%
rem_charge 0mAh
rem_energy mWh
current 0.16mA
avg_current -130mA
volt 38.39V
temp 34.5°C
tech Li-ion

Henrik "The Developer" Lindqvist

unread,
Aug 26, 2022, 5:48:52 AM8/26/22
to Automate
Thanks, this is great!

The Battery charging with proceed=Immediately issue must be due to an Android bug/feature, it seems that on some device its state change is delayed, maybe taking a few seconds/minutes or percent of charge change for it to update.

Volt is indeed incorrect.

Both current and average current seems to differ with device, what brand/model are you using?

Ricardo Fernández Serrata

unread,
Aug 30, 2022, 7:09:31 AM8/30/22
to Automate
Model: SM-J327VPP
Comercial Name: Galaxy J3 Mission
Manufacturer: Samsung
Carrier and Brand: Verizon (but the SIM card is from Altice)
Android version: 8.1 Oreo
Linux Kernel version 3.18.71

P. Andreas Schmidt, IVE

unread,
Feb 18, 2024, 8:41:17 AM2/18/24
to Automate for Android
Hello Henrik,

sorry for a very late post to this. And I guess it mustn't be of great importance? Considering that on the todo list there are no entries related to battery or charge or ...

But just to add, I had noted the same issue with the battery charging block that when using immediately it will always go through No, even when charging, and in that case still fill the variable with the time remaining till full charge. When set to when changed it never picked up a change, neither after minutes, nor when the charging-percentage was changed...

As for the properties, here are two examples (I've got an LG Velvet LM-G910EMW, Android 12  V30I-EEA-XX):
Before charging:
Capacity: 4300
Remaining battery percentage: 34 (1462) - between brackets what 34% of the capacity is
Remaining battery energy:
Remaining battery charge: 1285.331 (29.89141860465116) - here how many % is the remaining charge of the capacity - why is there a discrepancy? Or am I misunderstanding the values/names?
Current Usage:63.476
Average Usage:
Volt: 3.78
Temperature: 16.6
Tech: Li-ion

Right after charging (slow charging for 2h0m35s)
Capacity: 4300
Remaining battery percentage: 80 (3440)
Remaining battery energy:
Remaining battery charge: 3043.451 (70.77793023255815)
Current Usage:-944.823 - most likely it was still charging, as a negative current usage value occurs on my phone during charge ???
Average Usage:
Volt: 4.313
Temperature: 20.2
Tech: Li-ion

Hope this helps...

Any chance that those blocks will get an improvement? Or is there no possibility?

Thanks!

Henrik "The Developer" Lindqvist

unread,
Feb 18, 2024, 11:40:16 AM2/18/24
to Automate for Android
Sadly i don't think there many ways improving the Battery charging block, since it's an Android issue, as the documentation say, "On some devices the “charging” state as reported by this block may be delayed, temporarily incorrect, or not work at all. "
As a test, try using the Broadcast receive block with action "android.os.action.CHARGING" and "android.os.action.DISCHARGING" to see if it reports are any more accurate.

As for the Battery properties block.
But as the documentation say, "Some devices may return incorrect values, e.g. negated or not the unit as officially documented by Android. Please use the Help & feedback menu to report any such issues."
Reply all
Reply to author
Forward
0 new messages