[Q] Route audio from media out to mic. in internally - Android Q&A, Help & Troubleshooting

Hi,
First time posting here, but not new to rooting and flashing. All thanks to xda and it's user.
So, I want route the audio coming out from phone's speaker/headphone or w/e output device to microphone internally.
For example,
If my friend is listening to a song and he calls me and asks which song is this, I want to able to route the audio to Shazam or Soundhound without the use of another device (although that's not the reason for the problem)
Anothe example is, Whatsapp. Lets say I am listening to a song (locally on device or on a radio app in my cell), I want to able to use that quick audio message button in Whatsapp to record that song, internally, so if there bunch of people in the car, their sound doesn't get recorded.
And I can think of tonnes of situations where this could be used like when you are talking to someone on phone, use song/sounds/audio phrases direct from phone. Like a using some famous/quote but instead of you quoting them, using the actual person's sound from your local storage/youtube or any other audio app storage. Using sound effects, all internally. You can get so creative.
And this is something that is done by music producers all the time, routing audio and play it with recorded audio, but all done with hardware. It could be easily done using software or hardware on a computer.
I thought of using the 3.5 audio jack with mic to route the audio using wire by connecting them but I would require that special hardware (modded 3.5 jack wire) all the time and won't really help other people much. A software solution would be a lot more helpful.
I did try using this app, called SoundAbout to fix my problem but it didn't help much, or maybe I was doing something wrong.
ps. This is the 2nd time I am writing this lol. First time xda logged me out and I lost the whole thing. Would be nice if there was a app (for windows) that would copy any text written in any dialog box automatically (just like autofill feature but for larger text fields) and keep updating it on the fly. For example, text in the Title box gets copied in the app after each character punched with 5 histories. Same goes for Message box. In case of Firefox crash or accidental refresh or like in my case getting logged out, there is text stored in another app that can be retrieved. I am sure there are solutions used by devs. as they do tonnes of coding. Please share you thoughts.
Also please feel free to give any advice regarding right category, title, tags etc. so that this thread is organized and easily searchable.

I am searching for solution too. Some professionals are needed to check on these:
1. https://github.com/jurihock/voicesmith solving to step between the mic & audio feed processing
2. `system/ect/mixer_paths.xml` file can be hacked (maybe alter in some devices)?
3. This is just for more understanding: https://developer.android.com/guide/topics/media/sharing-audio-input

Did you figure it out? Are there not any Chinese or Russian apps that will bypass this restriction?

Related

How to turn off the HTC Audio Manager

HTC's Audio Manager is crap. To add insult to injury it takes over AVRCP controls such that no other application can use them. On an HTC Hero try the following - download and install some other audio player. For example, Google Listen for podcasts or TuneWiki or BeyondPOD. Next connect a AVRCP capible Bluetooth headset like a Sony Ericson HBH-DS980. Press play on the head set and insure that play plays music in the HTC Audio Manager (IOW that Music thingy on the HTC Hero). Insure that Play/Pause on the headset plays or pauses the audio program.
Now start Google Listen (or TuneWiki, or whatever) and play some audio material. Now press Play/Pause on the headset again. You'll see that you'll have two programs playing instead of one. IOW the AVRCP Play/Pause button controls only the HTC Audio Manager.
Therefore I'd like to turn off/uninstall/disable/kill the AVRCP stealing HTC Audio Manager program.
HTC did this same stupid thing on my HTC Touch running WinMo. However a company called Conduit who makes PocketPlayer figured out how to wrestle away AVRCP control from the HTC Audio Manager (and I was able to use a program to disable the Music tab where the HTC Audio Manager lived). So surely there's a programmatic way to accomplish this at least on WinMo - surely there should be a way to disable this on Android! Anybody know of any solutions? This is driving me nuts!
Anybody?!?
Note I figured out that I can root my phone then remove /system/app/HtcMusic.apx and HtcMusic.odex and the HTC Music thing is disabled. The widget is still on the home screen but it fails to start the player stating it's not there. Unfortunately all control of AVRCP is gone too!
Seems to me I just need to install the standard driver for AVRCP. Anybody know anything about that?
defaria said:
Anybody?!?
Note I figured out that I can root my phone then remove /system/app/HtcMusic.apx and HtcMusic.odex and the HTC Music thing is disabled. The widget is still on the home screen but it fails to start the player stating it's not there. Unfortunately all control of AVRCP is gone too!
Seems to me I just need to install the standard driver for AVRCP. Anybody know anything about that?
Click to expand...
Click to collapse
This may not be the best solution, and there's probably someone who can answer the question better than I can... but you could always try a non-HTC ROM for the Hero, aka a Vanilla Android ROM.
Yes, I would like a 1.6 or 2.x version of Android. Do you know where I can get one for a Sprout CDMA based Hero? Also I'd like to have the original Sprint ROM so I can flash back if required. Although I like the HTC Sense stuff i'd give that up of I cam fix this HTC Audio Manager crap. Still an HTC Hero ROM with Sense but minus the HTC Audio Manager bug would be very useful to many.
I had the same problem. So I debugged a little bit and found out the following:
The problem:
Normally an Android device should broadcast a "MEDIA_BUTTON" action when the AVRCP buttons on the bluetooth headset get pressed so that applications like music player can react on these events. It seems that HTC decided to ignore this and uses some other (non-standard) way of doing this on the HTC Hero (maybe on other phones too, I don't know).
My workaround:
I found out that at least l can see the button press events in the device logs. So I implemented a workaround application for myself, which simply monitors these logs. When it finds one of these AVRCP messages it broadcasts the "MEDIA_BUTTON" event which normally the platform should send. I know, this is an ugly way of doing this (because it needs a running service, monitoring the logs) but currently I see no other way.
This enables other applications to react on the headset buttons!
You still need to disable or remove the HTC music app or both applications will react on the buttons! I simply deleted it from my Hero (see instruction below).
As I saw here today that others might be interested in this workaround too, I published my app in the market a few moments ago. It's named "Headset Button Fix".
I cannot guarantee that it works for you, because I had only my headset (Nokia BH 503) for testing and I am not sure if the log messages are the same for other headsets. Just give it a try.
And finally, here the instructions how I removed the HTC music player from my (rooted) HTC Hero:
# Make the phone's filesystem read/writable:
> adb remount
# copy the HTC Music app in the current directory
# (for backup, if you want to reinstall it later)
> adb pull /system/app/HtcMusic.apk ./
# Delete the HTC music app on the phone
> adb shell rm /system/app/HtcMusic.apk
# Restart your phone afterwards.
Hope I could help someone with this..
johnny
Short update:
I found a much more elegant way to receive the headset button press events. Now my application directly receives the AVRCP broadcast intents from Android and re-broadcasts it correctly as MEDIA_BUTTON events for other music players.
So this solution is not ugly anymore (of course, working AVRCP on stock Hero would be the best, but now I can live with it).
I published this new version 2.0 in the market. Search for "Headset Button Fix"
As it does not need logcatting anymore, it needs far less resources!!
(You still have to get rid of the HTC music player. I'm afraid there is no way to prevent it from also start playing, except uninstalling it.)
So long..
Enjoy it.
Will try this later
i have a Sony audiocar with bluetooth AD2P and was wandering the same thing
ok
don't work with my audio car (sony mex-bt2500 )
Hmm.. sorry to hear this. So it seems not to work with every headset..
Hi again!
I quickly wrote a simple debug application which registers a receiver for the same events and simply prints them out. When you look at the screenshot you see how it looks like when I press buttons on my headset.
You could try this with your car system. If don't see anything in the output, then my workaround will not work for you. If you just see different command strings (in the EXTRA_FIELD_OP) then I could adapt my application.
Let me know what you get..
john
P.S.: You have to rename the attachement "DebugAVRCP.zip" to "DebugAVRCP.apk" as the forum seems not to allow .apk attachements.
My bad
its working
but i had to change my player : MortPlayer for Meridian (which have an option to activate Headset Buttons
it works great
but, is it possible to add an option to your app to automaticaliy run it and enable it when we activate bluetooth??
Thanks.
I have a lot of work at the moment, but I also was thinking about this. I will continue working on this next weekend.
regards,
john
As the OP of this thread I was anxious to try this out - but I had been in the process of moving so I'm only now getting back to this. Alas it didn't work for me. Yes I can remove the HtcMusic.apk and I have installed the Headset Button Fix. But pushing play on my headset does not stop or start the player I probably will be using most - Google Listen. You see I listen to podcasts most often and Google Listen's pretty good. It's also free and in the market place so could you download it and try it?
Also, what "player" are you using that works?
As for headset I use the Sony Ericson HBH-DS980. I love 'em! They work very well and are quite convenient. I fail to see how they would be different than any other Bluetooth device. I mean isn't an AVRCP pause control the same for all Bluetooth devices?!?
Other questions:
. Removing HtcMusic.apk removes the HTC Audio Manager music thingy, but you should probably remove that HTC Music widget (com.htc.MusicWidget.apk) too.
. As an installer, couldn't you rename HtcMusic.apk -> HtcMusic.apk.save and com.htc.Music.Widget.apk -> com.htc.Music.Widget.apk.save on install and rename them back on uninstall?
. It would be nice if this could be set up to auto start - and perhaps get rid of the little icon for those of us who would like it to always be running in the background
I would like to work with you - perhaps offline - to get this working for me and all other HTC Hero owners who might have a Bluetooth headset and want to use Google Listen, etc. You can contact me at [email protected].
This just in - I installed MortPlayer to pick a music player to test with. It works! AVRCP works with MortPlayer - just doesn't work with Google Listen! Wonderful! Who do I complain to now? Is it possible for us to debug this?
hi!
was having all the same problems (but with mixzing, I do not know Listen). This nice app makes me happy again about having bought a bluetooth headset!
@uninstall/rename:
AFAIK it's not possible for an application to rename/uninstall other applications on install. Additionally the HTC player is not installed in the "normal" app area, but under /system/ (that's the reason why you cannot uninstall it the standard way).
So I assume there will be no easier option than doing this as root via adb.
and @icon:
on my hero I can deactivate it in the preferences
and yes: autostart on headset connect would be nice!
Ok, tried today with Google Listen:
Seems to work partly (while having Headset Button Fix running). It does not react on the Play/pause button, but "Stop", "Next Track", "Previous Track" seem to work for me (while listening).
As far as I understand this is an issue of Listen but I am not sure about this. What they definitly did not implement is to react on AVRCP when the app is not started yet (some music player do start up then). To do this the app would have to register a BroadcastReceiver via its Manifest.xml file which it doesn't.
Maybe somebody could test the Play/Pause behaviour on a different phone (not a Hero), where AVRCP works normally. If then the behaviour is the same, then probably the Listen app is to blame.
hope that helps..
Pause/Play is all I really want. My Bluetooth headset doesn't have a Stop button and Stop would be the wrong thing to do as it would loss my place in the track. I cannot for the life of me understand why this is so difficult nor why one would implement Stop/Next/Prev but not Play/Pause!!! Makes no sense.
Then again I still haven't figured out why Google Listen seems to be behind WRT podcast feeds. For example, I use Banshee on my Linux box. I've subscribed to, for example, Security Now. Banshee shows and has downloaded the latest episode. But Google Listen? Just has a refresh menu selection. Select that and it thinks for a while but no new Security Now episode. Why does Banshee know about it but not Google Listen? Aren't they both going to the same source RSS feed? Shouldn't they both recognize there's a new episode?!?
Who do I contact exactly to submit bugs/etc. for Google Listen?....
Ah here's the link: http://listen.googlelabs.com
Note they say:
Can I use my Bluetooth headset?
Definitely. In fact, we love using Listen with wireless headsets. Using a headset with A2DP capability, you can get you audio content right in your ear, and often use the headset controls as well.
Click to expand...
Click to collapse
Note the use of the term often! Ugh!
Guess it's off to their forums...
Anybody know of a good podcatcher for Android that works with AVRCP?
(a) solution for audio manager problem..
A solution (I know, not the beauty price) to solve the problem of parallel controlling audio manager and music player (in my case museek), w/o rooting my fone, and deleting audio manager:
I've recorded a nice 3 minute piece of SILENCE with recorder, named it SILENCE, and started audio manager with playlist 'my records' (only containing before mentioned silence recording). Following, start Headset Button Fix (great program!), and Museek; result: although headset still commands audio manager aswell, it only skips/ replays/ forwards the silence recording, and my music on Museek is OK, replay-able, forward-able.. I knows it's a noobie's solution; but it works! (for folks, who like me, don't want to root their Hero)
johnny_z said:
I had the same problem. So I debugged a little bit and found out the following:
The problem:
Normally an Android device should broadcast a "MEDIA_BUTTON" action when the AVRCP buttons on the bluetooth headset get pressed so that applications like music player can react on these events. It seems that HTC decided to ignore this and uses some other (non-standard) way of doing this on the HTC Hero (maybe on other phones too, I don't know).
My workaround:
I found out that at least l can see the button press events in the device logs. So I implemented a workaround application for myself, which simply monitors these logs. When it finds one of these AVRCP messages it broadcasts the "MEDIA_BUTTON" event which normally the platform should send. I know, this is an ugly way of doing this (because it needs a running service, monitoring the logs) but currently I see no other way.
This enables other applications to react on the headset buttons!
You still need to disable or remove the HTC music app or both applications will react on the buttons! I simply deleted it from my Hero (see instruction below).
As I saw here today that others might be interested in this workaround too, I published my app in the market a few moments ago. It's named "Headset Button Fix".
I cannot guarantee that it works for you, because I had only my headset (Nokia BH 503) for testing and I am not sure if the log messages are the same for other headsets. Just give it a try.
And finally, here the instructions how I removed the HTC music player from my (rooted) HTC Hero:
# Make the phone's filesystem read/writable:
> adb remount
# copy the HTC Music app in the current directory
# (for backup, if you want to reinstall it later)
> adb pull /system/app/HtcMusic.apk ./
# Delete the HTC music app on the phone
> adb shell rm /system/app/HtcMusic.apk
# Restart your phone afterwards.
Hope I could help someone with this..
johnny
Click to expand...
Click to collapse
I guess at some point I need to learn this ****! I have been trying for the last 2 days to do this and don't know how to go about it!
I am rooted, got fresh, and gumbo going, so could some one help me out with this!

[REQUEST] Megaphone app for windows mobile 5-6.1-6.5

I've been searching the web for a long time, and the closest thin I've found is ScreamingBee's VoiceTwister, but that isn't what I was thinking of. My request is this: is there anyone out there willing to develop an application that will take input from a device's microphone, and amplify it? That's all, no fancy voice changing, no delays, maybe autotuning, maybe not, and send that realtime output to either the device's built-in speaker, or to a set of headphones, or external audio device plugged into the headphone jack?. You would think such a program would have been created by now, but so far, no dice. I am looking to use such a program to make my sometime job as a DJ easier. I would then be able to announce songs, and then play them all from the same device. Here's a link to the iphone version, for reference: http://download.cnet.com/Megaphone-Free/3000-2094_4-10908257.html
Anybody?
Maybe these links are usefull...
Pocket Stompbox
http://www.4pockets.com/product_info.php?p=81
Cebeans-Apps: look for category "Microphone"
http://www.cebeans.com/programs.htm

An app that fixes BLUETOOTH audio delay. ?

I've been looking for days on end, but I can't seem to find an app that fixes the delay in bluetooth speakers. For example, it would fix the delay for netflix so the sound matches the video.
I think that this delay is all software based, because Chrome and YouTube don't have delay, but most other apps do.
I was thinking, if this hasn't been created yet, which I don't know why because so many people complain about delayed bluetooth speakers, that it can't be that hard to create.
Like for example, just make it so you open the app, and it puts a sort of slider in the notification bar for you to adjust whatever is on the screen to sync with the video.
or maybe have the app open other apps from inside it and work like that? I have very little experience in coding,
So if anyone could explain to me why an app that syncs the screen with the audio doesn't exist, please tell me!
little more details, I'm using the speaker on my new Nexus 7 2013, and I also have a Nexus 4.
the speaker is a Jawbone Jambox. I bought so I could watch Netflix without headphones, but that's the only app the speaker isn't in sync, apart from.. every single game application.
thanks for any replies!

[Q] Using NFC and Bluetooth to voice-activate MP3s in the car

Hi, sorry if this is in the wrong category.
What I want to achieve is:
1. To stream audio (MP3s, calls) from my phone to my car stereo
2. To do this, and other functions of my phone, without taking the phone out of my pocket at all.
I'm going to be buying a Galaxy S5 in the very near future, and also my car stereo is knackered, so I thought now is a good time to shake things up. What I was thinking of was to get a new car stereo that has Bluetooth, and then use an NFC tag stuck on to the seat of my car, and the Trigger app, that when connected will turn on Bluetooth on my phone, and turn on voice commands.
First of all, what can one do with voice commands these days? I currently have a Galaxy S2, and with that one, it's not very much. What I'll want to do is call people, amswer the phone when people call me, write SMS/Whatsapp messages, and have them read out to me, set calendar entries and reminders, play music by going through my music library and reading it out to me.
Is this all possible in Android, or will I need a 3rd party app? To complicate things further, is it possible to replace current commands with other ones, where I would record them into the phone? The reason I ask is because my first language is Welsh. This also means that most my text messages will be in Welsh, so I will need to be able to write them in letter-by-letter, and also have them read out to me letter-by-letter. Possible?
Secondly, what sort of car stereo should I get for this? One with Bluetooth of course, but what other features should I look out for that I might need? Or should I go for a Parrot system?
Any suggestions will be appreciated.
Thanks.

[Q] Sharing audio during a phone call

I have posted it 2 months ago on "apps and software" and got nothing. So I'm trying again here.
Hello everyone!
What I'm looking to do is really simple, a LOT of people are interested in these feature, however, no one has a clear solution.
There has been a lot of post about this subject but they are most old post and there's nothing help full.
Here is the problem - whenever I'm talking over the phone, I can play any music I like and I can hear it perfectly, but the other side cant hear anything! even if ill let the music play using the phone speaker - the other side is silent (witch is strange cause when the speaker play, the mic should transfer the sound and shouldn't "care" who is making it).
So after a lot of searching for apps and different ways, I found out something interesting.. If I make the call using an VOIP (skype, viber and so on) and Ill play music at the same time - THE OTHER SIDE CAN HEAR IT PERFECTLY!!! witch means the phone is fully capable of doing it.
What is going wrong when I'm using the cellular network instead of VOIP? is there a way around it?
Ive noticed some people don't get WHY would I want to do it.. well, I'm working using my phone (sales) and using the exact same pitch. I would like to be super lazy and play a recorded version of me, and when its done, be able to just keep talking to the person without him being able to notice the difference.
Since I'm doing it for work, I cant use VOIP for regular calling.
I'm using Nexus 4, chroma rom (lollipop)
ANY help at all will be appreciated
Something to think about..
Since I didn't found any software to do it (yet), I'm experimenting with a different direction.
I currently use a PC headphones with a simple Y adapter from eBay. So I'm thinking "all I need is another microphone. One for the talking, another to sit between speakers that will play the sound for the caller.
I've gone through eBay again, this is a tough one to find cause I need 'audio input' splitter and most splitters are 'audio output'.
If you guys know something about it, please share.

Categories

Resources