During a call, if I am not actively speaking into the microphone, it appears as if there are no audio packets being sent. This is causing problems because I am tring to mix audio at the server level. It appears to be some kind of echo cancellation in the pjsip stack. Does anybody know if there is a way to shut this off?
I have tested with Zoiper and I have isolated the problem to this sdk. Thanks!
This is usually not because of AEC. You should look for something called "VAD" (Voice Activity Detection). If you find it try to change its setting or disable it.
Related
I keep running into a strange issue when running AKMIDI on IOS. I also think it may be an IOS problem and not necessarily from Audiokit. I can connect a MIDI controller to IPad and receive messages as expected using the MIDI listener protocol after I open the input. If I disconnect the MIDI controller by cycling the power or unplugging it from the IPad and then reconnect it, I then start receiving two identical messages at each event. If I cycle the power again I start getting three messages, etc. I should also mention that when I detect the device is removed I close the input and clear the listeners. When I detect the new connection I open the input and start over. Does anyone know what can cause this to happen?
I think I have found a workaround for this:
If I only open the midi in and midi out one time, when my device is first detected, it seems to work correctly. I now only close the in and out when the app is terminated. You can cycle the power on the midi controller and it will still communicate with the app when it reconnects. I am also now using the more generic calls openInput(), addListener(self), openOutput().
NOTE: This app I am working on is completely for my own usage and will not be on app store so please don't give answers referring that.
I want my app to do some process in background or after termination (double tap the home button and swipe the app from applications multitask) every few minutes. The process is very very light and quick so it won't drain the battery. This process shouldn't require internet connection. I have seen some answers here like and I will explain what are the problems:
VoIP. The problem with VoIP is wither it should be in background to use UIApplication.sharedApplication().setKeepAliveTimeout(..) method which doesn't work when the app is terminated or it should be connected to the internet to establish tcp connection and receive commands from sever and as mentioned before I want it to be internet independent.
Location Services. I found this excellent site with some great articles but the problem is it only works when the mobile phone is moved more than 500 meters. It depends on the location movement so when the phone is staying somewhere there will be no code execution.
Playing an silent audio loop. The problem here is if the user plays another audio (which is completely possible like music or phone call) the app will terminate!
Jailbreak Launch Daemons. I can't require jailbreak so it should be solved with a non-jailbreak solution:(.
I am free to use any kind of private-API's and there will be no restriction for that.
Thanks in advanced
I also faced with such problem, and don't find any solution.
The main problem is if user manually terminated app - in this case you can't do nothing...
Only way is:
a) use Location Services (as you mention)
b) use Push Notifications with background fetch
I am developing a VoIP app using Twilio for iOS. The app should be able to receive incoming connections. For that, I have checked the VoIP and Sound capabilities so that the app keeps running and listening for ports.
To achieve this, I have initialized a TCDevice in my appDelegate and set the appDelegate to be the TCDeviceDelegate so that the system keep listening for new connections. But the app will eventually go into background, or even be terminated at some point. So what should I do at this point?
Is this the correct way for keeping the app listening even when in background? I have been reading that I need to use a setKeepAliveTimeout in my didEnterBackground method, but Apple says when using iOS8+ , we should be registering for Remote Notifications instead.
Also, I am reading the Apple documentations, and they say that sockets should be tagged properly for the system to keep these sockets alive. Does Twilio's library take care of these details?
I am very confused about the whole process. Does Twilio take care of everything? if so, how?
The Twilio SDK calls the setKeepAliveTimeout for you so you don't need to call that or worry about the sockets. All you need to do is add the two background settings to your info.plist for Playback of Audio and VOIP.
The Twilio online documentation is not that great, however if you download the iOS SDK and untar it you will find a FAQ which is NOT online that explains more. You will also find a BasicPhone Xcode project that is way more fleshed out than the Monkey project.
Also I found that unless you cough up some money then none of the calls will actually go through.
If you encounter any problems then the Twilio email support is great for the first 48 hours of each issue and then they tend to go silent. YMMV.
All of this is information I could have done with 2 months ago, hope it helps.
I have the following problem with GKSessions:
Sometimes there is a huge delay when sending data (3-4 seconds sometimes up to 10 seconds) in a client/server application.
If the server sends let's say 10 packets during the delay, those 10 packets are received all at once on the client. The weird thing is that the server still receives packets from the clients during the delay.
This delay seems to be worse in WiFi networks but also happens in bluetooth networks.
Did anyone else encounter such delay spikes when using gamekit?
What could be the source of this issue?
I've been working a lot with gamekit and gksession. I always use the Peer2Peer mode even though some people discourage it. I never experience any kind of delay like the one you describe.
Do you send with GKSendDataReliable or GKSendDataUnreliable? Try switching to the other and see if it changes anything. If you're using GKSendDataReliable then the sending device will wait for a "Received" message from the receiver before sending the next message. This might be the problem.
On your testing devices: Is anything running which might flood the network?
I was testing a multiplayer gamekit based game, and if I had several active devices then suddenly some would stall completely, and I needed to hard reboot (shut down completely and restart) them to make them work again.
If you keep getting in trouble you might want to try a much more low level api: dns-sd https://developer.apple.com/library/mac/#documentation/Networking/Conceptual/dns_discovery_api/Introduction.html
I hope you make it work, good luck!
I have a Application on a PC which displays time-information for a mp3 song that is played. I now need to display this time information within an iPad App. The counting timers for remaining time, player position and song length must be in sync between iPad an PC.
I thought about using a socket connection (AsyncSocket on iPad) to keep the counters in sync.
Is there a better way doing this? I don't want to run in the wrong direction...
Additional, it should be possible to have more than one iPad showing the Information in future. That's a "nice to have" feature...
I don't need ready to use code snippets, it's more a theoretical question. (if someone has a ready to use code snippet, that's also good for me :-) )
MadMaxApp
i now used the AsyncSocket to solve the requirements. It works perfectly. Don't forget the handling of closing the socket connection if the app goes in background. Depending on the server the app is talking with, not closing the socket can lead to a problem in reconnecting.