Datasheet

Section 14 Universal Serial Bus (USB)
Rev.7.00 Dec. 24, 2008 Page 531 of 698
REJ09B0074-0700
(1)
(2)
(3)
(4)
(5)
(6)
(7)
(8)
(9)
(10)
(11)
(12)
(13)
(14)
(15)
(16)
(17)
(18)
(21)
(22)
(19)
(20)
(23)
(24)
Specify IRQ6 to falling edge sensitive
(Set IRQ6E in IER to 1)
(Write IRQ6SCB and IRQ6SCA
in ISCRH to 01
Cancel USB module stop2 mode
(Clear MSTPB0 in MSTPCRB to 0)
Enter USB module stop 2 state
(Stop MSTPB0 in MSTPCRB to 1)
USB communication operations can be
restarted by using various USB registers
Clear SPRSi in UIFR3 to 0
Mask all interrupts with LDC instruction, etc.*
Set IRQ6E in IER to 1*
Unmask all interrupts with LDC instruction, etc.*
Enter power-down mode*
(Execute SLEEP instruction)
IRQ6 = Low (falling edge output)
Set IRQ6F in ISR to 1
Set SPRSi and SPRSs in UIFR3 to 1
Confirm SPRSs in UIFR3 as 1
Clear IRQ6E in IER to 0
*
Clear SPRSi in UIFR3 to 0
Detect USB bus suspend state
USPND pin = High
Procedure to enter power-down mode Procedure to cancel power-down mode
Detect USB bus resume
USPND pin = Low
All USB module internal clocks stop
USB module intenal clock operation starts
Wait 2 ms for USB operation clock
to stabilize
(Wait for CK48READY in UIFR3 is set to 1)
All LSI internal clocks stop
IRQ6 = High
IRQ6 = High
Cancel power-down mode
Wait for system clock stabilization time
(For external clok: 16 states min.)
(For crystal oscillator clock: 4 ms min.)
Enter active mode
(LSI internal clock starts oscillation)
IRQ6 = Low (falling edge output)
Set IRQ6F in ISR to 1
Set SPRSi of UIFR3 to 1
Clear SPRSs of UIFR3 to 0
Set CK48READY in UIFR3 to 1
(USB operating clock stabilized)
Detect SOF packet
Set SOF of UIFR3 to 1
: Indicates operations to be done
by firmware.
Guide to Flowchart Figures
: Indicates operations to be
automatically done by hardware
in this LSI.
Note: * Interrupts should be masked from when the IRQ6 interrupt is received until the SLEEP instruction is executed.
Finally, unmask the interrupts using the LDC instruction or the like and execute the SLEEP instruction immediately
afterward.
Figure 14.28 Flowchart