[comp.sys.amiga] How to steal the mouse port.

peter@sugar.UUCP (11/29/87)

Here's what I do. It works. You may not have to go through all this
rigamarole, but I do it anyway. Any less and you end up with a hung
mouse.

	Open gameport.device, 0.
	Send GPD_ASKTRIGGER, savebuffer.
	Close gameport.device.

	Open input.device.
	Send IND_SETMPORT, 2.
	Close input.device.

	Open gameport.device, 0.
	Send GPD_SET* for whatever setup you want.

	Play game.

	Close gameport.device, 0.

	Open input.device.
	Send IND_SETMPORT, 0.
	Send IND_SETMTYPE, GPCT_MOUSE.
	Send IND_SETMTRIG, savebuffer.
	Close input.device.

While playing with this, visions of multiple input devices and a multiuser
Amiga started to crop up. Let's see, make input device 0 act like /dev/tty,
and give you just your virtual amiga. MEMF_PUBLIC is only public to your
virtual amiga. input device 1 is for virtual amiga 1...

Hey, it's just an idea.
-- 
-- Peter da Silva  `-_-'  ...!hoptoad!academ!uhnix1!sugar!peter
-- Disclaimer: These U aren't mere opinions... these are *values*.