Can TokBox handle multiple microphones - tokbox

I'm trying to connect multiple microphones to my web app.
But I haven't been able to get TokBox to list more than one microphone.
I am using the computer's built-in mike, plus my smartphone's mike as a secondary microphone, via DroidCam.
Can TokBox handle multiple microphones on the same computer?
If possible, can I do this with DroidCam? If not, how can I connect multiple (three) microphones and select them on TokBox?
Thanks.

I dont know that tokbox provides this directly but you could potentially use MultiStreamsMixer
https://github.com/muaz-khan/MultiStreamsMixer
const audioMixer = new MultiStreamsMixer([microphone1, microphone2]);
const mixedStream = audioMixer.getMixedStream();
and then give the tokbox publisher (via setAudioSource) the mixed stream.

Related

Voice call connection routing React-Native

I am trying to build an application which works this way: I as a user want to start a call with another user. The way I want the connection be made is by random. So it will connect to one of the many clients out there by random. Also when other clients try to make a call, it should connect to another random client and so on. I want those phone calls be made via application(such as WhatsApp) not as a phone call.
Now, the question is; is Twilio a good approach for this purpose?
If yes can you tell me which of their feature would fit my app the best?
Thanks for any suggestions!
Twilio developer evangelist here.
I can answer that Twilio would be a good approach for you to do this within your own application. I'd recommend using Twilio Video to build this as it allows cross platform communication via audio or video (in your case, you may not need the video, but this will give you the best audio quality).
As an example, my colleague Dominik built a video roulette application. It is the case that the interface was built in JavaScript for the web, but the idea would be the same for a native app. The code for the server side part of the application should give some insight into how to connect random pairings.
It's also possible to integrate Twilio Video with CallKit and Connection Services so that you can make outbound calls to other devices that ring like a real incoming call.

real time gps tracking device

I am working on a product which requires a real time gps tracking.
I searched on google to collect information, so I got an overview on how does basically GPS work.
Now what else do I need except for a GPS receiver to display on my mobile through an app (designed by us) where a GPS receiver is attached to my product?
I don't want the whole navigation functionality, but just to display where it is located.
I know a GPS receiver continuously sends and receives signals from satellites, but how to display that on my mobile app?
Do we send some info to some kind to a database and then program the app to collect the info from there?
Basically, You need a kind of connection between your receiver and your phone. Since all the phones have their own gps receiver, I assume that you are gonna track the location of a remote device. So the easiest way to do that is creating a basic web service which holds just 2 pages in total.
1 to update data by receiver (I suggest you to use a hash key to prevent bots to piss your database)
1 to get data to mobile app
Depending on your background and project needs you can either use a database to keep location data or you can use just a file (like xml file or something like that)
Also you will need to parse NMEA code to get the actual data. It is easier to do that on web side (like in php). So you can just pass the NMEA code as it is to server, parse it, record it to database/file. Then you can fetch the data from your mobile app by using simple http requests.
If two devices will be close to each other you can easily use bluetooth but I don't know if there is any case that it make sense to place an additional gps receiver just next to a smart phone :)
First of all, you need some kind of communication channel to send location from your product to a server (1) of directly to the phone (2).
Usually GPS tracking devices use GSM modem with GPRS to connection to a remote server. Then your phone app can request location data from server via HTTP API. You can use open source GPS tracking server for your project and use some simple protocol to send location data to it.
Second popular option requires GSM modem again, but in this case device can send SMS messages directly to your phone. In your app you can intercept SMS and retrieve location data.

Is there a way to send multiple wifi camera a signal to take a picture at the same time?

I have 20 wifi cameras that are compatible with the camera remote api (all identical).
Using the API, is it possible to trigger all of them over wifi to take a picture at the same time?
I would basically like to trigger all 20 over wifi and then fetch the pictures from all of them. So any suggestions for how to do that would be appreciated. Mainly just triggering them together would be a great start.
Also, is it possible to send commands to the camera with the API when the camera is connected to a network via the play memories camera app or can commands only be sent via connections with the Smart Remote Control? Reason being, I can have multiple cameras connect to my network this way, but via the smart remote, I can only connect to a single pc to camera at a time as the camera acts like the hot spot instead of the other way around.
Thanks,
-Scott
That would be possible but since it's only possible to connect one camera to one phone at a time, you would need 20 phones as well and then you could send the command to take a picture to all the phones which would in turn trigger the camera connected to each one.
It is not possible to send commands to the camera other than by using the Camera Remote API.
It would appear that some cameras use WPS to make outgoing connections (ie. when using 5 AZ1 with LiveViewRemote)....
If you had such a camera maybe you could connect them all to the same WiFi router, and then use the API to initiate a connection to all at the same time and quickly tell each to take a picture in quick succession.
Here's a link which might help you get there:
https://github.com/Bloodevil/sony_camera_api/issues/8

Can WebRTC help me create a virtual classroom?

I'm trying to create a virtual classroom. Since I'm not familiar with the web conferencing (or conferencing) terminology, I'm not sure if I'm understanding WebRTC's capabilities as I should.
I've looked in the examples for WebRTC, and all that I've found seem to be peer-to-peer connections. As I understand it, peer-to-peer connections are between two entities. However, virtual classrooms are different as far as I know; they require all parties to be connected to each other, so that when one user speaks/types, all users hear her.
Is such a thing possible with WebRTC? If so, what is it called and how can I read more about it?
Check out the open source Big Blue Button project (http://bigbluebutton.org/). They're currently Flash based but are actively moving towards webRTC. Rumor has it they'll be using Kurento as their MCU. They also have open source mobile (Android/iOS) application code.
According to http://www.html5rocks.com/en/tutorials/webrtc/infrastructure/, such a thing is possible:
Beyond one-to-one: multi-party WebRTC
You may also want to take a look at Justin Uberti's proposed IETF standard for
a REST API for access to TURN Services.
It's easy to imagine use cases for media streaming that go beyond a simple
one-to-one call: for example, video conferencing between a group of colleagues,
or a public event with one speaker and hundreds (or millions) of viewers.
A WebRTC app can use multiple RTCPeerConnections so to that every endpoint
connects to every other endpoint in a mesh configuration. This is the approach
taken by apps such as talky.io, and works remarkably well for a small handful
of peers. Beyond that, processing and bandwidth consumption becomes excessive,
especially for mobile clients.
Maybe you can try searching in the webrtc google group
hope this helps

Multiplayer game using UDP: How do the players get to know each other?

I'm making a multiplayer mode for my game and I decided to use UDP.
Since all the data is sent p2p, between the players, I have no server.
But how do the players get to know each other in first place?
Do I need a server dedicated to do this job or is there any other way?
Thanks.
There's several ways you can do this.
You could use a server dedicated to it.
You could let users enter in an IP address for another player.
You could use something like Bonjour.
Most networked multiplayer games use some form of service for listing players, and I can't think of many examples where it would be advisable to not use a server for this. Keep in mind that it doesn't have to be a dedicated server, you can simply have one of the clients play a server role for the listing, even if this is the only server type behavior needed by the game. This way each player will only have to know the one IP, and there's even ways around that if it's LAN play.