USB
USB Block Diagram
EP0: Only for Control Transfer
EP1、EP2: Only Support Interrupt IN
EP3: Support Interrupt IN and Interrupt OUT
USB register access control
Address
REGC
00E0H
USB_ADDR
00E1H
-
00E2H
USB_DI
UDI7
00E2H
USB_DO
UDO7
UDO6 UDO5 UDO4 UDO3 UDO2 UDO1 UDO0
USB_CTL:
REGC: 3.3V regulator control. 0: disable, 1: enable
URD: USB register read, writing 1 into this bit to read USB register (addressed by
USB_ADDR)
UWT: USB register write, writing 1 into this bit to write USB register (addressed by
USB_ADDR)
USB_ADDR: USB register address to be accessed
USB_DI: Data to be written into USB register (addressed by USB_ADDR)
USB_DO: Data read out from USB register (addressed by USB_ADDR)
Name
USB_CTL
Bit 7
Bit 6
-
-
UDI6
Bit 5
-
UA5
UDI5
Bit 4
-
UA4
UDI4
Bit 3
-
UA3
UDI3
Bit 2
-
UA2
UDI2
Bit 1
UWT
UA1
UDI1
Bit 0
URD
UA0
UDI0
R
√
√
-
√
W
√
√
√
-
The USB engine is an independent unit, which is Low-speed USB 1.1 version compliant, with
transceiver and 3.3V regulator built-in. The 3.3V regulator can be controlled by user program
through the USB_CTL.REGC control bit. The USB engine contains registers of its own, as
attached in next page. User can access the USB registers through the access control registers
provided here. The sequence to access USB register should be:
Write sequence:
Write the address of USB register to be accessed into USB_ADDR
Write 1 into USB_CTL.UWT
Write data into USB_DI
Write 0 into USB_CTL.UWT
MEGAWIN
MPC235 Data Sheet
17