RoosterRat / a2dpvolume

Automatically exported from code.google.com/p/a2dpvolume
1 stars 1 forks source link

Tasker plugin #128

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
It would be great if you would develop a stand-alone Tasker plugin that would 
allow a Tasker user to force a connection to a Bluetooth device. No other 
features of A2DP Volume, such as location detection, automatic volume control, 
etc., would be needed since these could be handled by Tasker. 

This would have the advantage of eliminating the need for the A2DP Volume 
service to be running all the time and occupying memory, because Tasker is 
already running all the time and could detect the conditions a user wants to 
act on.

Original issue reported on code.google.com by dch...@gmail.com on 18 Jul 2012 at 1:27

GoogleCodeExporter commented 9 years ago
By the way, here are the details for developing a Tasker Plugin.

http://tasker.dinglisch.net/plugins.html

Original comment by dch...@gmail.com on 18 Jul 2012 at 2:10

GoogleCodeExporter commented 9 years ago
Thanks for adding this to the list.  I see 10 people starred this already.  

One issue however:  In order for any app to receive an intent (like from 
Tasker) it must have an activity running.  So, the service will still need to 
be running anyway to use any features of A2DP Volume.  So you might as well use 
A2DP Volume to handle all of those things anyway.  

I presume you are using Tasker for many other things too.  In that case it 
would be better to submit an issue to the Tasker team to just implement the 
Bluetooth force connect like I have done.  A2DP Volume is open source so as 
long as they follow the OS license agreement they can just use the functions 
from my app in Tasker.

Original comment by JimR...@gmail.com on 19 Jul 2012 at 12:33

GoogleCodeExporter commented 9 years ago
I see Tasker is not free or open source.  Too bad.  So, they cannot directly 
implement my code.  They could still implement similar functionality though.

Original comment by JimR...@gmail.com on 19 Jul 2012 at 12:45

GoogleCodeExporter commented 9 years ago
Please excuse my ignorance if what I'm about to say is, well, ignorant. :-)

I don't think that the Tasker/Locale plugin concept relies on intents. I 
believe it's designed to package code in such a way that it's independent from 
any other activities.

Original comment by dch...@gmail.com on 19 Jul 2012 at 12:47

GoogleCodeExporter commented 9 years ago
Pretty much all app interaction in Android is done with Intents.  An app cannot 
respond if it is not running.  

Original comment by JimR...@gmail.com on 21 Jul 2012 at 8:02

GoogleCodeExporter commented 9 years ago
OK, thanks. I thought there was a chance that the Tasker/Locale Plugin spec 
http://www.twofortyfouram.com/developer.html
would run as part of the Tasker process instead of in it's own separate 
process. 

Guess not, eh?

Original comment by dch...@gmail.com on 21 Jul 2012 at 9:11

GoogleCodeExporter commented 9 years ago
Sure you could use Tasker to launch my app.  However, it would just launch 
similar to what it does now on boot.  So, then you would need to pass with the 
launch intent extras that would tell my app to do something.  The problem is I 
would have no idea what just connected because I listen for the connection to 
happen and if A2DP Volume was not running I would not receive that intent and 
would have no idea what just connected.  Not knowing what connected A2DP Volume 
would just sit and listen.  If Tasker sent me the mac address of what just 
connected then I could probably make it work but what is the point?  If they 
did that they might as well just implement the connect feature.  The more I 
think about this the more I think Tasker just needs to implement the force 
connect.  It is not that hard to do actually and they can simply read my open 
source and see exactly what I did.  Using my app for only that feature and 
leaving most of the other A2DP Volume features to Tasker makes no sense.  

I did start another app called A2DP Connect. 
http://code.google.com/p/a2dp-connect/
 It would make far more sense to integrate that with Tasker.  It is just a widget that does the force connect.  Nothing more.  If you just want the force connect, then this issue needs to move to the A2DP Connect issues list to be worked.  That said, I have not worked on that app in quite a while.  However, another developer did get it working recently and he said he would push the code and APK.  Lets move this issue to A2DP Connect for implementation.

Original comment by JimR...@gmail.com on 21 Jul 2012 at 9:51

GoogleCodeExporter commented 9 years ago
Now A2DP Connect is done and on Play Store: 
https://play.google.com/store/apps/details?id=a2dp.connect

Tasker plugin is also available on the A2DP Connect website here: 
http://code.google.com/p/a2dp-connect/

Original comment by JimR...@gmail.com on 16 Dec 2012 at 5:55