Hi all...
I'm trying to read some WLAN statistics from my application. These
stats are located in /sys/devices/virtual/net/eth0/statistics
(tx_packets and rx_packets) and in /sys/devices/virtual/net/eth0/
wireless (retries).
I've no problem to read the tx_packets and rx_packets. However I'm not
able to read the retries file, a value of 0 is always given.
The behavior is quite strange, since if I run adb shell and cat the
content of the retries ("cat retries") in superuser mode, I can read
the value without problems and it is automatically read also by the
application. Hoever, if I stop doing this cat in the terminal, the
aplpication maintains the last value and can not update it anymore.
I've tried to read the file using cat and inputstreams but it does not
work neither... I've also tried to change the file rights in runtime,
but it does not work.
The code I'm using to read it is:
int retries =
Integer.parseInt(readBytes(ConfigurationManager.RETRIES_FILE));
readBytes() simply opens the file using RandomAccessFile and
readLine()
Do you have any suggestion to access this retries file ??
Thank you in advance and nice weekend!
GERMAN
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en