www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/09/18/09:31:14

From: Mark Slagell <bald_soprano AT nospam DOT usa DOT net>
Newsgroups: comp.os.msdos.djgpp
Subject: mouse reset & logitech
Date: Wed, 17 Sep 1997 19:48:51 -0500
Organization: the well-basically society
Lines: 34
Message-ID: <34207A73.7DE7@nospam.usa.net>
NNTP-Posting-Host: dial22.ppp.iastate.edu
Mime-Version: 1.0
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

The following, I am told, fails to recognize a Logitech mouse driver. 
Does Logitech require some special test, or does somebody see a problem
with this code?  It does reliably detect a Microsoft driver.

There is no libc mouse support, right?

thanks -- Mark



void mouse_reset() {
__dpmi_regs r;
int result;
  r.x.ax = 0;
  __dpmi_int( 0x33, &r );
  result = r.x.ax;

  r.x.ax = 3; __dpmi_int( 0x33, &r );
  mxc = r.x.cx;  /* mxc & myc are globals that store the */
  myc = r.x.dx;  /* pointer's reset (center) position    */

  if( !result ) {
    printf("  No mouse driver detected.\n";
    exit(1);
  }
}



-- 
"There is no theory.  You have merely to listen.  Fantasy is the law." 
  -- Claude Debussey

Remove the ".nospam" to reply by email.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019