at89c5131 ATMEL Corporation, at89c5131 Datasheet - Page 120

no-image

at89c5131

Manufacturer Part Number
at89c5131
Description
8-bit Flash Microcontroller With Full Speed Usb Device At89c5131
Manufacturer
ATMEL Corporation
Datasheet

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
at89c5131-S3SIL
Manufacturer:
Atmel
Quantity:
10 000
Part Number:
at89c5131A-PUTUM
Manufacturer:
ATMEL/爱特梅尔
Quantity:
20 000
Part Number:
at89c5131A-RDTIL
Manufacturer:
Atmel
Quantity:
10 000
Part Number:
at89c5131A-RDTUL
Manufacturer:
Atmel
Quantity:
10 000
Part Number:
at89c5131A-RDTUM
Manufacturer:
ATMEL
Quantity:
5 000
Part Number:
at89c5131A-RDTUM
Manufacturer:
Atmel
Quantity:
10 000
Part Number:
at89c5131A-S3SIM
Manufacturer:
Atmel
Quantity:
10 000
Part Number:
at89c5131A-S3SUM
Manufacturer:
ATMEL
Quantity:
46
Part Number:
at89c5131A-UL
Manufacturer:
TI
Quantity:
12 500
Part Number:
at89c5131A-UL
Manufacturer:
ATMEL/爱特梅尔
Quantity:
20 000
Part Number:
at89c5131A-UM
Manufacturer:
TOSHIBA
Quantity:
1 200
Part Number:
at89c5131A-UM
Manufacturer:
ATMEL/爱特梅尔
Quantity:
20 000
Company:
Part Number:
at89c5131A-UM
Quantity:
300
Configuration
General Configuration
Endpoint Configuration
Figure 57. Endpoint Selection
118
Endpoint 0
Endpoint 6
AT89C5131
UEPSTA0
UEPSTA6
UBYCTH0
UBYCTH6
UEPCON0
UEPCON6
USB controller enable
Before any USB transaction, the 48 MHz required by the USB controller must be
correctly generated (See “Clock Controller” on page 19).
The USB controller will be then enabled by setting the EUSB bit in the USBCON
register.
Set address
After a Reset or a USB reset, the software has to set the FEN (Function Enable) bit
in the USBADDR register. This action will allow the USB controller to answer to the
requests sent at the address 0.
When a SET_ADDRESS request has been received, the USB controller must only
answer to the address defined by the request. The new address will be stored in the
USBADDR register. The FEN bit and the FADDEN bit in the USBCON register will
be set to allow the USB controller to answer only to requests sent at the new
address.
Set configuration
T h e C O N F G b i t i n t h e U S B C O N r e g i s t e r h a s t o b e s e t a f t e r a
SET_CONFIGURATION request with a non-zero value. Otherwise, this bit has to be
cleared.
Selection of an Endpoint
The endpoint register access is performed using the UEPNUM register. The
registers
These registers correspond to the endpoint whose number is stored in the UEP-
NUM register. To select an Endpoint, the firmware has to write the endpoint number
in the UEPNUM register.
UBYCTL0
UBYCTL6
UEPSTAX
UEPCONX
UEPDATX
UBYCTLX
UBYCTHX
UEPDAT0
UEPDAT6
UEPNUM
0
1
2
3
4
5
6
X
UEPSTAX
UBYCTHX
SFR registers
UEPCONX
UBYCTLX
UEPDATX
4136C–USB–04/05

Related parts for at89c5131