phyCORE -LPC3250 QuickStart Instructions Using IAR's JLINK and the IAR EWARM Software Development Tool Chain Note: The PHYTEC Kit CD includes the electronic version of the English phyCORE-LPC3250 Hardware Manual Edition: September 2009 A product of a PHYTEC Technology Holding company
phyCORE-LPC3250 QuickStart Instructions In this manual are descriptions for copyrighted products that are not explicitly indicated as such. The absence of the trademark () and copyright () symbols does not imply that a product is not protected. Additionally, registered patents and trademarks are similarly not expressly indicated in this manual. The information in this document has been carefully checked and is believed to be entirely reliable.
Contents 1 Introduction to the Rapid Development Kit ........................................1 1.1 Rapid Development Kit Documentation ..........................................1 1.2 Overview of this QuickStart Instruction ...........................................1 2 System Description...............................................................................2 2.1 Hardware Description ......................................................................2 2.2 Host System Requirements..............
phyCORE-LPC3250 QuickStart Instructions © PHYTEC America LLC 2009 L-718e_2
Introduction 1 Introduction to the Rapid Development Kit The phyCORE System-on-Module (SoM) is designed to be plugged into a PHYTEC Carrier Board. The PHYTEC Carrier Board contains the I/O connectors as well as any other interface circuitry not provided on the phyCORE SoM itself. The phyCORE SoM, combined with the PHYTEC Carrier Board, provides a platform to jump start embedded designs and propel concept to prototype and finished product.
System Description 2 System Description 2.1 Hardware Description The following PHYTEC hardware components are included in the phyCORE-LPC3250 IAR Rapid Development Kit (KPCM-040-IAR) and are necessary for completing the instructions in this QuickStart: the PHYTEC phyCORE-LPC3250 (PCM-040) the phyCORE-LPC3250 Carrier Board (PCM-967) Bare PCB Expansion Board (PCM-988) AC adapter supplying 5 VDC /3.
phyCORE-LPC3250 QuickStart Instructions 2.3 The PHYTEC phyCORE-LPC3250 The phyCORE®-LPC3250 is an ARM-9 based, small form factor, OEMable module populated with the NXP LPC3250. State-of-the-art power management, Vector Floating Point Unit (VFP), and rich peripherals such as USB OTG, Ethernet, and integrated LCD controller make this module the ideal candidate for embedded applications requiring high performance and low power consumption.
System Description 2.5 Micrium µC/OS-II Real-Time Kernel The Micrium μC/OS-II Real-Time Kernel is a highly portable, ROMable, very scalable, preemptive real-time, multitasking kernel (RTOS) for microprocessors and microcontrollers.
phyCORE-LPC3250 QuickStart Instructions 3 Getting Started What you will learn with this Getting Started example: installing Rapid Development Kit software interfacing the phyCORE-LPC3250, mounted on the Carrier Board, to a host-PC using the IAR JLINK downloading example user code to the LPC3250 internal SRAM memory. 3.1 Installing Rapid Development Kit Software 3.1.
Getting Started 3.1.2 Installing IAR Embedded Workbench for ARM When you insert the IAR EWARM CD into the CD-ROM drive of your host-PC, the CD should automatically launch a setup program that installs the required software. Otherwise the setup program (.exe) can be manually executed from the root folder of the CD. Alternately, the IAR Embedded WorkBench https://www.iar.com ® for ARM Evaluation tools can be installed from: 1.
phyCORE-LPC3250 QuickStart Instructions 3. The IAR Product Registration page will open within a new Internet Browser window. Fill out your contact information and your registration. 4. You will receive a confirmation email from IAR. Follow the email instructions and confirm your registration to retrieve your License Number and License Key. 5. Select Install IAR Embedded WorkBench® 6. Follow the installation wizard for Installation of the IAR Embedded WorkBench®.
Getting Started 3.2 Interfacing the phyCORE-LPC3250 to a Host-PC Connecting the phyCORE-LPC3250, mounted on the phyCORE Carrier Board, to your computer is simple: 1. Ensure proper jumper settings on the phyCORE Carrier Board as indicated in phyCORELPC3250 Hardware Manual. 2. Connect the 2.54 mm pitch ribbon cable from the IAR JLINK JTAG adapter to the JTAG connector X12 on the phyCORE Carrier Board. 3.
phyCORE-LPC3250 QuickStart Instructions 3.3 Downloading Example Code with IAR EWARM The IAR Embedded WorkBench® IDE should have been installed as described in section 3.1.2. 1. Start the tool chain by selecting the IAR Embedded Workbench IDE from within the programs group: Start / IAR Systems / IAR Embedded Workbench for ARM Kickstart / IAR Embedded Workbench After you start the WorkBench®, the window shown below appears.
Getting Started The GettingStarted project shows basic use of CP15, I/O, timer, UART and the interrupt controllers. It starts by blinking LED_D15 and LED_D18 on the phyCORE Carrier Board. Button BTN1 changes the blinking speed while button BTN2 changes the pattern. The button action is displayed over UART5 routed to the bottom DB-9 connector at P1 using 115200 baud, 8-bit, 1-stop and no parity/flow control.
phyCORE-LPC3250 QuickStart Instructions If the data transfer was successful, a screen similar to the Disassembly window below will appear.. The Debug Toolbar is also displayed. In the lower part of the debug screen you will see the Debug Log window. You may need to open, resize and /or move some windows to make your screen look similar to the following screen capture. You can open inactive windows by choosing the desired window from the View pull-down menu. 7.
Getting Started You have successfully downloaded to the on-chip SRAM, executed and monitored user interaction on the phyCORE-LPC3250 hardware via the HyperTerminal window.
phyCORE-LPC3250 QuickStart Instructions 4 Debugging What you will learn with this example: how to familiarize yourself with simple debug functions provided by the IAR EWARM debug environment how to download example user code to the phyCORE-LPC3250 external SDRAM memory and go through a basic debugging exercise with use of a break point This Debugging section provides a basic introduction to the debug functions included in the IAR Embedded WorkBench®.
Flash Programming 4.2 Breakpoint Example The GettingStarted demo is configured for button BTN1 to change the blinking speed while button BTN2 will change the pattern. BTN1 is physically connected to GPI_3 and BTN2 is physically connected to GPI_2. The LPC3250 interrupt controller is configured to respond to GPI_3 and GPI_2. The interrupt controller will not respond to BTN1 or BTN2 if the interrupt controller is configured improperly.
phyCORE-LPC3250 QuickStart Instructions 7. From the IDE menu select Tools / Options. 8. From the IDE Options window select Editor and check Show line numbers. 9. You will now see the line numbers in the main.c file. 10. Locate the Gpi03_handler function starting on line 126: 11. Place the cursor anywhere in the Gpi03_handler function and place a break point by selecting the Toggle Breakpoint button in the IDE toolbar . 12. Execute the code by selecting the Go button from the debug toolbar .
Flash Programming 15. Locate the interrupt controller configuration code for GPI_3 beginning on line 282: 16. Change GPI_03 to GPI_04 on line 282-286. 17. Start the debugger and download the code by selecting the Download and Debug button from the IDE toolbar . 18. Execute the code by selecting the Go button from the debug toolbar . 19. Again locate the Gpi03_handler function. The breakpoint set in step 11 should still be in place: 20.
phyCORE-LPC3250 QuickStart Instructions 21. Return to the interrupt controller configuration code for GPI_3 beginning on line 282 and change GPI_04 back to GPI_03 and save changes: You have now successfully download example user code in the phyCORE-LPC3250 external SDRAM memory and gone through a basic debugging exercise with use of a break point.
Flash Programming 5 Flash Programming What you will learn with this example: how to use the IAR secondary bootloader for the LPC3250. downloading example user code to the external Flash memory 5.1 Secondary Bootloader IAR provides a secondary bootloader for the NAND Flash. To better understand the reasons for the need of a secondary bootloader on the LPC3250 a concise explanation of the boot process is presented below.
phyCORE-LPC3250 QuickStart Instructions 5.2 Loading Example to Flash 1. From the Embedded Workspace Configuration drop-down menu select the Debug xRAM boot from NAND512(64M) configuration as shown below: 2. This target will program both the secondary bootloader and the application code to the on-board NAND Flash. 3. Start a HyperTerminal session with the following COM settings: 115200 bps 8 bit No parity 1 bit stop No flow control 4.
Flash Programming 6 Getting More Involved What you will learn with this example: how to create a new project 6.1 Create a new Project For ease of creating a new project for the phyCORE-LPC3250 it is recommended that the given GettingStarted workspace is used as a template. The GettingStarted workspace already has project examples with the target, linker, compiler, debugger, and startup code correctly configured for the phyCORE-LPC3250 internal RAM, external SDRAM, and NAND Flash target.
7 Micrium uC/OS-II Demo What you will learn with this example: installing and downloading the µC/OS-II example demo enabling the µC/OS-II Kernel Awareness Plug-In in IAR EWARM using μC/Probe as a debugging and monitoring tool. 7.1 Installing the Example Files Code for µC/OS-II is provided in source form along with IAR EWARM project files that allows you to run µC/OS-II on the PHYTEC phyCORE-LPC3250 Rapid Development Kit. To install the software, simply run the self-extracting executable.
To build the code, select the Rebuild All menu item from the Project menu. To load the code through the JTAG debugger onto the connected evaluation board, select the Debug menu item from the Project menu.
7.3 Enabling the uC/OS-II Kernel Awareness When running the IAR C-Spy debugger, the μC/OS-II Kernel Awareness Plug-In can be used to provide useful information about the status of μC/OS-II objects and tasks. If the μC/OS-II Kernel Awareness Plug-In is currently enabled, then a μC/OS-II menu should be displayed while debugging. Otherwise, the plug-in can be enabled. Stop the debugger (if it is currently active) and select the Options menu item from the Project menu.
7.4 Running the Example Application The example projects include a basic demonstration of the µC/OS-II and µC/Probe. After you load the sample project to the phyCORE-LPC3250, the LEDs will start to blink. Text will be output to the lower RS-232 port (at 115200 baud) giving the state of the system as shown in the HyperTerminal screen capture below. The push buttons can be used to change the output to a new item.
7.5 Using the uC/Probe Example Workspace µC/Probe is a Windows program which retrieves the values of global variables from a connected embedded target and displays the values in an engineer-friendly format. To accomplish this, an ELF file, created by the user’s compiler and containing the names and addresses of all the global symbols on the target, is monitored by µC/Probe.
Next, select the RS-232 item in the options tree, and choose the appropriate COM port and baud rate. 1. Start Running. You should now be ready to run µC/Probe. Just press the run button ( ) to see the variables in the open data screens update. Figure 7-3 displays the phyCORE-LPC3250 IAR Rapid Development Kit data screen where the pushbuttons state and the serial output are being monitored.
You have now successfully installed and downloaded the µC/OS-II example demo, enabled the µC/OS-II Kernel Awareness Plug-In in IAR EWARM and used μC/Probe as a debugging and monitoring tool Published by PHYTEC America LLC 2009 Ordering No.