MTA41300
PS/2
®
and Serial Mouse and Trackball Controller I.C.
FEATURES
• Mouse and trackball controller IC
• Selectable RS-232 Serial or IBM
®
PS/2 interfaces
• Microsoft
®
serial interface format and IBM PS/2
mouse compliant
• Single-chip, two-button mouse or trackball
controller
• 1200,N,7,1 - RS-232 serial communication format
• 10 kHz PS/2 interface
• Fixed mouse and trackball resolution
• Motion sampling rate of 12000 samples/second in
PS/2 Mode and 15000 samples/second in
RS-232 Mode
• Available in:
- 18-lead 300 mil PDIP
- 18-lead 300 mil SOIC
PACKAGE TYPE
PDIP, SOIC
DBTN
MODE
V
DD
MCLR
V
SS
HOR1
HOR2
TXD
DATA
•
1
2
3
4
5
6
7
8
9
18
17
16
15
14
13
12
11
10
SBTN
PBTN
OSC1
OSC2
V
DD
DLED
CLK
VERT
1
MTA41300
DESCRIPTION
The MTA41300 is the heart of a simple, low-cost,
mouse or trackball solution. It can be configured to
operate as either an IBM PS/2 compliant mouse or as
a serial mouse that is Microsoft serial format
compatible. Both interface options are also available
when the MTA41300 is used as a trackball controller.
The mouse select and drag operation can be
performed with a trackball by using the optional drag
lock input and drag lock LED. When using a trackball,
this allows for one-handed select and drag.
MTA41300
The MTA41300 is an 18-lead low-power CMOS
integrated circuit. Combined with a few simple external
components, a complete mouse or trackball system
can be realized.
IBM and PS/2 are registered trademarks of IBM Corp.
Microsoft is a registered trademark of Microsoft Corp.
The code in this product was not developed or licensed by Microsoft Corporation.
The microcode contained in this product is copyrighted
©1993,
all rights reserved.
©
1995 Microchip Technology Inc.
DS40101C-page 1
MTA41300
Table of Contents
Page
1.0 Pin Descriptions ............................................................................................................................................................................. 3
2.0 Serial Mouse Mode Operation ....................................................................................................................................................... 4
3.0 IBM PS/2 Mode Operation ............................................................................................................................................................. 5
4.0 Motion Encoder Inputs ................................................................................................................................................................... 8
5.0 Push-Button Inputs ........................................................................................................................................................................ 9
6.0 Trackball Option ............................................................................................................................................................................. 9
7.0 Electrical Characteristics.............................................................................................................................................................. 10
8.0 Application Examples................................................................................................................................................................... 17
9.0 Packaging Diagrams and Dimensions ......................................................................................................................................... 25
10.0 Package Marking Information ...................................................................................................................................................... 27
List of Figures
Figure 4-1:
Figure 4-2:
Figure 6-1:
Figure 7-1:
Figure 7-2:
Figure 7-3:
Figure 7-4:
Figure 7-5:
Figure 7-6:
Figure 7-7:
Figure 7-8:
Figure 8-1:
Figure 8-2:
Figure 8-3:
Figure 8-4:
Figure 8-5:
Figure 8-6:
Figure 8-7:
Positive Motion Input ..................................................................................................................................................... 8
Negative Motion Input .................................................................................................................................................... 8
Trackball Drag Lock Operation ...................................................................................................................................... 9
Input Threshold Voltage (V
TH
) of all Input and I/O Pins Except MCLR and OSC1...................................................... 12
V
IH
V
IL
OF MCLR
VS
V
DD
............................................................................................................................................ 12
Input Threshold Voltage (V
TH
) of OSC1 Input ............................................................................................................. 13
I
OH VS
V
OH
, V
DD
= 3V .................................................................................................................................................. 13
I
OH VS
V
OH
, V
DD
= 5V .................................................................................................................................................. 13
I
OL VS
V
OL
, V
DD
= 3V................................................................................................................................................... 14
I
OL VS
V
OL
, V
DD
= 5V................................................................................................................................................... 14
Timing Diagrams.......................................................................................................................................................... 16
MTA41300 Based PS/2 Mouse or Trackball................................................................................................................ 18
MTA41300 Based Serial Mouse or Trackball .............................................................................................................. 19
MTA41300 Based Serial - PS/2 Combo Mouse .......................................................................................................... 20
RS232 to PS/2 Adapter Plug Wiring for MTA41300 .................................................................................................... 21
Basic Mouse/Trackball Optical Motion Encoder .......................................................................................................... 22
Improved Mouse/Trackball Optical Motion Encoder .................................................................................................... 23
Mouse/Trackball Mechanical Motion Encoder ............................................................................................................. 24
DS40101C-page 2
©
1995 Microchip Technology Inc.
MTA41300
1.0
TXD
MODE
HOR1
HOR2
PBTN
SBTN
DBTN
VERT1
VERT2
DLED
OSC1
OSC2
DATA
CLK
MCLR
V
DD
V
SS
PIN DESCRIPTIONS
TYPE
Output
Input
Input
Input
Input
Input
Input
Input
Input
Output
Input
Output
I/O
I/O
Input
Pwr
Pwr
DESCRIPTION
Data port for RS-232 serial data. Active low. For IBM PS/2 Mode,
this pin is a no connect and should be left open
Mode select 1 = PS/2, 0 = RS-232 serial
Horizontal quadrature Input #1
Horizontal quadrature Input #2
Primary mouse button. Active low, 0 = button depressed
Secondary mouse button. Active low, 0 = button depressed
Optional trackball drag lock button. Active low, 0 = button
depressed. For mouse only operation, connect this pin to V
DD
Vertical quadrature input #1
Vertical quadrature input #2
Optional trackball drag LED. For mouse only operation, this pin is a
no connect and should be left open
4 MHz crystal or ceramic resonator connection
4 MHz crystal or ceramic resonator connection
Bidirectional data port for PS/2. For Serial Mouse Mode, this pin is
a no connect and should be left open
PS/2 data clock input. For Serial Mouse Mode, this pin is a no con-
nect and should be left open
A “low” voltage on this pin causes a reset condition for the
MTA41300 controller
+5V
Ground
PIN NAME
©
1995 Microchip Technology Inc.
DS40101C-page 3
MTA41300
2.0
SERIAL MOUSE MODE
OPERATION
The MTA41300 mouse controller transmits the
following three-byte Microsoft serial interface compliant
data packet in response to a mouse event.
Message Data Byte 1:
Bit
6
5
4
3
2
1
0
Description
Always = 1 (message sync bit)
1 = Primary Button Depressed
1 = Secondary Button Depressed
Vertical Motion bit 7 (MSB)
Vertical Motion bit6
Horizontal Motion bit7 (MSB)
Horizontal Motion bit6
When operating in serial mouse mode the MTA41300
mouse controller is a ransmit only device. The
t
MTA41300 transmits a fixed format data packet at
1200 baud to the host when a button press or mouse
motion is detected.
2.1
Reset Initialization
The MTA41300 will transmit a “M” character
immediately after power-up or when a reset is initiated
by the host. This character notifies the host that the
message format is Microsoft serial format compliant.
The MTA41300 is placed in the reset state when the
MCLR pin is driven low.
Message Data Byte 2:
Bit
6
5
4
3
2
1
0
Description
Always = 0
Horizontal Motion bit5
Horizontal Motion bit4
Horizontal Motion bit3
Horizontal Motion bit2
Horizontal Motion bit1
Horizontal Motion bit0
2.2
Serial Mode Message Format
The following Microsoft serial interface compliant data
format is broadcast by the MTA41300 when transmit-
ting data to the host. The 1200 baud data format uti-
lizes a 9-bit data frame that consists of 7 bits of
message data and 2 control bits.
Data Frame Format:
Bit
1
2
3
4
5
6
7
8
9
Description
Start Bit (always 0)
Message Data Bit0, LSB
Message Data Bit1
Message Data Bit2
Message Data Bit3
Message Data Bit4
Message Data Bit5
Message Data Bit6, MSB
Stop bit (always 1)
Message Data Byte 3:
Bit
6
5
4
3
2
1
0
Description
Always = 0
Vertical Motion bit5
Vertical Motion bit4
Vertical Motion bit3
Vertical Motion bit2
Vertical Motion bit1
Vertical Motion bit0
DS40101C-page 4
©
1995 Microchip Technology Inc.
MTA41300
3.0
IBM PS/2 MODE OPERATION
3.1.2
RESEND
CODE: FEH
Upon power-up the MTA41300 mouse controller
initiates an internal reset sequence. First, all internal
registers and communication parameters are cleared.
Next, the status registers are set to the default
condition. Finally, if the MTA41300 receives a Resend
command as the first command after power-up, it will
transmit a AAh followed by a 00h in response. This
notifies the host that the initialization is complete and
that the controller is a standard mouse type. This is to
ensure compatibility with some hosts that do not follow
the normally recommended behavior of issuing a Reset
command as the first command after power-up.
The MTA41300 always confirms reception of a
command sent by the host by returning an
acknowledge byte (FAh). If the host interrupts the
transmission of the acknowledge byte, the MTA41300
discards the complete command. The MTA41300 is
then ready to receive and acknowledge the next
command. Two exceptions to the acknowledge after
command received rule exist. The MTA41300 does not
issue an acknowledge upon receipt of either the Set
Wrap Mode (EEh) or Resend (FEh) commands.
Anytime the MTA41300 controller receives an invalidly
formatted command, it will transmit a Resend
command to the host. The controller will ignore invalid
commands and will continue to operate in its present
mode. When any command other than a resend is
received by the controller, it will clear its motion and
displacement counters.
The host system may send a Resend command to the
controller if an error is detected in a transmission from
the controller. When the controller receives a Resend
command, it will retransmit the last data packet
transmitted. If the last packet transmit was a resend
command, the packet prior to the last packet will be
retransmitted.
3.1.3
SET DEFAULT
CODE: FEH
The Set Default command re-initializes all controller
parameters to the power-up state. The controller
initializes the following status registers, which only exist
to ensure compatibility.
Report rate:
Scaling:
Mode:
Resolution:
100 reports per second
Linear
Streaming
Physical resolution
Disabled
3.1
PS/2 Mode Commands
Command Summary:
Command
Reset
Resend
Set Default
Disable Reporting
Enable Reporting
Set Report Rate
Read Device Type
Set Remote Mode
Set Wrap Mode
Reset Wrap Mode
Read Data
Set Stream Mode
Status Request
Set Resolution
Set Scaling
Reset Scaling
3.1.1
RESET
Code
FFh
FEh
F6h
F5h
F4h
F3h, XXh
F2h
F0h
EEh
ECh
EBh
EAh
E9h
E8h, XXh
E7h
E6h
CODE: FFH
Reporting:
This command does not initiate self test diagnostics.
The controller remains in the disabled state until
another command is received from the host.
3.1.4
DISABLE REPORTING
CODE: F5H
The Disable Reporting command prevents data
transmission by the controller while it is in the Stream
Mode. However, the controller will still respond to other
commands. When reporting is disabled, Stream Mode
must be disabled prior to the host sending a command
that requires a response by the controller.
3.1.5
ENABLE REPORTING
CODE: F4H
The Enable Reporting command allows the controller
to transmit data when in Stream Mode. This command
has no effect while the controller is in Remote Mode.
3.1.6
SET REPORT RATE
CODE: F3H, XXH
This command initiates a reset sequence in the
MTA41300 mouse controller. First, all internal registers
and communication parameters are cleared. Next, the
status registers are set to the default condition. Finally,
the MTA41300 transmits a AAh followed by a 00h, this
notifies the host that the initialization is complete and
that the controller is a standard mouse type.
This command updates the report rate status register
with the data contained in the second byte of the
command. However, the actual report rate remains
fixed at 40 times per second. This command only exists
to ensure compatibility.
3.1.7
READ DEVICE TYPE
CODE: F2H
The controller always transmits a 00h in response to
receiving this command. This informs the host that a
standard mouse is present.
©
1995 Microchip Technology Inc.
DS40101C-page 5