#!/bin/bash
export DEV=wlan0
L=0;
NL=0; 
while true; do 
	N=`grep $DEV /proc/net/dev | awk '{print $9}'`
	echo -ne '\rUt: '$(( ( $N - $L) / 1024)) 'KB/s ';
	L=$N 
	NN=$(grep $DEV /proc/net/dev | sed 's/^ *//' | cut -f1 -d' '|sed s/$DEV://)
	echo -n 'Inn: ' $(( ( $NN - $NL ) /1024)) 'KB/s            ';
	NL=$NN ; 
	sleep 1; 
done
