CD Insert Notification in WinXP
Tim Golden
tim.golden at viacom-outdoor.co.uk
Wed Jan 21 04:49:19 EST 2004
>Hi,
>
>I'm using Python 2.3 on a Win XP box, and I'm trying to find
>if there's
>a library of some sort that will give you a callback (or something
>comparable) when a new disc is inserted into a CD Rom drive.
>I've done a
>little googling and nothing's come up, so I'm not holding my breath. :)
>
Initial response, prior to further investigation: use PyGame
(http://pygame.org).
It's quite lightweight and gives you a lot of control. It doesn't, as far as
I
know, give you a call back, but its CD object gives you an is_empty
function
which you could poll as and when. Check out
http://pygame.org/docs/ref/CD.html
Don't be put off by the "gamey" nature of the toolkit. I've used it here
for several apps, because of the degree of control it gives. I haven't
used the CD lib, admittedly, except to play around with, but you can
import what you need and leave the rest.
TJG
________________________________________________________________________
This e-mail has been scanned for all viruses by Star Internet. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk
________________________________________________________________________
More information about the Python-list
mailing list