This is the mail archive of the
cygwin@sourceware.cygnus.com
mailing list for the Cygwin project.
Re: questions about port and timer functions
- To: gnu-win32 at cygnus dot com
- Subject: Re: questions about port and timer functions
- From: Benjamin Riefenstahl <benny at crocodial dot de>
- Date: Fri, 16 Jan 1998 11:56:11 +0100
- Organization: Crocodial Communications EntwicklungsGmbH
- References: <B6390D1C83@rz-nov4.rz.fh-weingarten.de>
Hi Armin,
herzer@rz-nov5.rz.fh-weingarten.de wrote:
> I have written a data acquisation program with DJGPP. Now I want to
> port it to Windows NT and give him a fancy outfit (with Tcl/TK). But
> yesterday in the evening these questions appeared:
>
> 1. How can I do port I/O with gnu-win32 (like in-, outportb in
> DJGPP).
You can not use the hardware ports in a WinNT 32 bit program. You can do
it in Win95, but there are no guarantees that this will work in future
versions. You're supposed to write device drivers for this, or use
existing facilities like the serial ports.
> I didn't find any include file which contains a definition
> for these functions. What libraries do I need?
You would probably have to write them yourself in inline assembly.
> 2. Is there a function which returns a time signal with precision of
> 0.001 s or better?
Look at the Win32 multimedia timers. They are the only thing that
actually comes near that precision. The standard Win32 functions like
GetSystemTime() have the resolution but not the actual granularity.
so long, benny
======================================
Benjamin Riefenstahl (benny@crocodial.de)
Crocodial Communications EntwicklungsGmbH
Ophagen 16a, D-20257 Hamburg, Germany
-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".