If you need to find the network speed you need to follow the below link :
http://www.gregbugaj.com/?p=47
What it does is simply you hit a url that gives you a text file and based on file size and time to download the file you can judge the exact n/w speed.
Also if you just want to check the quality of network you can use the following code :
ConnectionQuality networkQuality = ConnectionClassManager.getInstance().getCurrentBandwidthQuality();
This will return the ConnectionQuality enum that has the following values:
public enum ConnectionQuality {
/**
* Bandwidth under 50 kbps.
*/
WORST,
/**
* Bandwidth under 150 kbps.
*/
POOR,
/**
* Bandwidth between 150 and 550 kbps.
*/
MODERATE,
/**
* Bandwidth between 550 and 2000 kbps.
*/
GOOD,
/**
* EXCELLENT - Bandwidth over 2000 kbps.
*/
EXCELLENT,
/**
* Placeholder for unknown bandwidth. This is the initial value and will stay at this value
* if a bandwidth cannot be accurately found.
*/
UNKNOWN
}
Hope this helps..