CY7C66113C-XC CYPRESS [Cypress Semiconductor], CY7C66113C-XC Datasheet - Page 19

no-image

CY7C66113C-XC

Manufacturer Part Number
CY7C66113C-XC
Description
Full-Speed USB (12 Mbps) Peripheral Controller with Integrated Hub
Manufacturer
CYPRESS [Cypress Semiconductor]
Datasheet
Document #: 38-08024 Rev. *B
5.2
The accumulator is the general-purpose register for the microcontroller.
5.3
The “X” register is available to the firmware for temporary storage of intermediate results. The microcontroller can perform indexed
operations based on the value in X. Refer to Section 5.6.3 for additional information.
5.4
During a reset, the Program Stack Pointer (PSP) is set to 0x00 and “grows” upward from this address. The PSP may be set by
firmware, using the MOV PSP,A instruction. The PSP supports interrupt service under hardware control and CALL, RET, and
RETI instructions under firmware control. The PSP is not readable by the firmware.
During an interrupt acknowledge, interrupts are disabled and the 14-bit program counter, carry flag, and zero flag are written as
two bytes of data memory. The first byte is stored in the memory addressed by the PSP, then the PSP is incremented. The second
byte is stored in memory addressed by the PSP, and the PSP is incremented again. The overall effect is to store the program
counter and flags on the program “stack” and increment the PSP by two.
The Return From Interrupt (RETI) instruction decrements the PSP, then restores the second byte from memory addressed by the
PSP. The PSP is decremented again and the first byte is restored from memory addressed by the PSP. After the program counter
and flags have been restored from stack, the interrupts are enabled. The overall effect is to restore the program counter and flags
from the program stack, decrement the PSP by two, and re-enable interrupts.
The Call Subroutine (CALL) instruction stores the program counter and flags on the program stack and increments the PSP by
two.
The Return From Subroutine (RET) instruction restores the program counter but not the flags from the program stack and
decrements the PSP by two.
5.4.1
The CY7C66x13C microcontrollers provide 256 bytes of data RAM. Normally, the SRAM is partitioned into four areas: program
stack, user variables, data stack, and USB endpoint FIFOs. The following is one example of where the program stack, data stack,
and user variables areas could be located.
5.5
The Data Stack Pointer (DSP) supports PUSH and POP instructions that use the data stack for temporary storage. A PUSH
instruction pre-decrements the DSP, then writes data to the memory location addressed by the DSP. A POP instruction reads
data from the memory location addressed by the DSP, then post-increments the DSP.
During a reset, the DSP is reset to 0x00. A PUSH instruction when DSP equals 0x00 writes data at the top of the data RAM
(address 0xFF). This writes data to the memory area reserved for USB endpoint FIFOs. Therefore, the DSP should be indexed
at an appropriate memory location that does not compromise the Program Stack, user-defined memory (variables), or the USB
endpoint FIFOs.
Notes:
After reset
8-bit DSP
(Move DSP
8-bit DSP
1.
2.
Refer to Section 5.5 for a description of DSP.
Endpoint sizes are fixed by the Endpoint Size Bit (I/O register 0x1F, Bit 7), see Table 19-1 .
8-bit Accumulator (A)
8-bit Temporary Register (X)
8-bit Program Stack Pointer (PSP)
Data Memory Organization
8-bit Data Stack Pointer (DSP)
[1]
)
8-bit PSP
Address
0x00
user selected
0xFF
User variables
USB FIFO space for up to two Addresses and five endpoints
Program Stack Growth
Data Stack Growth
CY7C66013C
CY7C66113C
Page 19 of 61
[2]
[+] Feedback
[+] Feedback

Related parts for CY7C66113C-XC