[BangPypers] Hi.......

2010-01-13 Thread Smrutilekha Swain
i am doing a programme in which i have to copy a file from one directory to anotheri have used "shutil.copy(src,dest)"...but it is showing error i.e., permission denied...as file is in 'w' mode...so plzz tell me what to do. thanks in advance. smruti __

Re: [BangPypers] Hi.......

2010-01-13 Thread steve
Hi, On 01/13/2010 02:15 PM, Smrutilekha Swain wrote: i am doing a programme in which i have to copy a file from one directory to anotheri have used "shutil.copy(src,dest)"...but it is showing error i.e., permission denied...as file is in 'w' mode...so plzz tell me what to do. A

Re: [BangPypers] Tuples vs Lists, perfromance difference

2010-01-13 Thread Vishal
> > > Here is more real example. > > >>> def square(x): y = x*x; return y > ... > >>> import dis > >>> dis.dis(square) > 1 0 LOAD_FAST0 (x) > 3 LOAD_FAST0 (x) > 6 BINARY_MULTIPLY > 7 STORE_FAST 1 (y) >

[BangPypers] Python and USB

2010-01-13 Thread Vishal
Hi, I am looking for a way to create a python library that talks to some usb devices (such as usb-i2c cards etc). There is a requirement that the python library should be usable directly under windows and linux withough requiring the user to worry about her platform. Any pointers? I did find a c

Re: [BangPypers] Python and USB

2010-01-13 Thread Anand Balachandran Pillai
On Wed, Jan 13, 2010 at 2:56 PM, Vishal wrote: > Hi, > > I am looking for a way to create a python library that talks to some usb > devices (such as usb-i2c cards etc). There is a requirement that the python > library should be usable directly under windows and linux withough > requiring > the us

Re: [BangPypers] Python and USB

2010-01-13 Thread steve
On 01/13/2010 03:01 PM, Anand Balachandran Pillai wrote: On Wed, Jan 13, 2010 at 2:56 PM, Vishal wrote: Hi, I am looking for a way to create a python library that talks to some usb devices (such as usb-i2c cards etc). There is a requirement that the python library should be usable directl

Re: [BangPypers] Python and USB

2010-01-13 Thread Vishal
On Wed, Jan 13, 2010 at 3:01 PM, Anand Balachandran Pillai < abpil...@gmail.com> wrote: > On Wed, Jan 13, 2010 at 2:56 PM, Vishal wrote: > > > Hi, > > > > I am looking for a way to create a python library that talks to some usb > > devices (such as usb-i2c cards etc). There is a requirement that

Re: [BangPypers] Python and USB

2010-01-13 Thread Anand Balachandran Pillai
On Wed, Jan 13, 2010 at 3:09 PM, Vishal wrote: > On Wed, Jan 13, 2010 at 3:01 PM, Anand Balachandran Pillai < > abpil...@gmail.com> wrote: > > > On Wed, Jan 13, 2010 at 2:56 PM, Vishal wrote: > > > > > Hi, > > > > > > I am looking for a way to create a python library that talks to some > usb > >

Re: [BangPypers] Python and USB

2010-01-13 Thread Vishal
On Wed, Jan 13, 2010 at 3:13 PM, Anand Balachandran Pillai < abpil...@gmail.com> wrote: > On Wed, Jan 13, 2010 at 3:09 PM, Vishal wrote: > > > On Wed, Jan 13, 2010 at 3:01 PM, Anand Balachandran Pillai < > > abpil...@gmail.com> wrote: > > > > > On Wed, Jan 13, 2010 at 2:56 PM, Vishal wrote: > >

[BangPypers] Power management/consumption control module

2010-01-13 Thread Anirudh Asokan
Hey ter! Is there any python module that collects the power consumption details of computer components? or bios related things like fan speed, cpu frequency, overall power consumption of computer? If not python, what are other ways to go about it? Waiting eagerly for your answers (will be checkin

Re: [BangPypers] Power management/consumption control module

2010-01-13 Thread Amit Saha
Hello: Anirudh Asokan wrote: Hey ter! Is there any python module that collects the power consumption details of computer components? or bios related things like fan speed, cpu frequency, overall power consumption of computer? If not python, what are other ways to go about it? Not sure about p

Re: [BangPypers] Power management/consumption control module

2010-01-13 Thread Deepak Mishra
Hello, Amit is right, there should not be any cross platform way to do that because python itself does not have any such modules. Third party libraries will have to depend on the OS specific implementation. For eg in Linux open ("/proc/acpi/thermal_zone/TZ01/temperature").readline() should read