From mboxrd@z Thu Jan 1 00:00:00 1970 Message-ID: <750545e9ff482cda1c6398ed30c189cb@plan9.bell-labs.com> From: David Presotto To: 9fans@cse.psu.edu Subject: Re: [9fans] Re: random moving of cursor arrow In-Reply-To: <20030726095940.GA2481@ratsnest.hole> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="upas-titjqyumprlozisqniabzunwkx" Date: Thu, 7 Aug 2003 09:52:46 -0400 Topicbox-Message-UUID: 164f737a-eacc-11e9-9e20-41e7f4b1d025 This is a multi-part message in MIME format. --upas-titjqyumprlozisqniabzunwkx Content-Disposition: inline Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit I'm adding the serial intellimouse support. What mousectl were you using to set it? Right now serial port# - sets up a normal (?) serial mouse serial port# M - sets up a microsoft serial mouse I could add serial port# MI - for a microsoft serial intellimouse --upas-titjqyumprlozisqniabzunwkx Content-Type: message/rfc822 Content-Disposition: inline Received: from plan9.cs.bell-labs.com ([135.104.9.2]) by plan9; Sat Jul 26 05:56:33 EDT 2003 Received: from mail.cse.psu.edu ([130.203.4.6]) by plan9; Sat Jul 26 05:56:30 EDT 2003 Received: by mail.cse.psu.edu (CSE Mail Server, from userid 60001) id 7BFAC19A63; Sat, 26 Jul 2003 05:56:20 -0400 (EDT) Received: from psuvax1.cse.psu.edu (psuvax1.cse.psu.edu [130.203.76.6]) by mail.cse.psu.edu (CSE Mail Server) with ESMTP id 4717A199E1; Sat, 26 Jul 2003 05:56:16 -0400 (EDT) X-Original-To: 9fans@cse.psu.edu Delivered-To: 9fans@cse.psu.edu Received: by mail.cse.psu.edu (CSE Mail Server, from userid 60001) id 8D3D819A94; Sat, 26 Jul 2003 05:55:07 -0400 (EDT) Received: from mail.rdslink.ro (mail.rdslink.ro [193.231.236.20]) by mail.cse.psu.edu (CSE Mail Server) with SMTP id 4A4E7199E1 for <9fans@cse.psu.edu>; Sat, 26 Jul 2003 05:55:06 -0400 (EDT) Received: (qmail 23695 invoked from network); 26 Jul 2003 09:49:52 -0000 Received: from unknown (HELO ratsnest.hole) (10.100.0.28) by mail.rdslink.ro with SMTP; 26 Jul 2003 09:49:52 -0000 From: Enache Adrian To: 9fans@cse.psu.edu Subject: Re: [9fans] Re: random moving of cursor arrow Message-ID: <20030726095940.GA2481@ratsnest.hole> Mail-Followup-To: Enache Adrian , 9fans@cse.psu.edu References: <012c01c3528e$f861d2a0$b9844051@insultant.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4i Sender: 9fans-admin@cse.psu.edu Errors-To: 9fans-admin@cse.psu.edu X-BeenThere: 9fans@cse.psu.edu X-Mailman-Version: 2.0.11 Precedence: bulk Reply-To: 9fans@cse.psu.edu List-Id: Fans of the OS Plan 9 from Bell Labs <9fans.cse.psu.edu> List-Archive: Date: Sat, 26 Jul 2003 12:59:40 +0300 X-Spam-Status: No, hits=-3.5 required=5.0 tests=IN_REP_TO,REFERENCES,USER_AGENT_MUTT version=2.55 X-Spam-Level: X-Spam-Checker-Version: SpamAssassin 2.55 (1.174.2.19-2003-05-19-exp) A question about mouse support: Have the new changes to the serial ports & mice code added support for scroll serial mice (aka microsoft intellimice with 5 buttons) and for shift-button3 button2 emulation ? I'm using a rather old 4th edition plan9 (Tue Sep 3 00:36:58 2002), and there I hacked some code in the kernel so it works fine for me now (but no code for pnp identification in aux/mouse.c - that would be simple, though). It looks like this: src/9/port/devmouse.c: /* * microsoft intellimouse 3 buttons + scroll * byte 0 - 1 L R Y7 Y6 X7 X6 * byte 1 - 0 X5 X4 X3 X2 X1 X0 * byte 2 - 0 Y5 Y4 Y3 Y2 Y1 Y0 * byte 3 - 0 0 M % % % % * * %: 0xf => U , 0x1 => D * * L: left * R: right * U: up * D: down */ int m5mouseputc(Queue*, int c) { static uchar msg[3]; static int nb; msg[nb++] = c & 0x7f; if (nb == 4) { schar dx,dy,newbuttons; dx = msg[1] | (msg[0] & 0x3) << 6; dy = msg[2] | (msg[0] & 0xc) << 4; newbuttons = (msg[0] & 0x10) >> (shiftpressed ? 3:2) | (msg[0] & 0x20) >> 5 | ( msg[3] == 0x10 ? 0x02 : msg[3] == 0x0f ? 0x08 : msg[3] == 0x01 ? 0x10 : 0 ); mousetrack(dx, dy, newbuttons, TK2MS(MACHP(0)->ticks)); nb = 0; } return 0; } (I also changed 'shift' in i8042intr() to 'shiftpressed' and made it global, and removed 'mouseshifted' which was never set). Thanks & Regards, Adi --upas-titjqyumprlozisqniabzunwkx--