Accessing system resources

Reply

Join Date: Jul 2009
Posts: 2
Reputation: asim.mittal is an unknown quantity at this point 
Solved Threads: 0
asim.mittal asim.mittal is offline Offline
Newbie Poster

Accessing system resources

 
0
  #1
Jul 5th, 2009
Hey

I use both windows vista and Ubuntu (mostly) for developing small py scripts. I wanted to know if there were any libraries or modules available to get information about system resources like :
- Source of power (ac or battery)
- how much battery time is left
- Is there any network activity
- how much CPU / Memory is being used

Basically all the things that Task Manager(windows) or System Monitor(linux) would do for you. I wanna do this using a PY script. (or if there is a way to do it at the linux shell)

Any info would be greatly appreciated.

Thanks,
Asim
Reply With Quote Quick reply to this message  
Join Date: Aug 2005
Posts: 46
Reputation: xav.vijay is an unknown quantity at this point 
Solved Threads: 6
xav.vijay's Avatar
xav.vijay xav.vijay is offline Offline
Light Poster

Re: Accessing system resources

 
0
  #2
Jul 7th, 2009
For windows look for WMI scripting queries that would fetch you the required info. You can use the same in the python. The Microsoft site has plenty of details on that.

For Ubuntu, you will have to look for the file which stores that info. It could be in /proc.

A google search for "Ubuntu + battery" gave me something called

acpi -V
Hope this helps...
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:



Similar Threads
Other Threads in the Python Forum
Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC