damian
asked on
how to code a DPMI call
I need some code about makeing a DPMI 0x0300 call in order
to make a disk read with int13h under WIN 3.1 platform
I tried to use the documentation and it doesn't work at all.
Thanx
Damian Ionut
to make a disk read with int13h under WIN 3.1 platform
I tried to use the documentation and it doesn't work at all.
Thanx
Damian Ionut
Please, explain what's your steps ?
Please, explain what's your steps ?
ASKER
I need exactly the C coded function like:
MakeInt13hRead(void far *buffer,int sect,int track,int side);
and
MakeInt13hWrite(...)
I allready implemented a general int 13h call function but it doesn't work at all. Maybe it could be a problem with the "void far *buffer" param wich is WINDOWS memory alloc chunk (alocated with DELPHI's new(buffer)
function call, lets say, or with Alloc and Fix etc. ) ... Any further information
nedeed ?? ;)
See ya !
Slash
MakeInt13hRead(void far *buffer,int sect,int track,int side);
and
MakeInt13hWrite(...)
I allready implemented a general int 13h call function but it doesn't work at all. Maybe it could be a problem with the "void far *buffer" param wich is WINDOWS memory alloc chunk (alocated with DELPHI's new(buffer)
function call, lets say, or with Alloc and Fix etc. ) ... Any further information
nedeed ?? ;)
See ya !
Slash
For 16 bit applications the DPMI host automatically handles all
INT nn opcodes to provide BIOS and DOS services transparently.
So you have not the reasons to simulate real mode interrupt.
For checking it I included to my C program following code for reading sector from diskette and it runs OK:
__asm mov ah,02h
__asm mov al,01h
__asm mov ch,00h
__asm mov cl,01h
__asm mov dl,00h
__asm mov dh,01h
__asm mov bx,seg wrkbuf
__asm mov es,bx
__asm mov bx,offset wrkbuf
__asm int 13h
__asm mov errcode,ah
According to documentation,Win32 applications cannot communicate with VxDs by the same means that 16-bit can (software interrupts, callbacks, VxD services, etc.) Win32 applications must use
DeviceIOControl interface to communicate with VxDs that support
device I/O calls.
INT nn opcodes to provide BIOS and DOS services transparently.
So you have not the reasons to simulate real mode interrupt.
For checking it I included to my C program following code for reading sector from diskette and it runs OK:
__asm mov ah,02h
__asm mov al,01h
__asm mov ch,00h
__asm mov cl,01h
__asm mov dl,00h
__asm mov dh,01h
__asm mov bx,seg wrkbuf
__asm mov es,bx
__asm mov bx,offset wrkbuf
__asm int 13h
__asm mov errcode,ah
According to documentation,Win32 applications cannot communicate with VxDs by the same means that 16-bit can (software interrupts, callbacks, VxD services, etc.) Win32 applications must use
DeviceIOControl interface to communicate with VxDs that support
device I/O calls.
ASKER
I think you have not tested it ... ;)
I have done it allready ...
Saa ya !
I have done it allready ...
Saa ya !
I tested it on QuickC for Windows v.1.0. I could see that diskette drive started work, wrkbuf was filled some information, but I didn't check this information, becouse you sad INT 13h didn't work at all. Of course, I can check it too, but I think
it's not necessary, it's run OK. But if you have done it allready and my code didn't run on your hardware too, you should see the Diskette Parameter Table using INT 1Eh or you can get this address from BIOS directly at 0:0078 If you will have troubles
in this cause too, just E-mail me, I will try to help you :-).
it's not necessary, it's run OK. But if you have done it allready and my code didn't run on your hardware too, you should see the Diskette Parameter Table using INT 1Eh or you can get this address from BIOS directly at 0:0078 If you will have troubles
in this cause too, just E-mail me, I will try to help you :-).
I have a vested interest in the area that you have asked about. My angle is that I am currently writing a Windows 3.1 utility program to copy diskettes. This requires the use of int13 subfunctions 2,3,4,5, and 0 naturally. I cannot even help you unless I know what angle you are coming from. Specifically, what subfunctions are you interested in? and what are your problems with them? I have had a lot of problems myself and am working around them one by one. If you would like to work with me if possible. I know a little about DPMI. Myb e-mail is:
mchalej@iol.ie
mchalej@iol.ie
Ok guiz!
Thanx a lot for help, but I found the code on MSDN CD. It is not that easy as it seems.
BTW, with FDD is more easy than HDD... you can use a lot of other functions ...
PS: If you need this code, I'll be glad to share it with you !
See ya
Thanx a lot for help, but I found the code on MSDN CD. It is not that easy as it seems.
BTW, with FDD is more easy than HDD... you can use a lot of other functions ...
PS: If you need this code, I'll be glad to share it with you !
See ya
Sample code for FDD\Win16
Yes please slash.
mchalej@iol.ie
Thanxx.
Yes please slash.
mchalej@iol.ie
Thanxx.
I'll send you by e-mail ....
BTW ... send me your datas at slash@buc.soros.ro and I'll reply you with the code !!!
See ya !
BTW ... send me your datas at slash@buc.soros.ro and I'll reply you with the code !!!
See ya !
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.