Login
Back to forumSee the full topicGo to last reply

Posted By

MMS
on 2019-10-09
14:45:37
 Re: Apart of new clean and bigger scans...

Both your proposal may work.

1) 1351 mouse can be done via SID card.
Actually the original first GEOS did not support analog mouse, only the later versions. BTW the original 1351 mouse had a disc, on the second side it was the GEOS driver to upgrade GEOS to 1.3 (it was the main version change)
Disc content is here (I do not have it, but surely the D64 available somewhere)
https://www.c64-wiki.com/wiki/Mouse_1351

AFAIK the main issue here that the original C64 SID register's are putting the mouse ($d419 and $d41a) while the SID card is putting it to $FD82 and $FD83.

On the other hand there is a small chance no conversion is needed(...)
The SID card can be put into "legacy mode" (pushing both RESET buttons at the same time), then the SID card operates at original $D400 address. The original GEOS mouse driver expects to read the paddle position from here, so coping and activating the C64 GEOS driver to the Plus/4 GEOS (like: updating C64 GEOS to v1.3), then putting the SID card to legacy mode the driver can read the mouse coordinates.
Unfortunately it is not probable it will work so easily. The POX and POTY registers need to be read out regularly, so if the driver using some CIA timers or raster time for the reading, then it will not run on Plus/4. Also it expects, that the Plus/4 GEOS do not use than memory address where the SID Card operates now ($D400)

On this page you can find a resident driver assembly code for C64 mouse driver.
You can slightly modify it and test the SID Card's behaviour with an 1351.
Unfortunately I do not own such a C= mouse, otherwise I would already do that.
Certainly sprite in the code will not work, but eg. dividing XPOS and XPOS values by 8 (ROR 3x) you may get the character position (40x25) and if you write it directly into the cursor position of the machine, you can control the cursor position with the mouse on the screen during BASIC editing (same way as Plus4Emu handles PC mouse)
https://www.commodore.ca/manuals/funet/cbm/manuals/1351-mouse.txt

2) RS232 mouse: the reading and decoding of that PC serial mouse is different and more complex than the 1351 (just getting the coordinate from SID).
Buying a ready Max232 circuit and connecting to user port makes the connection easy. The HW is the easy part.
Currently there is no driver, and the version I have is too big to put into zero page, and has a bug (breaking), but can share it with you.
It is not GEOS, but a core of a resident driver with a lot of bitmovement, but it needs a better programmer than me to be finished. There is a BASIC sample how can be used. But the code it much longer than the above linked one. (and does not work :-) )

3) worth to read Levente's PC serial mouse interface
http://www.zimmers.net/anonftp/pub/cbm/documents/projects/interfaces/mouse/Mouse.html

It does not really help on Plus/4 scene (as still reqiore POTX, POTY inputs on the joystick port), but it is a very detailed one
It looks to be similar function as Micromys PS/2 mouse adapter (simulates an 1351 on C64 joy port)
https://icomp.de/shop-icomp/de/shop/product/micromys-v5.html



Back to top


Copyright © Plus/4 World Team, 2001-2024