From: Richard Dawe Newsgroups: comp.os.msdos.djgpp Subject: Re: Async COM managing Date: Sat, 06 Jan 2001 16:11:36 +0000 Organization: Customer of Energis Squared Lines: 31 Message-ID: <3A5743B8.B569950A@phekda.freeserve.co.uk> References: <9250eb$a84$00$1 AT news DOT t-online DOT com> <557-Fri05Jan2001203419+0200-eliz AT is DOT elta DOT co DOT il> <936lkf$7mj$01$1 AT news DOT t-online DOT com> <6137-Sat06Jan2001145950+0200-eliz AT is DOT elta DOT co DOT il> <937csu$pst$06$1 AT news DOT t-online DOT com> NNTP-Posting-Host: modem-63.carbon.dialup.pol.co.uk Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: newsg4.svr.pol.co.uk 978797749 31262 62.136.5.63 (6 Jan 2001 16:15:49 GMT) NNTP-Posting-Date: 6 Jan 2001 16:15:49 GMT X-Complaints-To: abuse AT theplanet DOT net X-Mailer: Mozilla 4.51 [en] (X11; I; Linux 2.2.17 i586) X-Accept-Language: de,fr To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com Hello. Peter Remmers wrote: > The documentation is terse. But the PM-API is basically just a wrapper > for the VXD-to-VXD interface of VCOMM, which is documented better. > Constants can be looked up in the header files, ans structures are > declared there, too. Having the header files is quite helpful. Having some DDK documentation and header files is even better. ;) > What I don't understand is why pointers are passed as 16:16 and not > 16:32? Could that mean buffers have to reside in low DOS memory? The following is based on my experience of interfacing with WSOCK.VXD and WSOCK2.VXD. When using the protected mode entry point of WSOCK[2].VXD, you pass in a selector:offset pair rather than a segment:offset pair. The VxD will map the address you pass in to a flat address, using the virtual machine ID and the selector:offset pair. I guess the 16:16 is a limitation from Windows's old days. Changing the interface of VCOMM from expecting 16:16 to 16:32 would break a lot of things, I guess. You can use __dpmi_allocate_memory() to allocate a chunk of memory and get its selector. You may want to look at the libsocket code to see what it does - see src/wsock/w_initnt.c. Bye, Rich =] -- Richard Dawe [ mailto:richdawe AT bigfoot DOT com | http://www.bigfoot.com/~richdawe/ ]