Code example for WifiInfo

Methods: getRssi, toString

0
	    return dateFormat.format(date);
    } 
     
    public void updateWifiDetails(){ 
        WifiInfo info = wifi.getConnectionInfo();
        String sInfo = info.toString();
        rssi = info.getRssi();
        int pos = sInfo.indexOf("Supplicant");
        tvWifiDetails.setText("  " + sInfo.substring(0,pos) +"\n  " + sInfo.substring(pos));
    } 
     
    public void addEventHistory(String history) {
    	//TODO: Add time  
    	tvEvent.append(history+"\n");
    } 
     
     
    //Listeners 
    OnClickListener mScanListener = new OnClickListener() {
        public void onClick(View v) { 
            addEventHistory("Starting Scan");