Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Best way to evaluate connection speed

I'm developing an app which needs to get music file by streaming for playing live.

In the request song api I can specify the bandwith (eg: 50kbps, 100kbps, 300, 600 or 1 Mbps).

The more the bandwith is big, the more the file will get time to be fetched. As I don't want the users to be restricted about that I have multiple choices to deal with it:

  • Detect wether the phone is using 3g, wifi or Edge and specify an bandwith for each connection speed.

  • Let the user decide the quality of the song he will get: like youtube (but the users won't be people that know much about computing: the more easy is the software, the more it will fit)

  • Having a way to evaluate properly the connection speed: Like fetching a file, measure the time that it took and set the bandwith.

I know that connection speed could vary a lot if user loose the wifi, or is using 3g moving in the street. And the thing is that I can't change the bandwidth when the song will be playing.

Maybe you have experience about that you would like to share?

Thank you!

like image 782
GrandMarquis Avatar asked Sep 26 '11 12:09

GrandMarquis


People also ask

What is the most accurate way to test internet speed?

Speedtest.net is probably the most well-known speed test. It's fast, free, and has available to it a huge list of worldwide test locations, making for more accurate results than average.

How do you evaluate internet speed?

Some of the more popular speed test services include Speedtest.net, Fast.com or CloudFlare. Whether you install an app or use a website, it's a good idea to run the test a few times to get a sense of your connection's performance.

How do I know if my connection speed is good?

A good download speed is at least 100 Mbps, and a good upload speed is at least 10 Mbps. With 100 Mbps, you can watch Netflix or YouTube, attend Zoom meetings, and play most online games on several devices at the same time. Some people can get away with fewer Mbps, and others need more.


1 Answers

Facebook released a library for this:

https://github.com/facebook/network-connection-class

this wasn't existing in 2011..

like image 137
GrandMarquis Avatar answered Sep 28 '22 09:09

GrandMarquis