My bad. I should use 'Q' instead of 'LL'. Thank you Tim!
Jane
Jane Chen wrote:
> Hi all,
> I would like to get total sector number of my disk. However, I found that I
> cannot get 8G sectors because of the buffer size.
> I only g
Hi all,
I would like to get total sector number of my disk. However, I found that I
cannot get 8G sectors because of the buffer size.
I only got 4G.
buf_fmt='LL' buf_size=struct.calcsize(buf_fmt)
buf=win32file.DeviceIoControl(h, winioctlcon.IOCTL_DISK_GET_LENGTH_INFO, None,
buf_size, None)
Cou
Cool. Thank you Tim!
Jane Chen wrote:
> Thank you for your help, Roger and Tim!
>
> Problem solved. I realized that I can simplify my problem by
> using win32file.ReadFile()to create a bin file.
You don't even need to go that far. There's nothing you can do with
win32
Thank you for your help, Roger and Tim!
Problem solved. I realized that I can simplify my problem by
using win32file.ReadFile()to create a bin file.
Thank you,
Jane
---
There's a FileStream class in \win32com\server\util.py that
creates an IStream connected to a
Hi all,
I would like to create disk image through SHCreateStreamOnFileEx,IStream::Read,
and IStream::Write. However, I cannot find these API in python-win32. I am
wondering how to create disk image through python.
Thank you,
Jane___
python-win32 maili
SD card?
Thank you,
Jane
Jane Chen wrote:
> Thank you for your help! No luck so far.
>
> I wrote a C program and got the same results as python:
Support for this ioctl is sporadic. It may simply be that your SD drive
doesn't support it.
> Win 7 Notebook (with SD card inserted
tf("Failed to get ProtocolGUID, err code: %d",dwErr);
}
else{
printf("%s \n", pCmdBuf->ProtocolGUID);
}
delete [] pCmdBuf;
return 0;
}
Thank you,
Jane
Jane Chen wrote:
> Sorry. It's a mistake. However, I still get the same error message.
> Maybe t
}
else{
printf("%s \n", pCmdBuf->ProtocolGUID);
}
delete [] pCmdBuf;
return 0;
}
Thank you,
Jane
Jane Chen wrote:
> Sorry. It's a mistake. However, I still get the same error message.
> Maybe there is another mistake. :(
> Is there any tool for debugging
Sorry. It's a mistake. However, I still get the same error message. Maybe there
is another mistake. :(
Is there any tool for debugging purpose?
Thank you,
Jane
> drive=".\\"+drive+'.'
Why are you adding a dot? That's a mistake. You want just ".\\E:"
. Remove the
I want my script to tell if the removable disk is an SD card or not, so I wrote
the following script.
buf_fmt='HH'
buf_size=struct.calcsize(buf_fmt)
drives = (drive for drive in win32api.GetLogicalDriveStrings ().split
("\\\000") if drive)
for drive in drives:
if win32
Jane Chen wrote:
>
> Thank you for your help. However, I still got pywintypes.error: (50,
> "DeviceIoControl", "The request is not supported").
>
> I added the following codes to winioctlcon.py <http://winioctlcon.py/>.
You should not probably modify t
Thank you for your help. However, I still got pywintypes.error: (50,
"DeviceIoControl", "The request is not supported").
I added the following codes to winioctlcon.py.
IOCTL_SFFDISK_QUERY_DEVICE_PROTOCOL = CTL_CODE( FILE_DEVICE_DISK, 0x7a0, METHOD_BUFFERED, FILE_ANY_ACCESS)
GUID_SFF_PROTOCO
Hi All,
Does pywin32 support SD card operation (IOCTL_SFFDISK_QUERY_DEVICE_PROTOCOL)?
I google IOCTL_SFFDISK_QUERY_DEVICE_PROTOCOL with Python. However, no useful
information shows up.
My code:
if win32file.DeviceIoControl(hVol,
winioctlcon.IOCTL_SFFDISK_QUERY_DEVICE_PROTOCOL, 0, 6, 0):
Er
-packages\win32\ lib, and
xx\python\lib\site-packages\Pythonwin.
Regards,
Jane
From: Mark Hammond
To: Jane Chen
Cc: "python-win32@python.org"
Sent: Thursday, July 12, 2012 6:39 PM
Subject: Re: [python-win32] ImportError: DLL load failed
On 13/07/201
Hi all,
I would like to add python win32 to Portable Python distribution with PyGTK for
Windows http://fnch.users.sourceforge.net/portablepygtkwindows.html
I installed the pywin32 in the python\Lib\site-packages folder. PC #1 can find
win32api.pyd. After that, I copied the whole portable python
15 matches
Mail list logo