Acorn Atom Mouse and Cursor van Oss                       by Kees van Oss.

See also Atomic Windows and the Atomic windows ROM                                     back to the Special 3 text.

This is the default standard mouse for the Atom. I have no wish to modify all the existing software that expects mouse data at its usual memory locations, so if I do add a ROM to my project I will make it use the same addresses. I got some mail from Kees expressing an interest in my project, and he sent me details about his interfaces.

The trick is to manipulate the address lines between the video RAM and the 6847. The block diagram looked like this:  

CPU PH2 !OE 64K EPROM
  GND !CE
8255 PB7- PB0 A15- A8
6847 A12- A5 A7- A0 D7- D0 A12- A5 Video RAM
8255 PA4- PA0 A9- A5 1K EPROM D4- D0 A4- A0
6847 A4- A0 A4- A0
  GND !CE
CPU PH2 !OE

I also built a mouse interface which had two 8-bit counters. The mouse has to be a non-intelligent mouse (the Atom is intelligent enough ;-) You can use an Amiga- or a Tandy mouse. The mouse has to output pulses which are used in my interface to increment or decrement the counters. The block diagram looks like this:  

Mouse X-trig -->
X-dir -->
U/D
split
--> 8-bit X
counter
--> Buffer --> Atom
PL6
Y-trig -->
Y-dir -->
L/R
split
--> 8-bit Y
counter
--> Buffer -->
Buttons L and R --> Buffer -->

The addresses to control the mouse are:

#BFE0 X-Pos Write D7-0 Put Mousepointer on X-pos
Read D7-0 Get current Mousepointer-X-pos
#BFE1 Y-Pos Write D7-0 Put Mousepointer on Y-pos
Read D7-0 Get current Mousepointer-Y-pos
#BFE2 PointerNr Write D7 Pointer on/off
0 Mousepointer on
1 Mousepointer off
D6-5 Unused
D4-0 Select Mousepointer
Mouse
buttons
Read D7-2 Unused
D1 0 right button pressed
1 right button released
D0 0 left button pressed
1 left button released)

The third project I started was to display a pointer on the screen by hardware. No software is needed to display the pointer. The pointer has a white and a black mask so it very similar to a PC mouse pointer. The trick is to manipulate the data lines between the video RAM and the 6847 with AND and OR operations combined with a mouse pointer mask. The block diagram looks like this:  

Atom --> Buf
D7-0
--> Video RAM --> Mixer --> 6847
--> Buf
A12-0
-->
--> Scroll
H & V
--> Pointer
Black & White
-->
--> -----------------------------> --> ----> -->

After all above mentioned interfaces were working, I combined them to get a hardware displayed mouse pointer (0-31) that was moved by hardware scrolling controlled by the mouse. When the mouse pointer worked I wrote a ROM (Atomic Windows) which is an utility ROM for easy creating graphic dialogboxes in CLEAR4. This ROM works with the standard keyboard but I implemented some routines to use this mouse interface. Now I can write programs with dialog boxes activated by the mouse. I attached the manual and the ROM (#A000) of Atomic Windows.   That's the interface I build in my Atom and maybe it's something to implement in your FPGA project. I also attached 2 more detailed block diagrams of the mouse interface and the hardware pointer. The schematics are also attached of the 2 interfaces.

My Atom is also expanded with an I2C bus,  an infrared receiver and an ISA bus. At the moment I'm trying to implement TCP/IP for the Atom. The status of the project is that I can connect the Atom with a PPP-server that is running on a PC under Windows 98 by using a serial I/O card placed in the Atom ISA bus and a nullmodem cable. When the connection is established, the Atom can be Pinged. Also some simple TFTP file transfers works. I am intending to write a TCP/IP stack in ROM (Atomic Network ROM) which can be used with a device driver in RAM. The PPP serial device driver is working and now I'm experimenting with a Realtek 8019AS network card. I managed to read the MAC address.   You see, the Atom is still alive!!   If you have any questions or need some information, I'll be glad to send them to you. At the same time I will follow your experiments with the FPGA.


block diagram mouse pointer


block diagram hardware pointer


diagram mouse pointer Click to enlarge this diagram