An announcement for the Android users amongst us
-
I've spent about 5 hours trying to get the android tasker app to monitor the onewheel app and alert me when battery falls below 50%. Think I've finally got that something that works, still lots of bugs though..
-
@parrothd Oh yeah? Care to share your profile as it evolves?
-
@TonyGDTLA said:
As do I. But I've gotten pretty good at reading the power button light for battery level. With in 5-10%.
So...
- How does that work?
and - How can you see your power light while riding?
- How does that work?
-
@bmtka Sure, it's been a while since I've used tasker but I think I have the basic logic down.
This is on my nexus 6. Basically I've tried everything to get the battery percent out of the app, however they way they wrote it(just like the IOS app) you can't do much with it. So I switched gears and went another direction.
I have tasker open the app and then use the autoinput plugin to get 1 pixel screen shot from the main battery power meter screen. If it's color #445366 which is the background depending on where I get the pixel from tells me the color change/height of the power meter.
I can post an export if wanted..
tasker
autoinput plugin
secure settings
-
@parrothd Dude that's very creative. Yah if you could upload the export I'll see if I can play with it as well. Get it to send a notification to my Gear S2 watch and no more worrying about battery-life.
Thanks!!
-
@parrothd That is actually really clever. Many of my trusty Tasker profiles go unused since much of that functionality is built into Android these days. I will give it a shot.
-
You need to tweak the pixel location, for my phone it's probably different, I've been testing around 90% alert... :)
TaskerData sr="" dvi="1" tv="4.8u1m">
<Profile sr="prof2" ve="2">
<cdate>1457055617603</cdate>
<clp>true</clp>
<edate>1457191519609</edate>
<id>2</id>
<mid0>3</mid0>
<nme>Battery Mon1</nme>
<App sr="con0" ve="2">
<cls0>com.rideonewheel.onewheel.ui.splash.OWSplashScreen</cls0>
<flags>2</flags>
<label0>Onewheel</label0>
<pkg0>com.rideonewheel.onewheel</pkg0>
</App>
</Profile>
<Task sr="task3">
<cdate>1457055628207</cdate>
<edate>1457191362880</edate>
<id>3</id>
<nme>Test</nme>
<pri>100</pri>
<Action sr="act0" ve="7">
<code>549</code>
<Str sr="arg0" ve="3">%batt</Str>
<Int sr="arg1" val="0"/>
</Action>
<Action sr="act1" ve="7">
<code>547</code>
<Str sr="arg0" ve="3">%batt</Str>
<Str sr="arg1" ve="3">1</Str>
<Int sr="arg2" val="0"/>
<Int sr="arg3" val="0"/>
</Action>
<Action sr="act10" ve="7">
<code>28028</code>
<Bundle sr="arg0">
<Vals sr="val">
<CaptureMode>0</CaptureMode>
<CaptureMode-type>java.lang.String</CaptureMode-type>
<CatpureAudio>false</CatpureAudio>
<CatpureAudio-type>java.lang.Boolean</CatpureAudio-type>
<CatpureScreenshot>/storage/emulated/0/AutoInput/screencapture.png</CatpureScreenshot>
<CatpureScreenshot-type>java.lang.String</CatpureScreenshot-type>
<CompareTo><null></CompareTo>
<CompareTo-type>java.lang.String</CompareTo-type>
<Crop><null></Crop>
<Crop-type>java.lang.String</Crop-type>
<Duration>0</Duration>
<Duration-type>java.lang.String</Duration-type>
<File>/storage/emulated/0/AutoInput/screencapture.mp4</File>
<File-type>java.lang.String</File-type>
<Palette>false</Palette>
<Palette-type>java.lang.Boolean</Palette-type>
<PixelColor>800,405</PixelColor>
<PixelColor-type>java.lang.String</PixelColor-type>
<Resolution>2</Resolution>
<Resolution-type>java.lang.String</Resolution-type>
<com.twofortyfouram.locale.intent.extra.BLURB>Screenshot Path: /storage/emulated/0/AutoInput/screencapture.png
Pixel Color : 800,405
Palette: false
Get Average Color : false</com.twofortyfouram.locale.intent.extra.BLURB>
<com.twofortyfouram.locale.intent.extra.BLURB-type>java.lang.String</com.twofortyfouram.locale.intent.extra.BLURB-type>
<net.dinglisch.android.tasker.RELEVANT_VARIABLES><StringArray sr=""><_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES0>%aifiles()
File Paths
File Paths of the selected files.<br/>Will contain only the selected files (video or screenshot)</_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES0><_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES1>%aiscreenshotfile
Screenshot Path
Path where the screenshot was saved</_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES1><_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES2>%aiscreenshotpixelcolor
Screenshot Pixel Color
Color of the pixel in the specified coordinates in the hexadecimal format</_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES2><_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES3>%aivideofile
Video Path
Path where the video of the screen capture was saved</_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES3><_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES4>%err
Error Code
Only available if you select <b>Continue Task After Error</b> and the action ends in error</_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES4><_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES5>%errmsg
Error Message
Only available if you select <b>Continue Task After Error</b> and the action ends in error</_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES5></StringArray></net.dinglisch.android.tasker.RELEVANT_VARIABLES>
<net.dinglisch.android.tasker.RELEVANT_VARIABLES-type>[Ljava.lang.String;</net.dinglisch.android.tasker.RELEVANT_VARIABLES-type>
<net.dinglisch.android.tasker.extras.VARIABLE_REPLACE_KEYS>FieldsToGet CompareTo PixelColor Crop CaptureMode Resolution Bitrate File Duration CatpureScreenshot plugininstanceid plugintypeid </net.dinglisch.android.tasker.extras.VARIABLE_REPLACE_KEYS>
<net.dinglisch.android.tasker.extras.VARIABLE_REPLACE_KEYS-type>java.lang.String</net.dinglisch.android.tasker.extras.VARIABLE_REPLACE_KEYS-type>
<net.dinglisch.android.tasker.subbundled>true</net.dinglisch.android.tasker.subbundled>
<net.dinglisch.android.tasker.subbundled-type>java.lang.Boolean</net.dinglisch.android.tasker.subbundled-type>
<plugininstanceid>c830bf45-1b68-4faa-bf44-4d087e966924</plugininstanceid>
<plugininstanceid-type>java.lang.String</plugininstanceid-type>
<plugintypeid>com.joaomgcd.autoinput.intent.IntentScreenCapture</plugintypeid>
<plugintypeid-type>java.lang.String</plugintypeid-type>
</Vals>
</Bundle>
<Str sr="arg1" ve="3">com.joaomgcd.autoinput</Str>
<Str sr="arg2" ve="3">AutoInput Screen Capture</Str>
<Int sr="arg3" val="200"/>
</Action>
<Action sr="act11" ve="7">
<code>171</code>
<on>false</on>
<Int sr="arg0" val="7326"/>
<Int sr="arg1" val="302"/>
<Int sr="arg2" val="50"/>
<Int sr="arg3" val="3"/>
</Action>
<Action sr="act12" ve="7">
<code>61</code>
<Int sr="arg0" val="200"/>
<ConditionList sr="if">
<Condition sr="c0" ve="3">
<lhs>%aiscreenshotpixelcolor</lhs>
<op>0</op>
<rhs>#445366</rhs>
</Condition>
</ConditionList>
</Action>
<Action sr="act13" ve="7">
<code>171</code>
<Int sr="arg0" val="8000"/>
<Int sr="arg1" val="1000"/>
<Int sr="arg2" val="90"/>
<Int sr="arg3" val="3"/>
<ConditionList sr="if">
<Condition sr="c0" ve="3">
<lhs>%aiscreenshotpixelcolor</lhs>
<op>2</op>
<rhs>#445366</rhs>
</Condition>
</ConditionList>
</Action>
<Action sr="act14" ve="7">
<code>548</code>
<Str sr="arg0" ve="3">%aiscreenshotpixelcolor</Str>
<Int sr="arg1" val="0"/>
</Action>
<Action sr="act15" ve="7">
<code>16</code>
</Action>
<Action sr="act16" ve="7">
<code>30</code>
<Int sr="arg0" val="0"/>
<Int sr="arg1" val="30"/>
<Int sr="arg2" val="0"/>
<Int sr="arg3" val="0"/>
<Int sr="arg4" val="0"/>
</Action>
<Action sr="act17" ve="7">
<code>135</code>
<Int sr="arg0" val="0"/>
<Int sr="arg1" val="2"/>
<Str sr="arg2" ve="3"/>
</Action>
<Action sr="act2" ve="7">
<code>30</code>
<Int sr="arg0" val="0"/>
<Int sr="arg1" val="3"/>
<Int sr="arg2" val="0"/>
<Int sr="arg3" val="0"/>
<Int sr="arg4" val="0"/>
</Action>
<Action sr="act3" ve="7">
<code>11820</code>
<Bundle sr="arg0">
<Vals sr="val">
<com.intangibleobject.securesettings.plugin.extra.BLURB>Screen & Keyboard Lights On
1 Second</com.intangibleobject.securesettings.plugin.extra.BLURB>
<com.intangibleobject.securesettings.plugin.extra.BLURB-type>java.lang.String</com.intangibleobject.securesettings.plugin.extra.BLURB-type>
<com.intangibleobject.securesettings.plugin.extra.SETTING>wake_device</com.intangibleobject.securesettings.plugin.extra.SETTING>
<com.intangibleobject.securesettings.plugin.extra.SETTING-type>java.lang.String</com.intangibleobject.securesettings.plugin.extra.SETTING-type>
<com.intangibleobject.securesettings.plugin.extra.WAKE_LOCK_DURATION>1000</com.intangibleobject.securesettings.plugin.extra.WAKE_LOCK_DURATION>
<com.intangibleobject.securesettings.plugin.extra.WAKE_LOCK_DURATION-type>java.lang.Long</com.intangibleobject.securesettings.plugin.extra.WAKE_LOCK_DURATION-type>
<com.intangibleobject.securesettings.plugin.extra.WAKE_LOCK_TYPE>full</com.intangibleobject.securesettings.plugin.extra.WAKE_LOCK_TYPE>
<com.intangibleobject.securesettings.plugin.extra.WAKE_LOCK_TYPE-type>java.lang.String</com.intangibleobject.securesettings.plugin.extra.WAKE_LOCK_TYPE-type>
<com.twofortyfouram.locale.intent.extra.BLURB>Screen & Keyboard Lights On
1 Second</com.twofortyfouram.locale.intent.extra.BLURB>
<com.twofortyfouram.locale.intent.extra.BLURB-type>java.lang.String</com.twofortyfouram.locale.intent.extra.BLURB-type>
<net.dinglisch.android.tasker.subbundled>true</net.dinglisch.android.tasker.subbundled>
<net.dinglisch.android.tasker.subbundled-type>java.lang.Boolean</net.dinglisch.android.tasker.subbundled-type>
</Vals>
</Bundle>
<Str sr="arg1" ve="3">com.intangibleobject.securesettings.plugin</Str>
<Str sr="arg2" ve="3">Secure Settings</Str>
<Int sr="arg3" val="0"/>
</Action>
<Action sr="act4" ve="7">
<code>20</code>
<App sr="arg0">
<appClass>com.rideonewheel.onewheel.ui.splash.OWSplashScreen</appClass>
<appPkg>com.rideonewheel.onewheel</appPkg>
<label>Onewheel</label>
</App>
<Str sr="arg1" ve="3"/>
<Int sr="arg2" val="0"/>
<Int sr="arg3" val="1"/>
</Action>
<Action sr="act5" ve="7">
<code>30</code>
<Int sr="arg0" val="0"/>
<Int sr="arg1" val="5"/>
<Int sr="arg2" val="0"/>
<Int sr="arg3" val="0"/>
<Int sr="arg4" val="0"/>
</Action>
<Action sr="act6" ve="7">
<code>15355</code>
<Bundle sr="arg0">
<Vals sr="val">
<AppPackage>com.rideonewheel.onewheel</AppPackage>
<AppPackage-type>java.lang.String</AppPackage-type>
<IsFirstAction>false</IsFirstAction>
<IsFirstAction-type>java.lang.Boolean</IsFirstAction-type>
<OnlyClickable>false</OnlyClickable>
<OnlyClickable-type>java.lang.Boolean</OnlyClickable-type>
<OnlyVisible>true</OnlyVisible>
<OnlyVisible-type>java.lang.Boolean</OnlyVisible-type>
<Regex>false</Regex>
<Regex-type>java.lang.Boolean</Regex-type>
<UIUpdateFields>com.rideonewheel.onewheel:id/ridingModeLabel=:=ds,com.rideonewheel.onewheel:id/batteryLabel=:=batt</UIUpdateFields>
<UIUpdateFields-type>java.lang.String</UIUpdateFields-type>
<UIUpdateText><null></UIUpdateText>
<UIUpdateText-type>java.lang.String</UIUpdateText-type>
<com.twofortyfouram.locale.intent.extra.BLURB>Only Visible: true
Only Clickable: false
App Package: com.rideonewheel.onewheel
Check Screen State: false
Variables: ds, batt</com.twofortyfouram.locale.intent.extra.BLURB>
<com.twofortyfouram.locale.intent.extra.BLURB-type>java.lang.String</com.twofortyfouram.locale.intent.extra.BLURB-type>
<net.dinglisch.android.tasker.RELEVANT_VARIABLES><StringArray sr=""><_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES0>%aiapp
App Name
</_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES0><_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES1>%aiid()
Element Ids
</_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES1><_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES2>%aipackage
App Package Name
</_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES2><_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES3>%aitext()
Element Texts
</_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES3><_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES4>%batt
batt
batt</_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES4><_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES5>%ds
ds
ds</_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES5><_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES6>%err
Error Code
Only available if you select <b>Continue Task After Error</b> and the action ends in error</_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES6><_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES7>%errmsg
Error Message
Only available if you select <b>Continue Task After Error</b> and the action ends in error</_array_net.dinglisch.android.tasker.RELEVANT_VARIABLES7></StringArray></net.dinglisch.android.tasker.RELEVANT_VARIABLES>
<net.dinglisch.android.tasker.RELEVANT_VARIABLES-type>[Ljava.lang.String;</net.dinglisch.android.tasker.RELEVANT_VARIABLES-type>
<net.dinglisch.android.tasker.extras.VARIABLE_REPLACE_KEYS>ActionTimeout AppPackage UIUpdateFields UIUpdateText FieldsToGet plugininstanceid plugintypeid </net.dinglisch.android.tasker.extras.VARIABLE_REPLACE_KEYS>
<net.dinglisch.android.tasker.extras.VARIABLE_REPLACE_KEYS-type>java.lang.String</net.dinglisch.android.tasker.extras.VARIABLE_REPLACE_KEYS-type>
<net.dinglisch.android.tasker.subbundled>true</net.dinglisch.android.tasker.subbundled>
<net.dinglisch.android.tasker.subbundled-type>java.lang.Boolean</net.dinglisch.android.tasker.subbundled-type>
<plugininstanceid>acc94305-6a1c-443d-a0c1-e96e45235976</plugininstanceid>
<plugininstanceid-type>java.lang.String</plugininstanceid-type>
<plugintypeid>com.joaomgcd.autoinput.intent.IntentUIQuery</plugintypeid>
<plugintypeid-type>java.lang.String</plugintypeid-type>
</Vals>
</Bundle>
<Str sr="arg1" ve="3">com.joaomgcd.autoinput</Str>
<Str sr="arg2" ve="3">AutoInput UI Query</Str>
<Int sr="arg3" val="20"/>
</Action>
<Action sr="act7" ve="7">
<code>548</code>
<Str sr="arg0" ve="3">%batt %ds</Str>
<Int sr="arg1" val="0"/>
</Action>
<Action sr="act8" ve="7">
<code>171</code>
<Int sr="arg0" val="7425"/>
<Int sr="arg1" val="7486"/>
<Int sr="arg2" val="50"/>
<Int sr="arg3" val="3"/>
<ConditionList sr="if">
<Condition sr="c0" ve="3">
<lhs>%batt</lhs>
<op>0</op>
<rhs>1</rhs>
</Condition>
</ConditionList>
</Action>
<Action sr="act9" ve="7">
<code>30</code>
<Int sr="arg0" val="0"/>
<Int sr="arg1" val="5"/>
<Int sr="arg2" val="0"/>
<Int sr="arg3" val="0"/>
<Int sr="arg4" val="0"/>
</Action>
</Task>
</TaskerData>
-
THANK YOU! I know I complained a lot, but the app works great on my LG G4. I feel a lot safer being able to monitor my battery. THANKS
-
can't believe it only works on android 5.0 and up, i waited so long, PLS FM MAKE IT BACKWARDS COMPATIBLE
-
@fabuz That sucks man, sorry