From: Mark Slagell Newsgroups: comp.os.msdos.djgpp Subject: Why can't I get rawclock() to work? Date: Thu, 15 May 1997 22:23:08 -0500 Organization: dept. of redundancy dept. Lines: 23 Message-ID: <337BD31C.2838@ames.net> NNTP-Posting-Host: dial50.ppp.iastate.edu Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Precedence: bulk It's no big deal, the following code shows the workaround I'm using, but I still don't know why rawclock() always returns zero. What am I doing wrong? ------------------- #include #include #include main() { __dpmi_regs r; unsigned long t; printf("rawclock(): %d\n",rawclock() ); // Always returns 0; why? r.x.ax = 0; __dpmi_int( 0x1a, &r ); t = r.x.cx << 16 | r.x.dx; printf("ticks via BIOS: %d\n", t ); // This works fine }