Page 1 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
D
D
Da
a
at
t
ta
a
aS
S
Sh
h
he
e
ee
e
et
t
t
Version:1.1
Jul./2002
http://www.topro.com.tw
5 F, No.10, Prosperity Road 1, Sci ence-Based Industri al Park, Hsinchu 300, Taiwan, R.O.C
300 新竹科學工業園區展業一路 10 5
TPE:
5 F, No.27, Min Chuan W. Rd. Taipei 104, Taiwan, R.O.C
104 台北市民權西路 27 5
SHENZHEN
:
Room 802, Tower A, World Trade Plaza, Fahong Rd., Fatian, Shenzhen, China
深圳市福田區福虹路 9號世貿廣場 A802 (郵編:518033)
H.Q.: Tel:886-3-5632515 Fax:886-3-5641728
TPE.: Tel:886-2-25856858 Fax:886-2-25941104
SHENZHEN:TEL:755-3679985 Fax:755-3679518
Page 2 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
G
Ge
en
ne
er
ra
al
l
S
Sp
pe
ec
ci
if
fi
ic
ca
at
ti
io
on
n
The TP88x5/x3 is to provide a reliable and low-cost solution of transferring mouse data to
the host system through a USB environment and accept a report information from host system to
indicate e-mail coming. This USB e-mail Mouse controller has been developed for applications
requiring a low speed interface to the USB. It completely conforms to the USB 1.5 Mbps
specification, version 1.1 and USB HID specification, version 1.1. TP88x5/x3 build in a RC
Oscillator,so it doesn’t need any external crystal for whole system. This e-mail mouse controller
can interface five key-switches and six photo-couplers direct to USB and up to three indicator
ELED to turn on/off an LED in order to indicate e-mail received by your mail server. Key
de-bouncing circuit is provided to prevent false entry and improve the accuracy, and the noise
immunity circuits to eliminate this noise.
Selector Guide
Part Number Interface No. of Keys No. of LEDs Support Buzzer Pin/Package
TP8833 (a)AP/BP USB+PS/2 3 0 NONE 18/DIP,SOP
TP8835 (a)AP/BP USB+PS/2 5 0 NONE 20/DIP,SOP
*TP8815 (a)AP/BP USB+PS/2 5 1 NONE 20/DIP,SOP
*TP8825 (a)AP/BP USB+PS/2 5 3 YES 22/DIP
24/SOP
Note: 1.”A”=>resolution in z direction=1/2.
2.”B”=>resolution in z direction=1/4.
3.In USB mode,the “a” indicates Button-Wakeup only,if not,that indicates Button
with Motion Wakeup.
4.A LED could instead of a Buzzer.
5. ‘ *’ = development
Page 3 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
Features
Built-in 6MHz RC oscillator or 6MHz external oscillator.
Fully compliant with the USB 1.1 specification, supports control and interrupt transactions.
Fully compliant with the HID 1.1 specification, supports remote wakeup and USB
mouse boot protocol feature.
Data transfer at USB low speed, Supports 1 device address and 2 endpoints.
Integrated USB Transceiver & 1.5Mbps USB serial interface engine.
Improved output drivers to reduce EMI.
Single 5V power supply with DC supply voltage from 4.4v to 5.25v.
Internal power-on-reset (POR).
Built-in noise immunity circuit.
Five key-switches and six photo-couples inputs.
Both key-press and key release de-bounce intervals are 11ms.
Support USB suspend mode and remote wakeup feature.
Operating temperature range from 0 to 70 degree Celsius.
Built-in auto-reference function.
Auto speed with dynamic resolutions.
Set on/off time for ELED1 and ELED2. When e-mail coming it can flashlight.
Change frequency for buzzer when e-mail coming it will sing a song.
PS/2 Support with compatible 2D & 3D & 5-button Wheel mode.
PIN to PIN compatible with TP8301/02, TP88X5.
Improved ESD protection.
5-button & 3D Wheel mode.
Low power dissipation. Support USB suspend power management to lower suspend current
. the LEDs and internal Clocks are turned off before the device goes into suspend and are turned
on right after the device gets out of suspend.
Page 4 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
Contents
1. General Specification P. 2 --- P.
3
2. Pin Configurations and Package Type P. 5 --- P.
6
3. Pin Descriptions P. 7 --- P.
7
4. Functional Block Diagram P. 8 --- P.
8
5. Function Descriptions P. 9 --- P.
28
6. Absolute Maximum Ratings P. 29 --- P.
29
7. DC Electrical Characteristic P. 29 --- P.
30
8. AC Electrical Characteristic P. 30 --- P.
33
9. Application Diagrams P. 34 --- P.
35
Page 5 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
P
Pi
in
n
C
Co
on
nf
fi
ig
gu
ur
ra
at
ti
io
on
ns
s
a
an
nd
d
P
Pa
ac
ck
ka
ag
ge
e
T
Ty
yp
pe
e
1. 5Key Series(TOP VIEW)
ELED3/BUZZER
Z 2
D-
D+
RC
L ED
XTAL1
XTAL2
VSS
Z1
Y2
Y1
X2
X1
L
M
R
VDD
1
2
3
4
5
6
7
8
9
10
11 12
13
14
15
16
17
18
TP8825A/BP
19
20
21
22
ELED1 ELED2
B 4 B5
22pin/DIP
ELED 3/BU ZZE R
Z2
D-
D+
RC
L ED
XTAL1
XTAL2
VSS
Z1
Y2
Y1
X2
X1
L
M
R
VDD
1
2
3
4
5
6
7
8
9
10
11 14
15
16
17
18
19
20
TP8825A/BP
21
22
23
24
ELE D1 ELED2
B 4 B5
24pin/SO P
12 13 NCNC
ELED
Z 2
D-(DATA)
D+(CLK)
RC
L ED
XTAL1
XTAL2
VSS
Z1
Y2
Y1
X2
X1
L
M
R
VDD
1
2
3
4
5
6
7
8
9
10 11
12
13
14
15
16
17
18
TP8815A/BP
19
20
B 4 B5
20pin/DIP
20
p
in/SOP
Z 2
D-(DATA)
D+(CLK)
RC
L ED
XTAL1
XTAL2
VSS
Z1
Y2
Y1
X2
X1
L
M
R
VDD
1
2
3
4
5
6
7
8
9
10 11
12
13
14
15
16
17
18
TP8835A/BP
19
20
B4 B5
TE ST
20pin/DIP
20
p
in/SOP
Page 6 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
2. 3Key Series(TOP VIEW)
Z 2
R C
L E D
XTAL1
XTAL2
VSS
Z1
Y2
Y1
X2
X1
L
M
R
VDD
1
2
3
4
5
6
7
8
910
11
12
13
14
15
16
17
18
TP8833A/BP
T E S T
18pin/DIP
18pin/SOP
D-(DAT A)
D + (C L K )
Page 7 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
Pin Descriptions
Symbol Type Function
D+(CLK)
D-(DATA) I/O
I/O Bi-directional data line. For USB environment, An external 7.5kΩresistor
must be connected between the D- and Vdd to select low-speed operation. For
PS2 environment, D+, D- are functioned as PS/2 CLK, DATA line
XTAL1 I 6 MHz ceramic resonator or external clock input
XTAL2 O 6 MHz ceramic resonator
R
M
L
B4
B5
I
I
I
I
I
Five key-switches exert seven different combinations totally. Both key-pressed
and key-released signals will be sent accompanied with horizontal and vertical
state.
The de-bounce interval for both key-press and key-release is 11ms.
VSS
VDD G
P Ground
Power
X1
X2
Y1
Y2
Z1
Z2
I
I
I
I
I
I
Six photo-couple signals denote UP, DOWN, LEFT, RIGHT, Scrolling UP and
Scrolling DOWN state. During the scanning period, as long as the
photo-couples change their state, the value of vertical or horizontal counter
will accordingly increase or decrease.
BUZZER O Open Drain & can set on/off time.
RC I Connect to external RC circuit for USB suspend mode power management
LED O Open Drain & Control for the sink of photo diodes.
ELED1
ELED2
ELED3
O
O
O
Open Drain output pin. A LED indicator, When e-mail coming, the host can
control this pin state by send SET REPORT(see HID-Class Request or
Functional Descriptions) , and also can set ON / OFF time.
Page 8 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
Functional Block Diagram
LED
Driver USB
Command SIE
Mouse
Function
OSC.
PS/2
Command DATA
I/O
LED 1
LED 2
LED 3
X 1
X 2
Y1
Y 2
Z 1
Z 2
B4
B5
L
R
M
D+/CLK
D-/DA
XCVR
Page 9 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
Functional Descriptions
The TP88X5/X3 supports the USB Specification 1.1 data model. Data from the USB host
to the device is transmitted serially. The data are NRZI coded to increase transmission
reliability; bit stuffing (inserting an extra 0 bit after any 6 consecutive 1 bits) is performed and
a CRC check carried out. Bit stuffing, NRZI coding/decoding and CRC checks or generation
are performed within the TP88X5/X3.
The data is transmitted in packets. Three types of packets are defined for the USB: token,
data and handshake. The token is always passed on by the host. It contains a PID (packet
identifier) which defines the direction of the following data transmission and the address of
the device and endpoints to be addressed. Depending on the previous token command, data is
transferred from the USB host to the TP88X5/X3 (OUT transfer) or transferred from the
TP88X5/X3 to the USB host (IN transfer). In the process the respective FIFOs are written
(OUT) or read (IN).
The data transfer is concluded with a handshake. If the data has been received successfully,
an ACK is sent to the data source. If no data is ready for an IN transfer out of the TP88X5/X3,
it sends an NAK handshake instead of the data (If endpoint is enabled).
USB Engine
The USB engine includes the Serial Interface Engine (SIE) and the low-speed USB I/O
transceiver. The SIE block performs most of the USB Interface functions. Two endpoints are
supported. Endpoint 0 is used to receive and transmit control (including setup) packet while
Endpoint 1 is only used to transmit data packets. The USB SIE processes USB bus activity at
the transaction level independently. It does all the NRZI encoding/decoding and bit
stuffing/unstuffing. It also determines token type, checks address and endpoint values, generates
and checks CRC values and controls the flow of data byte between the bus and Endpoint FIFOs.
The SIU handles higher level and function specific tasks. During control transfers the SIU must
interpret device requests and respond correctly. It also must coordinate Suspend/Resume, verify
and select DATA toggle value, and perform function specific tasks.
Page 10 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
Attached
A USB device may be attached or detached from the USB. The state of a USB device
when it is detached from the USB is not defined by this specification. The specification only
addresses required operations and attributions once the device is attached.
Powered
USB devices may obtain power from USB through the hub to which they are attached. A
hub port must be powered in order to detect port status changes, including attach and detach.
Hubs do not provide any downstream power until they are configured, at which point they
will provide power as allowed by their configuration and power source.
Default
After the device has been powered, it must not respond to any bus transactions until it has
received a reset from the bus. After receiving a reset, the device is then addressable at the
default address.
Address assigned
All USB devices use the default address when initially powered or after the device has
been reset. Each USB device is assigned a unique address by the host after attachment or after
reset. A USB device maintains its assigned address while suspended. A USB device responds
to requests on its default pipe whether the device is currently assigned a unique address or is
using the default address.
Configured
Before the USB device’s function may be used, the device must be configured. From the
device’s perspective, configuration involves writing a non-zero value to the device
configuration register. Configuring a device or changing an alternate setting causes all of the
status and configuration values associated with endpoints in the affected interfaces to be set to
their default values. This includes setting the data toggle of any endpoint using data toggle to
the value DATA0.
Page 11 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
Suspended
In Order to conserve power, USB devices automatically enter the suspended state when the
devicehas observed no bus traffic for a specified period. When suspended, the USB device
maintains any internal status including its address and configuration.
Bus Enumeration
When a USB device is attached to or removed from the USB, the host uses a process known
as bus enumeration to identify and manage the device state changes necessary.
Dynamic Attachment and Removal
USB devices may be attached and removed at any time. The hub that provides the attachment
point or port is responsible for reporting any change in the state of the port.
Address Assignment
When a USB device is attached, the host is responsible for assigning a unique address to the
device after the device has been reset by the host and the hub port where the device is attached has
been enabled.
Configuration
A USB device must be configured before its function may be used. The host is responsible
for configuring a USB device. The host typically requests configuration information from the USB
device to determine the device’s capabilities.
Data Transfer
Data may be transferred between a USB device endpoint and the host in one of four ways.
Some endpoints may be capable of different types of data transfer. However once configured, a
USB device endpoint uses only one data transfer method.
Power Budgeting
For bus-powered devices, power is limited resource. When a host detects the attachment of a
bus-powered USB device, the host needs to evaluate the power requirements of the device. If USB
Page 12 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
device power requirements exceed available power, the device is not configured.
Remote Wakeup
Remote wakeup allows a suspended USB device to signal a host that may be suspended.
This notifies the host that it should resume from its suspended mode, if necessary, and service the
external event that triggered the suspended USB device to signal the host.
USB Request
The TP88X5/X3 supports the following USB standard request : (ref to USB spec. for detailed
description)
a. clear_feature :
This request is used to clear endpoint_stall or disable device_remote_wakeup
b. get_configuration:
This request returns the current device configuration. If the returned value is zero, the
device is not configured.
c. get_descriptor :
This request returns the specified descriptor if the descriptor exists.
d. get_status :
This request returns status for the specified recipient.
e. set_address :
This request sets the device address for all future device accesses.
f. set_configuration :
This request sets the device configuration.
g. set_feature :
This request is used to enable device_remote_wakeup feature.
HID-Class Request
The TP88X5/X3 supports the following HID class-specific requests : (ref to HID spec. for
detailed description)
a. get_class_descriptor :
This request returns a class descriptor for the device.
Page 13 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
b. get_report :
This request allows the host to receive a report via the control pipe.
c. get_idle :
This request reads the current idle rate for the input report.
d. get_protocol :
This request reads which protocol is currently active, either the boot protocol or the
report protocol. This request is supported by devices in the boot subclass.
e. set_report :
This request allows the host to send a report to device, possibly setting the state of input,
output, or feature controls.
f. set_idle :
This request silences a particular report on the interrupt pipe until new event or the
specified amount of time passes. The default idle rate is infinity.
g. set_protocol :
This request switches between the boot protocol and the report protocol.
USB Descriptors
The TP88X5/X3 supports the following USB standard descriptors : (ref to USB spec. for
detailed descriptor)
a. device descriptor :
A device descriptor describes general information about a USB device. It includes
information that applies globally to device and all of the device’s configurations. A USB
device has only one device descriptor.
b. configuration descriptor :
The configuration descriptor describes information about a specific device configuration.
c. interface descriptor :
This descriptor describes a specific interface provided by associated configuration.
d. endpoint descriptor :
This descriptor contains the information required by the host to determine the
bandwidth requirement of each endpoint.
e. string descriptor :
Page 14 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
String descriptors are optional. If a device does not support string descriptors, all
references to string descriptors within device, configuration, and interface descriptors
must be reset to zero.
HID Descriptors
The TP88X5/X3 supports the following HID class-specific descriptors : (ref to HID spec. for
detailed description)
a. HID descriptor :
The HID descriptor identifies the length and type of subordinate descriptors for a device.
b. report descriptor :
The report descriptor is made up of item, which provide information about the device.
The length and content of a report descriptor vary depending on the number of data fields
required for the device’s reports.
c. physical descriptor :
The physical descriptor is a data structure that provides information about the specific
parts of the human body that are activating controls.
Mouse Report Format
bit7 bit6 bit5 bit4 bit3 bit2 bit1 bit0
Byte0 3 bit padding 5thbutton4thbuttonMbutton Rbutton Lbutton
Byte1 X displacement
Byte2 Y displacement
Byte3 Z displacement
Host Request Report Format
Bit7 bit6 bit5 bit4 bit3 bit2 bit1 bit0
Byte0 Select LED X Select LED flash cycle ELED
ON/OFF
Byte1 ON Time(Unit = 0.1Second)
Byte2 OFF Time (Unit = 0.1Second)
Page 15 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
Contents of descriptors
a. device descriptor
Offset Field size value Description
0 Blength 1 0x12 size of this descriptor in bytes
1 BdescriptorType 1 0x01 DEVICE descriptor type
2 BcdUSB 2 0x0110 USB specification release 1.10
4 BdeviceClass 1 0x00 class code
5 BdeviceSubClass 1 0x00 subclass code
6 BdeviceProtocol 1 0x00 protocol code
7 BmaxPacketSize0 1 0x08 Maximum packet size for endpoint zero
8 IdVendor 2 0x06A2 Topro vender ID
10 IdProduct 2 0x0001 product ID
12 BdcDevice 2 0x0100 device release number in bcd
14 IManufacturer 1 0x01 string index for iManufacturer
15 IProduct 1 0x02 string index for iProduct
16 ISerialNumber 1 0x00 no string index
17 BNumConfigurations 1 0x01 number of possible configuration
b. configuration
Offset Field size Value description
0 BLength 1 0x09 size of this descriptor in bytes
1 BDescriptorType 1 0x02 CONFIGURATION descriptor type
2 WTotalLength 2 0x0022 configuration+interface+endpoint+HID
4 BNumInterfaces 1 0x01 number of interface
5 BConfigurationValue 1 0x01 configuration argument
6 IConfiguration 1 0x04 string index for iConfiguration
7 BmAttributes 1 0xa0 bus powered + remote wakeup feature
8 MaxPower 1 0x32 max. power consumption in 2mA unit
c. interface descriptor
Offset Field size Value description
0 BLength 1 0x09 size of this descriptor in bytes
1 BDescriptorType 1 0x04 INTERFACE descriptor type
2 BInterfaceNumber 1 0x00 interface argument
3 BAlternateSetting 1 0x00 value used to select alternate setting
4 BNumEndpoint 1 0x01 number of endpoints(excluding ep0)
5 BInterfaceClass 1 0x03 HID class code
Page 16 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
6 BInterfaceSubClass 1 0x01 boot interface subclass code
7 BInterfaceProtocol 1 0x02 mouse protocol
8 IInterface 1 0x05 Interface string index
d. endpoint descriptor
Offset Field size Value description
0 Blength 1 0x07 size of this descriptor in bytes
1 BdescriptorType 1 0x05 ENDPOINT descriptor type
2 BendpointAddress 1 0x81 IN endpoint address
3 BmAttributes 1 0x03 interrupt pipe attribute
4 WmaxPacketSize 2 0x0008 maximum packet size
6 Binterval 1 0x0a interval for polling EP for data transfer
e. HID descriptor
Offset Field size Value description
0 Blength 1 0x09 size of this descriptor in bytes
1 BdescriptorType 1 0x21 HID descriptor type
2 BcdHID 2 0x0100 HID class specification release number
4 BcountryCode 1 0x00 Hardware target country
5 BnumberDescriptors 1 0x01 number of HID class descriptors to follow
6 BdescriptorType 1 0x22 report descriptor type
7 WreportLength 2 0x0055 total length of report descriptor
f. report descriptor
Item Value(3D)
Usage page (generic desktop) 05 01
Usage (mouse) 09 02
Collection (application) a1 01
Usage (pointer) 09 01
Collection (Physical) a1 00
Usage page (buttons) 05 09
Usage minimum (button 1) 19 01
Usage maximum (button 5) 29 05
Logical minimum (0) 15 00
Logical maximum (1) 25 01
Report count (5) 95 05
Page 17 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
Report size (1) 75 01
Input(data, variable, absolute) 81 02
Report count (1) 95 01
Report size (3) 75 03
Input (constant) 81 03
Usage page (generic desktop) 05 01
Usage (x) 09 30
Usage (y) 09 31
Usage (wheel) 09 38
Logical minimum (-127) 15 81
Logical maximum (127) 25 7f
Report size(8) 75 08
Report count (3) 95 03
Input (data, variable, relative) 81 06
End collection c0
Usage page(LEDs) 05,08
Usage (Usage Selected Indicator) 09,3a
Collection (Logical) a1, 02
Usage (Num Lock) 09,01
Logical Minimum(0) 15,00
Logical Maximum(1) 25,01
Reprot count (1) 95,01
Report size (1) 75,01
Output (Data,Var,Abs) 91,02
End collection C0
Report count (1) 95,01
Report size (7) 75,07
Output (Cnst,Ary,Abs) 91,01
Usage (Flash On Time) 09,42
Report count (2) 95,02
Report size (8) 75,08
Output (Data,Var,Abs) 91,02
End collection C0
g. string descriptor
Offset Field size Value Description
0 Blength 1 0x04 size of this descriptor in bytes
1 BdescriptorType 1 0x03 String descriptor type
Page 18 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
2 Bstring 2 0x0409 LangID code for English
String index 1 for manufacturer
Offset Field size Value Description
0 Blength 1 0x0c size of this string in bytes
1 BdescriptorType 1 0x03 String descriptor type
2 Bstring “TOPRO
String index 2 for product
Offset Field Size Value Description
0 Blength 1 0x14 size of this string in bytes
1 BdescriptorType 1 0x03 String descriptor type
2 Bstring “USB Mouse”
String index 4 for configuration
Offset Field size Value Description
0 Blength 1 0x14 size of this string in bytes
1 BdescriptorType 1 0x03 String descriptor type
2 Bstring “HID Mouse”
String index 5 for interface
Offset Field Size Value Description
0 Blength 1 0x1e Size of this string in bytes
1 BdescriptorType 1 0x03 String descriptor type
2 Bstring “Interrupt Pipe”
PS/2 Functional Descriptions
(A) Operating mode
There are four operating modes in PS/2 mouse :
Page 19 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
a. Reset Mode :
In this mode a self-test is initiated during power-on or by a Reset command. After reset
signal, PS/2 mouse will send:
(a) Completion code AA & ID code 00.
(b) Set default:
sampling rate: 100 reports/s
non-autospeed
stream mode
4 counts/mm
disable
b. Stream Mode:
The maximum rate of transfer is the programmed sampling rate.
Data report is transmitted if
(a) switch is pressed
(b) movement has been detected
c. Remote Mode:
Data is transmitted only in response to a Read Data command.
d. Wrap Mode:
Any byte of data sent by the system, except hex EC ( Reset wrap mode ) or hex FF
( Reset), is returned by TP88X5/X3.
(B) PS/2 Mouse Data Report:
a. In stream mode: A data report is sent at the end of a sample interval.
b. In remote mode: A data report is sent in response to Read Data command.
Page 20 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
c. Data report format:
Byte Bit Description
1 0 Left button status; 1 = pressed
1 Right button status; 1 = pressed
2 Middle button status; 1 = pressed
3 Reserved
4 X data sign; 1 = negative
5 Y data sign; 1 = negative
6 X data overflow; 1 = overflow
7 Y data overflow; 1 = overflow
2 0-7 X data ( D0 - D7 )
3 0-7 Y data ( D0 - D7 )
4 0-7 Z data :
D0 – D6,sign bit (3D mode)
D0 – D3,4th- ,5th button (5-button 3D mode)
(C) PS/2 mouse Data Transmission:
a. TP88X5/X3 generates the clocking signal when sending data to and receiving data from
the system.
b. The system requests TP88X5/X3 to receive system data output by forcing the DATA line
to an inactive level then allowing CLK line to go to an active level.
c. Data transmission frame:
Bit Function
1 Start bit ( always 0 )
2-9 Data bits ( D0 - D7 )
10 Parity bit ( odd parity )
11 Stop bit ( always 1 )
Page 21 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
d. Data Output (data from TP88X5/X3 to system ):
If CLK keep low (inhibit status), data will not transmit.
If CLK raised to high and DATA is low(request-to-send),data is updated.
After receiving data from system, TP88X5/X3 will not start transmitting until CLK
and DATA are both high.
If CLK and DATA are both high, the transmission is ready.
DATA is valid prior to the falling edge of CLK and beyond the rising edge of CLK.
During transmission, TP88X5/X3 check for line contention by checking for an inactive
level on CLK lasting for no more than 100m sec.
Contention occurs when the system lowers CLK to inhibit TP88X5/X3 output after
TP88X5/X3 has started a transmission. If this occurs before the rising edge of the tenth
clock, TP88X5/X3 internal store its data in its buffer and returns DATA and CLK to an
active level. If the contention does not occur by the tenth clock, the transmission is
completed.
Following a transmission, the system inhibits TP88X5/X3 by holding CLK low until it
can service the input or until the system receives a request to send a response from
TP88X5/X3.
e. Data Input ( from system to TP88X5/X3):
System first check if TP88X5/X3 is transmitting data. If TP88X5/X3 is transmitting,
the system can override the output by forcing CLK to an inactive level prior to the tenth
clock. If the transmission of TP88X5/X3 beyond the tenth clock ,the system must receive
the data.
If TP88X5/X3 is not transmitting or if the system choose to override the output, the
Page 22 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
system force CLK to an inactive level for a period of not less than 100u sec while preparing
for output. When the system is ready to output start bit (0), it allows CLK to go to active
level.
If request-to-send is detected, TP88X5/X3 clocks in 11 bits. Following the tenth clock,
TP88X5/X3 checks for an active level on the DATA line, and if found, force DATA low, and
clock once more.
If framing error occurs, TP88X5/X3 continue to clock until DATA is high, then clocks
the line control bit and request a Re-send.
When the system sends out a command or a data that requires a response, the system
must wait for TP88X5/X3 to response before sending its next output.
(D) PS/2 Mouse Error Handling:
a. A Re-send command ( FE ) following receipt of an invalid input or any input with
incorrect polarity.
b. If two invalid input are received in succession, an error code of hex FC will be sent to the
system.
c. The counter accumulators are cleared after receiving any command except “Re-send”.
d. As TP88X5/X3 receives a Re-send command ( FE ), it transmits its last packet of data.
e. In the stream mode ”Re-send” is received by TP88X5/X3 following a 4-byte data packet
transmission to the system. TP88X5/X3 re-send the 4-byte data packet prior to clearing
the counter.
f. A response is sent within 25 ms if
Page 23 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
(a) The system requires a response
(b) An error is detected during transmission
g. When a command requiring a response is issued by the system, another command should
not be issued until either the response is received or 25ms has passed.
(E) PS/2 Mouse Commands Description:
There are 16 valid commands that transmit between the system and TP88X5/X3. The “EA”
code is always the first response to any valid input received from the system other than a Set
Wrap Mode or Re-send command.
The following table lists the commands:
Hex Code Command TP88X5/X3 echo code
FF Reset FA,AA,00
FE Re-send XX,(XX,XX)
F6 Set Default FA
F5 Disable FA
F4 Enable FA
F3,XX Set Sampling Rate FA,FA
F2 Read Device Type FA,00(2D mode)/03(3D mode)/04(5-button 3D
mode)
F0 Set Remote Mode FA
EE Set Wrap Mode FA
EC Reset Wrap Mode FA
EB Read Data FA,XX,XX,XX,XX(3 XX in 2D mode)
EA Set Stream Mode FA
E9 Status Request FA,XX,XX,XX,XX(3 XX in 2D mode)
E8,XX Set Resolution FA,FA
E7 Set Autospeed FA
E6 Reset Autospeed FA
Page 24 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
The continuance command sequence below will activate 3-button 3D mode.
F3,XX
F3,XX
F3,XX
The continuance command sequence below will activate 5-button 3D mode.
F3,C8
F3,64
F3,50
F3,C8
F3,C8
F3,50
The following describes valid commands:
a. Reset ( FF )
TP88X5/X3 operation:
(a) Complete the reset.
(b) Transmit FA,AA,00 to the system.
(c) Set default:
sampling rate: 100 reports/s
non-autospeed
stream mode
4 counts/mm
disable
b. Re-send ( FE )
(a) Any time TP88X5/X3 receives an invalid command, it returns a Re-send command
to the
system.
(b) When TP88X5/X3 receives a Re-send command, it retransmits its last output. If the
Page 25 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
last
packet was a Re-send command, it transmits the packet just prior to the Re-send
command.
(c) In stream mode, if a Re-send command is received by TP88X5/X3 immediately
following
a 4-byte data packet transmission to the system, TP88X5/X3 will re-send the
4-byte data
packet prior to cleaning the count accumulators.
c. Set Default ( F6 )
The command reinitializes all conditions to the power-on defaults.
d. Disable ( F5 )
This command is used in the stream mode to disable transmissions from TP88X5/X3.
e. Enable ( F4 )
Enable transmissions, if in stream mode.
f. Set Sampling Rate ( F3,XX )
In the stream mode, this command sets the sampling rate to the value indicated by byte
hex XX, shown as follows:
Second byte XX Sample Rate
0A 10/sec
14 20/sec
28 40/sec
3C 60/sec
50 80/sec
64 100/sec
C8 200/sec
g. Read Device Type ( F2 )
TP88X5/X3 always echoes “ FA,00 “ in 2D mode, “FA 03” in 3D mode. “FA,04” in
Page 26 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
5-button 3D mode.
h. Set Remote Mode ( F0 )
Data value are reported only in response to a Read Data command.
i. Set Wrap Mode ( EE )
Wrap mode remains until Reset ( FF ) or Reset Wrap Mode( EC ) is received.
j. Reset Wrap Mode ( EC )
TP88X5/X3 returns to the previous mode of operation after receiving this command.
k. Read Data ( EB )
This command is executed in either remote or stream mode. The data is transmitted
even if there has been no movement or the button status is unchanged since the last
report. Following a Read Data command, the registers are cleared after a data
transmission.
l. Set Stream Mode ( EA )
This command sets TP88X5/X3 in stream mode.
m. Status Request ( E9 )
When this command is issued by the system, TP88X5/X3 responds with a 3-byte status
report as follows:
Byte Bit Description
1 0 1 = Right button pressed
1 1 = Middle button pressed
2 1 = Left button pressed
3 Reserved
4 0 = Normal speed, 1 = Autospeed
5 0 = Disabled, 1 = Enabled
Page 27 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
6 0 = Stream mode, 1 = Remote mode
7 Reserved
2 0-7 Current resolution setting ( D0 - D7 )
3 0-7 Current sampling rate ( D0 - D7 )
n. Set Resolution ( E8,XX )
TP88X5/X3 provides four resolutions selected by the second byte of this command as
follows:
Second Byte XX Resolution
00 1 counts/mm
01 2 counts/mm
02 4 counts/mm
03 8 counts/mm
> 4 & <64 Set Eled or Buzzer on time counter
< 125 & > 64 Set Eled or Buzzer off time counter
7C Select buzzer high byte
7D Select buzzer low byte
7E Select Eled1
7F Select Eled2
o. Set Autospeed ( E7 )
At the end of a sample interval in the stream mode, the current X and Y data values are
converted new values. The sign bits are not involved in this conversion. The
conversion is only in stream mode. The relationship between the input and output
count is as follows:
Input Output
0 0
1 1
2 1
3 3
Page 28 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
4 6
5 9
N( >=6 ) 2.0*N
p. Reset Autospeed ( E6 )
This command restore normal speed.
(G) BUZZER and ELED function:
There are three special function support difference application and can control
On/off independently by command F1/EF,select and set on/off time by option byte of
command E8.All legal command and option TP88X5 will answer “FA”.
Testing Mode Descriptions
Whenever “Test” pin is connected to logic 1, the chip will enter buyer's testing mode.
If RC = “0” (i.e. connect to GND)The X direction output signals of comparators will present to
“L” and “M” pin. Pressing "R" key can toggle the output from X direction to Y direction.
If RC = “1”(i.e. connect to VDD)The TP88X5/X3 will enter engineer testing mode.
Page 29 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
Absolute Maximum Ratings
Parameter Symbol min Max unit
Temperature under bias Top 0 50
Storage temperature Tst -65 150
Power dissipation Pdis --- 500 mW
Supply voltage Vcc 4.5 5.25 volt
DC Characteristics
Parameter Symbol Test condition min max unit
Supply voltage Vdd 4.4 5.25 V
Operating current Iop 20 mA
USB characteristics: (Note)
USB mode Suspended current Isu 480 uA
D+,D- Hi-Z state data line leakage Ilo 0v<Vin<3.3v -10 10 uA
D+,D- Differential input sensitivity Vdi |(D+)-(D-)| 0.3 V
D+,D- Differential common mode ran
g
Vcm 0.8 2.0 V
D+,D- Single ended receiver threshold Vse 0.8 2.0 V
D+,D- Static data line output low Vol RL of 1.5k to 3.6v 0.3 V
D+,D- Static data line output high Voh RL of 15k to Gnd 2.8 3.6 V
USB Transceiver capacitance Cin pin to Gnd 20 pF
PS/2 characteristics:
CLK,DATA positive-going threshold
Voltage Vt+ 3.2 3.8 V
CLK,DATA negative-going threshold
Voltage Vt- 1.2 1.9 V
DATA, CLK input current Idc pull up resistor
Vin=0V -0.6 1.8 mA
DATA, CLK low output voltage Vprl Iprl=4mA 0.4 V
Other characteristics:
X1,X2,Y1,Y2,Z1,Z2 input reference
Voltage (comparator mode) Virh 1.5 V
X1,X2,Y1,Y2,Z1,Z2 input linkage
Current Iil Vin = 0v 0 3 uA
L,M,R,4th ,5th input(pull-down) curren
t
Imi Vin=5v 18.6 56 uA
Page 30 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
L,M,R,4th ,5th input high voltage Vih Vdd=5v 3.5 V
L,M,R,4th ,5th input low voltage Vil Vdd=5v 1.5 V
Xtalin, L,M,R,4th ,5th input low Leaka
g
Current Iil Vin=0v,Vdd=5v 0 2.5 uA
Xtalin input leakage current Iih Vin=5v,Vdd=5v -2.5 uA
Note 1: All voltage measured from the local ground potential, unless otherwise specified.
Note 2: All timings use a capacitive load (CL) to ground of 50 pF, unless otherwise
specified.
Note 3: Excludes external resistor. In order to comply with USB Specifications
1.0, external series resistors of 24Ω±1% each on D+ and D- are recommended.
Note 4: Semi auto-reference circuit are used at X/Y/Z input to detect photo-coupled voltage and
generate digital pulses for caculating the movement of mouse.
AC Characteristics
Parameter Symbol conditions Min. Typ. Max. unit
USB D+, D- Driver characteristics:
Rise time
Fall time
Tdr
Tdf
Cl=50pf
Cl=300pf
Cl=50pf
Cl=300pf
75
-
75
-
-
300
-
300
ns
ns
ns
ns
Rise/fall time matching Trfm Tr/Tf 80 120 %
Output signal crossover voltage Vcrs 1.3 2.0 v
USB D+, D- Data source timings:
Low speed data rate Tdrate 1.477
5
1.5225 Mbs
Source differential driver jitter
To next transition
For paired transitions
Tudj1
Tudj2
ref Fig 1
-95
-150
95
150
ns
ns
Source EOP width Teopt ref Fig 2 1.25 1.50 us
Differential to EOP transition skew ref Fig 2 -40 100 ns
Receiver data jitter tolerance
To next transition
For paired transitions
Tdjr1
Tdjr2
ref Fig 3
-75
-45
75
45
ns
ns
EOP width at receiver 1.25 1.5 us
Page 31 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
Must reject as EOP
Must accept Teopr1
Teopr2 ref Fig 2 330
675 ns
ns
Mouse timings:
Rising Edge Crossed Width Tmr 15 us
Falling Edge Crossed Width Tmf 15 us
Mouse key debounce time Tkd 12 ms
PS/2 CLK, DATA timings:
Mouse CLK active time Tmca 44.8 us
Mouse CLK inactive time Tmci 44.8 us
System CLK active time Tsca 44.8 us
System CLK inactive time Tsci 44.8 us
Time that mouse sample DATA
from CLK rising edge Tmdc 14.9 us
Time from DATA transition to
Falling Edge of CLK Tsdc 14.9 us
Time from rising edge of CLK to
DATA T ransition Tscd 28.6 us
Time to mouse inhibit after the
11th CLK to ensure mouse does
not start another Transmission
Tpi 0 50 us
Oscillator timings:
Oscillating frequency Fosc 6-2% 6 6+2% MH
z
Note 1: All voltage measured from the local ground potential, unless otherwise specified.
Note 2: All timings use a capacitive load (CL) to ground of 50 pF, unless otherwise specified.
Note 3: Low Speed USB timings have a 1.5kΩ pull-up to 2.8V on the D- data line.
Note 4: The PS/2 AC timings are measured with 6 MHz system clock signal.
Page 32 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
Timing Waveforms
Tperiod
Crossover
Point
Consecutive
Transitions
N*Tperiod+Txjrl
Differential
Data Lines
Paired
Transitions
N*Tperiod+Txjr2
Fi gure 1 Dif fe rential Data Jitter
Tperiod
Crossover
Point
Differential
Data Lines
Diff.Data-to-
SE0 Skew
N*Tperiod+Txdeop
Figure 2 Differen tial to EOP Transit ion Skew and EOP Width
Sourc e EOP Width: Tfeopt
Tleopt
Receiver EOP Width: Tfeop r
Tleopr
Crossover Point
Extended
Tperiod
Differential
Data Lines
Consecutive
Transitions
N*Tperiod+Txjrl
Paired
Transitions
N*Tperiod+Txjr2
Txjr Txjr1 Txjr2
Figur e 3 Recei v er Jitter Toleran ce
Page 33 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
Page 34 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
I. Typical Application Circuit
Y2
Y1
X2
X1
Z2
Z1
B4
B5
L
M
R
LED
RC
XTAL1
XTAL2
VDD
VSS
D+
D-
BUZZER
ELED1 ELED2
+5V
D-
D+
GND
470K
0.1uF
100pF
7.5K 10~4K
10~4K
10uF
10~2.5K
10~4K
13
14
15
12
11
21
2
16
17
18
19
122
4
5
10
20
3
8
9
6
7
TP8825AP
A pplication C iruit I:Sem i Optical Input
CLK
5V
GND
DATA
Page 35 of 35 TOPRO CONFIDNETIAL 2003/7/31 Print
TP8833-35-15-25
USB+PS/2 3D 3/5Key
Mouse Controller
Y2
Y1
X2
X1
Z2
Z1
B4
B5
L
M
R
LED
RC
XTAL1
XTAL2
VDD
VSS
D+
D-
test
+5V
D-
D+
GND
470K
0.1uF
100pF
7.5K
10~4K
10uF
10~2.5K
12
13
14
11
10
20
1
15
16
17
18
2
3
4
9
19
7
8
5
6
TP8835AP
Application Ciruit I:Semi Optical Input
CLK
5V
GND
DATA