Embest EB-SAM3U User Manual

EB-SAM3U Development Board User Guide
Rev. 1.1
Release: 2011-07-26
Embest info & Tech Co., Ltd.
Address:509 Room, Luohu Sci&T ech Edifice, No.85, T aining R oad, Luohu
Zone, Shenzhen Telephone: 86-755-25504951 25505451 25532557 Fax: 86-755-25616057 E-mail: sales.cn@embedinfo.com
support.cn@embedinfo.com
Website: http://www.embedinfo.com http://www.embed.com.cn
AT91SAM3U4 Chips Based on Atmel
ARM Cortex-M3 Kernel
The EB-SAM3U board is a new evaluation board based on Atmel corp. AT91SAM3U se r i e s p r o s e s s o r s . The board features rich interfaces,which not only provides a good platform for application development,but also is the first choice for learners. Combining with our company's debugging tools ULINK2, it will offer your a better development environment for saving time and improving efficiency.
Deliverables
The EB-SAM3U toolkit contains the following items:
1.a EB-SAM3U board
2.power supply
3.universal input AC/DC power supply with US, Europe and UK plug adapters
4.one 3V Lithium Battery type CR1225
5.one USB cable
目录
CHAPTERIJUMPERS........................................................................................1
CHAPTERIIEVALUATIONKITHARDWARE...............................................................2
2.1BoardOverview..................................................................................................2
2.2EBSAM3UBlockDiagram.................................................................................4
2.3Processor............................................................................................................4
2.4Memory..............................................................................................................4
2.5ClockCircuitry....................................................................................................5
2.6ResetandWakeUpCircuitry............................................................................5
2.7PowerSupplyandManagement.......................................................................5
2.8UART..................................................................................................................5
2.9USART................................................................................................................5
2.10LEDs.....................................................................................................................6
2.11LCD,BacklightControlandTouchPanel............................................................6
2.12JTAG....................................................................................................................7
2.13AudioCodec........................................................................................................7
2.14USB......................................................................................................................7
2.15ADC......................................................................................................................8
2.16UserButtons.......................................................................................................8
2.17TemperatureSensor.........................................................................................8
2.18SDCard................................................................................................................9
2.19HardwareTesting...............................................................................................9
CHAPTERIIISOFTWAREDEVELOPMENTANDEXAMPLES..........................................10
APPENDIXA:AFTERSALESERVICE...................................................................13
- 1-
www.embedinfo.com/en
Chapter I Jumpers
The EB-SAM3U board jumpers are used for many purposes such as internal Flash Memory reinitialization, power current measurement and other configurations.
Table 1. Jumpers Setting
Label Default
Setting
Feature
JP1 ERASE Open Close it to reinitialize the Fla s h content and some
of its NVM bits. This jumper must be closed for more than 220 ms at power-up to perform the reinitialization.
JP2 TEST Not
populated
(open)
reserved
JP3 VBU Close JP4 FORCE
POWER ON
Open Close to force +3V3 LDO output valid
JP5 Not
populated
(open)
Close to enable 50-Ohm terminal resistor for AD12BAD3 BNC port
JP6 Not
populated
(open)
Close to enable 50-Ohm terminal resistor for AD0 BNC port
JP7 ADVREF Pin1 Pin2
close,Switch
to +3V3
Select the reference voltage of the 10-bit ADC to be either 3.3V (close 1-2) or 2.5V (close 2-3)
JP8 AD12BVREF Pin1 Pin2
close,Switch
to +3V3
Select the reference voltage of the 12-bit ADC to be either 3.3V (close 1-2) or 2.5V (close 2-3)
www.embedinfo.com/en
2/16
Chapter Evaluation Kit Hardware
2.1 Board Overview
Table 2. A List of Hardware Interfaces
J1 TFT LCD Connector J2 UART DB9 male connector J3 USART DB9 male connector J4 HEADPHONE LINE-OUT J5 Audio LINE-IN J6 MONO/STEREO MICRO INPUT J7 SD/MMC Socket J8 USB Device(B-type) interface J9 JTAG interface J10 Power +5V J11 Power supply by USB J12 external pins(at the back of the board) J13 external pins(at the back of the board)
www.embedinfo.com/en
3/16
CN1 BNC interface1 supporting ADC12B CN2 BNC interface2 supporting ADC0 MN1 SAM3 chip MN2 PSRAM MN3 NAND Flash(under the LCD) MN4 Touch Screen controller(under the LCD) MN5 RS232 Transceiver 1 MN6 RS232 Transceiver 2 MN7 WM8731 CODEC(under the LCD) MN8 Temperature Sensor MN9 USB Slave Device interface MN10 Voltage Regulator MN11 LM4040-2.5 PNP BP1 NRST button BP2 USR-LEFT button BP3 NRSTB button BP4 FWUP button BP5 USR-RIGHT button
www.embedinfo.com/en
4/16
2.2 EB-SAM3U Block Diagram
2.2.3 Processor
The EB-SAM3U is equipped with a AT91SAM3U in LQFP144 package.
4 Memory
The AT91SAM3U chip embeds:
· 256 Kbytes of embedded Flash
· 48 Kbytes of embedded SRAM with dual bank
· 16 Kbytes of ROM with embedded bootloader routines (UART, USB) and IAP (In-Application Programming functions) routines. The AT91SAM3U features an External Bus Interface (EBI) that permits interfacing to a broad range of external memories and virtually to any parallel peripheral. The EB-SAM3U board is equipped with two kinds of memory devices connected to the SAM3U4E EBI:
· One PSRAM (Micron MT45V512KW16PEGA 512K*16,48-ball VFBGA), 16 bits data interface
· One NAND-Flash MT29F2G16ABD.
www.embedinfo.com/en
5/16
2.
2.
2.
2.
2.
5 Clock Circuitry
The clock generator of a AT91SAM3U microcontroller is made up of:
· A Low Power 32,768 Hz Slow Clock Oscillator with bypass mode
· A 3 to 20 MHz Crystal Oscillator, which can be bypassed (12 MHz needed in case of USB)
· A factory programmed fast internal RC Oscillator. 3 output frequencies can be selected: 4, 8 or 12 MHz (default value is 4 MHz).
· A 480 MHz UTMI PLL providing a clock for the USB High Speed Device Controller
· A 96 to 192 MHz programmable PLL (input from 8 to 16 MHz), capable of providing the clock MCK to the processor and to the peripherals. The EB-SAM3U board is equipped with one 12 MHz crystal, one 32,768 Hz crystal and an external clock input connector (optional, not populated by default).
6 Reset and Wake-Up Circuitry
The on-board NRST button BP1 and NRSTB button BP3 provide the AT91S AM3U with external reset control.The on-board WAKE-UP button BP4 can be used to wake up the chip from low power modes.
7 Power Supply and Management
The EB-SAM3U board is supplied with an external 5V DC block through input J10. It can also be powered by USB, close J11 to the right hand.
8 UART
The Universal Asynchronous Receiver Transmitter features a two-pin UART that can be used for communication and trace purposes. It offers an ideal channel for in-situ programming solutions. This UART is associated with two PDC channels to reduce the processor time on packet handling. This two-pin UART (TXD and RXD only) is buffered through an RS232 Transceiver MN5 and brought to the DB9 male connector J2.
9 USART
The Universal Synchronous/Asynchronous Receiver Transmitter (USART) provides one
www.embedinfo.com/en
6/16
full duplex universal synchronous/asynchronous serial link. The data frame format is extensively configurable (data length, parity, number of stop bits) to support a broad range of serial communication standards. The USART is also associated with PDC channels for TX/RX data access. There are 3 USARTs on the SAM3U4E device, EB-SAM3U connects the USART1 bus (including TXD, RXD, RTS, CTS handshake signals control) to the DB9 male connector J3 through the RS232 Transceiver MN6.
2.2.10 LEDs
There are three LEDs on the EB-SAM3U board:
· D3 and D4green LEDs are user defined and controlled by the GPIO.
· D5 red LED is a power LED indicating that the 3.3V rail is enabled. It can also be controlled by the GPIO (by default, the GPIO is disabled and an on-board pull-up to 3.3V lights the LED).
11 LCD, Backlight Control and Touch Panel
EB-SAM3U carries one TFT/Transmissive LCD module with touch screen, FTM280C12D, with integrated driver IC HX8347. The LCD display size is 2.8 inches, with a native resolution of 240 x 320 pixels.
Table 3. LCD Module Pin Out
Pin Symbol Function
1 GND Ground 2 CS Chip Select 3 RS Register select signal 4 WR Write operation signal 5 RD Read operition signal
6~21 DB0~DB15 Data bus
22~23 NC No connection
24 RESET Reset signal 25 GND Ground 26 X+ Touch panel Y_RIGHT 27 Y+ Touch panel Y_UP 28 X- Touch panel Y_LEFT 29 Y- Touch panel Y_DOWN 30 GND Ground 31 VDD1 Power supply for digital IO Pad
32 VDD2 Power supply for analog circuit 33~36 A1~A4 Power supply for backlight 37~38 NC No connection
39 K Backlight ground
www.embedinfo.com/en
7/16
2.2.12 JTAG
A standard 20-pin JTAG connector is implemented on the EB-SAM3U for any ARM JTAG emulator connection, such as SAM-ICE. Note that the NRST net is connected to the system button BP1, and is also used to reset the LCD module. 0-Ohm resistor R75 may be removed in order to isolate the JTAG port from the system reset signal.
13 Audio Codec
The EB-SAM3U includes a WOLFSON codec WM8731 for digital sound input and output. This interface includes audio jacks for:
· microphone input,
· line audio input,
· headphone output. The AT91SAM3U programmable clock output is used to generate the WM8731 master clock (MCLK). The AT91SAM3U ODT (On-Die Termination) feature guarantees a signal integrity on this clock line without the need for external discrete components. WM8731 pin 21 MODE is pulled down by default; this configures the device as a TWI device for internal register access. Pin15 CSB is pulled up, which sets its TWI address as 33 [0x0011011]. The WM8731 digital interface works in slave mode on the AT91SAM3U Synchronous Serial Controller (SSC) interface, which means that Codec digital audio bit clock and ADC/DAC left/right control clock are to be generated by the AT91SAM3U.
Figure 1. Codec Slave Mode
2.14 USB
The AT91SAM3U UDPHS port is compliant with the Universal Serial Bus (USB) rev 2.0 High Speed device specification. J8 is a B-type receptacle for USB device.
www.embedinfo.com/en
8/16
2.15 ADC
There are 8 multiplexed analog channel inputs on the 12-bit ADC, and 8 multiplexed analog channel inputs on the 10-bit ADC. EB-SAM3U optionally connects the two ADC channels to BNC header (check for your actual components implementation, schematics and BOM. One is 12-bit ADC channel 3, shared with PIO pin PB4. The other one is 10-bit ADC channel 0, shared with PIO PB5.
A potentiometer is also connected to these two channels to implement an easy access to ADC programming and debugging (or implement an analog user control such as display brightness, volume, etc.). Please note that EB-SAM3U default setting connects both AD12BAD3 and AD0 to the potentiometer so that AD12BAD3 and AD0 are actually shorted. If these two ports need to work separately, R82 and/or R84 should be removed.
Figure 2. ADC Input
2.2.16 User Buttons
2 user buttons on the EB-SAM3U are connected to PIO lines, and are defined as left and right buttons by default.
17 Temperature Sensor
A temperature sensor MCP9800 is connected to the AT91SAM3U TWI bus. This device also features an open-drain output ALERT pin. The device outputs an alert signal when the ambient temperature goes beyond the user-programmed temperature limit.
www.embedinfo.com/en
9/16
Note that the 0-Ohm resistors R15 and R16 have been implemented to offer a disconnection possibility (freeing these dedicated PIO lines for other custom usage).
2.2.18 SD Card
The EB-SAM3U has an MMC/MMCPlus high-speed 8-bit multimedia interface. This interface is used as a 4/8-bit interface, connected to an 8-bit SD/MMC card slot with card detection.
19 Hardware Testing
T able 4. Routine Introduction of EB-SAM3U Evaluation Board
Experiment
Name
Function Description
NVIC Turn on LED lights according pushing USR-LEFT of USR-RIGHT button. DMA DMA transfers datas from memory to memory working on Link List Mode. PDC In this experiment, PDC module (peripheral DMA controller) obtains serial data
from DBGU,stored in the data array, and finally displayed.
USART Send a message using USART. Display them through PC HyperTerminal.
You can also send data or files according PC HyperTerminal. USART can receive them, display the transfer size per second and total transfer size.
PWR You can control board working in four different power modes (Sleep Mode,
Active Mode, Wait Mode, Backup Mode) by pressing different keys according PC HyperTerminal. You can also wakeup it by pu shing USR-LEFT button when it working in SLEEP MODE and WAIT MODE, by pushing FWUP button when it working in BACKUP MODE.
GPBR Write in values to four corresponding backup registers. And then software reset
the entire processor and peripherals. At the next restart, display the value of the four back-up registers in HyperTerminal,and compare them with the values writen in previously. If there is no difference between them, LED(D2) will blink,else,LED(D3) will blink.
RTT You can set the pre-divider value, as well as the RTT alarm value in this
procedure. It will generate a alarm interrupt as soon as RTT counter reach the value set previously.
RTC This experiment can detect the RTC time and date, displaying the time the date,
setting time and date.
WDT Let watchdog can genetate a interrupt when it’s counter value reach zero or there
is a error occurred according configuring its mode register. NOTE:don’t reset the system. It will generate a interrupt if you haven’t re-set a appropriate value to the corresponding regsiter before the cut-off time.
PWM This procedure sets up PWM channel 0, channel 1 and channel 2. You can view
the output value of channel 0 according PA7 of PB0,view the output value of channel 1 according PA9 or PB2. Positive pulses of Channel 0, Channel 1 and Channel 2 are as the inputs of D2,D3 and D4(LED) respectively. You can also configure the channel according the serial port .
ADC This experiment tests ADC0 and ADC12B and show the voltage values from the
four-channel ADC pins. You can configure the values of GAIN,Bias Current,Mode,and Sampel Offset.
EEFC To achieve the reading and writing,latches, GPNVM settings, and erase within
two FLASH.
www.embedinfo.com/en
10/16
NandFlash Read and write to external NANDFLASH according SMC. SRAM Test the external SRAM. Read and write it. If success,D2 lights,else D3 lights. TIM This procedure mainly tests TC module of the board. Configure TC working in
Waveform Mode. RA=0x1000. It will generate interrupt and turn on LED light when generating Comparing matchs.
HSMCI This procedure tests the HSMCI interface by using a SD card with FAT32 file
system. It can format the SD card, write in a bin file, read it and compare its contents with the contents writen in previously.
SSC This sample can play the WAV file, related Information can display in
HyperTerminal.The WAV file must be 48KHz samplerateTwo-channel stereo, and Previously stored in the SD card. SSC interface connected to WM8731,can send audio data to WM8731,which decode simply and play. You can hear the music by using a headphone.
SPI Achieve the communication between SPI interface and touch-screen controller.
Touch-screen controller can receive the commands sent from SPI interface and Feedback the corresponding data to SPI.
Touchscreen The main function of this routine is to obtain the coordinates of the touch-point
on the touch screen, and print it in the serial port and LCD screen. LCD LCD display routines. It can display characters, text, graphics and so on. TWI This procedure test Temp.Sensor according TWI. It can read the values of the
sensor internal registers, access to the current configuration, and get the current
temperature value. UDPHS This is a USB mass-storage test case.There are two DISK sample in this project,
one for Extended SRAM addressed from 0x60000000(size: 512KB),one for SD
Card inserting on the SD/MMC socket of the board. USB_CDC This procedure achieves the USB Communication Device class(CDC) serial
communication test. RTX_Traffic BLINKY test case based on RTX operating system. It simulates the changes of
traffic lights at a crossroads.
Chapter Software development and examples
Example operation sequencetake ADC character display for example
1. Open ADC folder , Enter ADC folder, double-click adc.Uv2 project file,then will open this project file.
2. Project file include StartUp Code(storage area of startup codes), Source Code(storage area of main source program codes, System Code(program library source files)and Documentationprogram document descriptionfolders.
3. Connect the power line and emulator wire to the board (between ULINK2 and JTAG.
4. Click Flash/Download to download the image as follows:
www.embedinfo.com/en
11/16
or click the shortcut icon: to download the image.
5. After download, execute Debug/Start/Stop Debug Session(Ctrl+F5) to debug as follows
or click shortcut con to start debug.After click, assembly code will show in the main workspace, if you want to see source code, you can right click mouse before Step, choose “Show Source Code for current Address” As follows
click it
www.embedinfo.com/en
12/16
source code will appear in the workspace
6. You can make use of the debug shortcut icon in the window to execute debug process, the icon as follows
13/16
www.embedinfo.com/en
Appendix A: After-sale Service
Embest is at your service, and we have special Technical Support Engineers to provide support and consultation in forms of telephone,E-mail,Fax and so on.
• TEL:0755-2550 9834
• FAX:0755-2561 6057
• Special E-mail of Technical Support Engineers:
o Technical Support for ARM development tools:support@embedinfo.com o Technical Support for RealView MDK tools:support.realview@embedinfo.com
• Embedded Technical Forum: http://bbs.embedinfo.com, Our Technical Support Team will correspond to your questions about all kinds of evaluation board as soon as possible.
Loading...