returnValue = False
oldError = win32api.SetErrorMode(1)
try:
    freeSpace = win32file.GetDiskFreeSpaceEx(letter)
except:
    returnValue = False
else:
    returnValue = True
win32api.SetErrorMode(oldError)
return returnValue
How do I check if a disk is in a drive using python?