
iXPeRiPheRaLMoDuLes7(usB):usBFunCtionContRoLLeR(usB)
s1C33L17teChniCaLManuaL
ePson
iX-1-3
IX
USB
iX.1.3usBoperatingClocksandDMaRegisters
iX.1.3.1ControllingtheusBClocks
The CMU provides the clock paths with a control bit shown below for the USB module. The clock supply turns on
when the control bit is set to 1 and it turns off when the control bit is set to 0.
(1)usBclock(usB_CLK)
This clock (OSC3 = 48 MHz) is used for the USB interface module. USB_CKE (D8/0x301B00) is used for
clock supply control (default: off).
(2)Controlregisterclock(usBsaPB_CLK)
This clock (MCLK) is used to control the USB registers located in area 6. This clock is required for accessing
the USB registers and the DMA area, and it can be stopped otherwise. USBSAPB_CKE (D9/0x301B00) is used
for clock supply control (default: off).
note: The Gated Clock Control Register 0 (0x301B00) is write-protected.To rewrite this register and
other CMU control registers at addresses 0x301B00 to 0x301B14, write protection must be
removed by writing 0x96 to the Clock Control Protect Register (0x301B24). Since unnecessary
rewritestoaddresses0x301B00to0x301B14maycausethesystemtooperateerratically,make
sure that data set in the Clock Control Protect Register (0x301B24) is other than 0x96 unless
rewritingsaidregisters.
iX.1.3.2settingtheMiscRegister
1. USBWT[2:0] (D[2:0])/USB Wait Control Register (0x300012)
USBWT[2:0] (D[2:0]/0x300012) used to set the number of wait cycles to be inserted when accessing the USB
registers.
TableIX.1.3.2.1NumberofWaitCyclesduringUSBAccess
usBWt2
1
0
usBWt1
1
0
1
0
usBWt0
1
0
1
0
1
0
1
0
numberofwaitcycles
(inunitsofMCLKcycles)
7cycles
6cycles
5cycles
4cycles
3cycles
2cycles
1cycle
0cycles
MCLKclock
frequency
Lessthan60MHz
Lessthan56MHz
Lessthan45MHz
Lessthan36MHz
Lessthan24MHz
Lessthan16MHz
Lessthan8MHz
(Default:0b111=7cycles)
The number of wait cycles should be set according to the MCLK clock frequency.
2. USBSNZ (D5)/USB Wait Control Register (0x300012) = 0
This disables the USB snooze control.
The OSC3 oscillator circuit must be turned on before the USB function controller can be used. Refer to “III.1
Clock Management Unit (CMU)” and “III.4 Misc Registers” for details of the clock control.