View Single Post
Old 06-27-2008, 10:13 AM   #41
kovidgoyal
creator of calibre
kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.kovidgoyal ought to be getting tired of karma fortunes by now.
 
kovidgoyal's Avatar
 
Posts: 45,697
Karma: 28549304
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
Hmm, possibly. Try the following

Code:
import wmi, pythoncom
pythoncom.CoInitialize()
_wmi = wmi.WMI()
from calibre.devices.scanner import DeviceScanner
scanner = DeviceScanner(_wmi)
scanner.scan()
from calibre.devices import devices
for d in devices():
        if scanner.is_device_connected(d):
            dev = d(log_packets=options.log_packets)

dev.open()
print dev._main_prefix, dev._card_prefix
Is the final line of output showing the wrong drive for card_prefix?
kovidgoyal is offline   Reply With Quote