Audio Streaming API's: Wifi vs what? - iphone

I've noticed certain radio apps, that some stations required wifi and others did not. What were those other stations possibly using? Are there other methods of streaming audio on iOS?
Apparently, I was not clear in my question before.
I'm asking in terms of API's. Is there an API to interact directly with say, FM radio, on iOS? Is wifi the only way of streaming audio?

Have a look at HTTP Live Streaming:
https://developer.apple.com/library/content/documentation/NetworkingInternet/Conceptual/StreamingMediaGuide/Introduction/Introduction.html

Related

getting realtime audio stream from voip or sip systems

I am building an application that gets real-time audio from our organization's VoIP system, records the call and transcribe the real-time voice. The transcription then passed to our analytics engine and get the insights.
We are able to transcribe the recorded audio and get the insights from the transcription. We have a solution for real-time transcription also. It will transcribe the voice from the microphone and even an RTSP stream also. We are having trouble finding a solution for getting the real-time audio from SIP/VoIP systems. I read that SIP Trunking and option and also WebRTC is also another option. But I don't know how to and where to start with.
I am experienced in Java and Python, I requesting experts to give me suggestions or examples on how to get the real-time audio stream from a SIP/VoIP conversation.
I am not familiar with SIP/VoIP and never written VoIP application.
A solution that might suit your needs is Oreka, which is the open source version of Orecx, a call recording software for VoIP.
I used it in the past and it works perfectly well with SIP calls that use open audio codecs like g711 (alaw,ulaw) or speex but it may have problems decoding the audio of calls that use the propietary g729 codec (I had to work out my own codecs at that time).
The paid version might support more codecs and protocols like Avaya's H323.
Have in mind that this app works by sniffing the network, so the setup is not trivial. Anyway, I suggest you give it a try.
Link: https://www.orecx.com/open-source/
For anyone out there. if you want to have access to live/realtime audio data from a VoIP call I suggest you use Twilio Streams.
If you're just looking to get realtime transcriptions without access to the actual audio data Twilio and Plivo also provide that.

iPhone RCA APIs for communication with apps

What API are available for communicating between a native device/web app and the devices RCA port, like the way credit card readers (square, paypal etc.) exist for iPhones?
Does anyone know what sound/recording API is used by these readers to encode data as audio?
The card reader plays an audio encoding of the card data, and the app is listening to the audio. So technically it's using audio recording APIs. There's no way to treat the headphone jack like a serial port and read data over it, only audio. If you wish to communicate directly with another device, either it needs to be over bluetooth or thru the dock/lightning connector.

How to simulate a call so that the bluetooth audio get streamed into a vehicle?

The iphone connects to most vehicles via bluetooth. Phone calls as well as voice control and siri also get routed via the bluetooth audio and mic of the vehicle.
How can i stream audio in the same way?
I have sen answers about the vehicle capability to support streaming audio, but this is not what i am looking for. If siri and voice control can stream over the vehicle audio as it is treated as a voice call then i should be able to stream everything else.
Thank you
It sounds like you want to simulate a call originated from your iPhone, as opposed to some other device that pretends to be a phone and pairs with your car. You can’t, because Apple doesn’t provide APIs to do that.
I think that false.
Google did it.
They do it in Google Search. If you search using voice, it streams simulating a call.
Something similar happens with the voice notes application from Apple. You can stream music to the car as if it was a call.
Actually, my car doesn't support A2DP, only calls, and using voice notes I can play music (odd, but works).
But..., how can we implement it???

How Square implemented data transfer to iPhone?

Some days ago I saw a interesting device for iphone, square, here: https://squareup.com/
you can plug it into iphone's earphone socket, and it can transfer data to iphone. A running App on iphone can receive it.
does any one know how it implemented? I guess it can encode data to audio stream and "sing" it, and App on phone can record the sound and decode it. but how to? is there a protocol or SDK?
The implemention is likely to be no different to that of a simple acoustic modem. The relevant APIs include Audio Units (low-level) or Audio Queue Services (higher level).
Matt Gallagher has written an excellent (as always!) post on creating an iOS tone generator, which is one way of enabling what you are after.

Which iPhone API should I be using for streaming audio?

I'm looking to build a little toy app that is very similar to a voip application. One person would hold one iphone and talk to the other iphone. I don't want to use gamekit because it forces a p2p connection and does not work over 3g. I'm worrying about the server side of this later but just wanted to get started with the iPhone side of it. Which API to record audio in real time and which to play it back?
Look to Audio Queue Services for capture and recording. You'd need to come up with a wire protocol to transmit the audio, but the tools to capture and playback or save on either side of the connection can be built using the queue services.