Advertisement

Quick Links

QuickStart Instructions
phyCORE-MPC565
Using Freescale CodeWarrior
Development Tool Chain
Note: The PHYTEC Spectrum CD includes the electronic version of
the phyCORE-MPC565 English Hardware Manual
Edition: September 2009
A product of a PHYTEC Technology Holding company

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the phyCORE-MPC565 and is the answer not in the manual?

Questions and answers

Summary of Contents for Phytec phyCORE-MPC565

  • Page 1 QuickStart Instructions phyCORE-MPC565 Using Freescale CodeWarrior Development Tool Chain Note: The PHYTEC Spectrum CD includes the electronic version of the phyCORE-MPC565 English Hardware Manual Edition: September 2009 A product of a PHYTEC Technology Holding company...
  • Page 2 PHYTEC Meßtechnik GmbH neither gives any guarantee nor accepts any liability whatsoever for consequential damages resulting from the use of this manual or its associated product. PHYTEC Meßtechnik GmbH reserves the right to alter the information contained herein without prior notification and accepts no responsibility for any damages which might result.
  • Page 3: Table Of Contents

    Getting Started .................. 13 2.1 Installing the Metrowerks CodeWarrior Tool Chain ....13 2.2 Installing Rapid Development Kit Software ......15 2.3 Interfacing the phyCORE-MPC565 to a Host-PC ..... 15 2.4 Launching the CodeWarrior IDE ..........19 2.4.1 Setting up a New Remote Connection ......19 2.5 Downloading Example Code with CodeWarrior IDE ....
  • Page 4 QuickStart Instructions © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 5: Introduction To The Phycore-Mpc565 Rapid Development Kit

    Introduction to the phyCORE-MPC565 1 Introduction to the phyCORE-MPC565 Rapid Development Kit This QuickStart provides: • general information on the PHYTEC phyCORE-MPC565 Single Board Computer • an overview of Freescale's CodeWarrior software development tool chain, and • instructions on how to run example programs on the phyCORE-MPC565, mounted on the PHYTEC Development Board, in conjunction with Freescale' CodeWarrior tools.
  • Page 6: Overview Of This Quickstart Instruction

    1.3 System Requirements Use of this "Rapid Development Kit" requires: • the PHYTEC phyCORE-MPC565, • the PHYTEC Development Board with the included DB-9 serial cable, DB-25 printer port cable and AC-to-DC adapter supplying 5 V DC/min. 1.5 A, • the PHYTEC Spectrum CD, •...
  • Page 7 Introduction to the phyCORE-MPC565 For more information and example updates, please refer to the following sources: http://www.phytec.com - or - http://www.phytec.de support@phytec.com - or - support@phytec.de http://www.freescale.com/ © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 8: The Phytec Phycore-Mpc565

    200-pin, high-density Molex connectors. In addition to the on-chip Flash (1 MByte), the phyCORE-MPC565 can be populated with up to 8 MByte of asynchronous standard Flash and up to 16 MByte of synchronous Burst-SRAM, addressable without wait states. Both memory device...
  • Page 9 Flash-EEPROM, 32-bit access C Memory: 4 kByte EEPROM (up to 32 kByte, alter- natively I C FRAM, I C SRAM) • Other Board-Level Features: Please contact PHYTEC for more information about additional module configurations. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 10 C Real-Time Clock with calendar and alarm function • power-down/wake-up support via RTC or external signal • JTAG/BDM/Nexus test/debug port • industrial temperature range (-40…+85°C) The phyCORE-MPC565 Development Board is fully equipped with all mechanical and electrical components necessary for the speedy and secure insertion...
  • Page 11 • reset and boot push buttons • Expansion Bus: address, data, interface and all applicable I/O signals route from implemented phyCORE module to 2 x 80-pin Molex connectors, enabling connectivity to PHYTEC Add-On hardware © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 12: The Metrowerks Codewarrior Development Tool Chain

    The editing and software debugging tools in CodeWarrior are state-of- the art and feature syntax highlighting, the power to evaluate structures and complex expressions in the debugger, and the ability to correct source code in the error message window. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 13: Figure 1: Freescale Codewarrior Ide Architecture

    Introduction to the phyCORE-MPC565 Freescale CodeWarrior consists of the IDE and Debugger core tools, which are structured as follows: IDE: Windows-based Integrated Development Environment housing the following tools: • Project Manager: shows the collection of files used to build an output file •...
  • Page 14 C code compiles to. The compiler and linker support *.elf and Freescale S-record output file formats. A map file is also generated, providing detailed memory map and module information. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 15 Mode), a hardware debugger module integrated on the processor. The parallel printer port of the host-PC communicates to the phyCORE via a BDM interface, such as the Macraigor Wiggler or the BDM signal conversion logic integrated on the PHYTEC Development Board.
  • Page 16 QuickStart Instructions © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 17: Getting Started

    What you will learn with this Getting Started example: • installing Freescale CodeWarrior for PowerPC Embedded Systems • installing the Rapid Development Kit software • interfacing the phyCORE-MPC565, mounted on the Development Board, to a host-PC • downloading example user code from a host-PC to the phyCORE-MPC565 on-board memory 2.1 Installing the Freescale CodeWarrior Tool Chain...
  • Page 18 Program Files for CodeWarrior on your host-PC. These files enable initialization of and communication to the PHYTEC phyCORE-MPC565 target hardware from within the CodeWarrior IDE. You need to enter the path ftp://ftp.phytec.de/pub/Products/ phyCORE-MPC565/CW8.7/ into your browser and then...
  • Page 19: Installing Rapid Development Kit Software

    Getting Started 2.2 Installing Rapid Development Kit Software The current version of the PHYTEC Tool-CD does not provide a setup program for automatic installation. You will need to manually copy the demos, manuals, and other support documents for this Rapid Development Kit to your local hard drive.
  • Page 20: Figure 2: Development Board Overview

    QuickStart Instructions P2B (top): B_CAN P1B (top): RS232_1 RESET BOOT P2A (bot): A_CAN P1A (bot): RS232_2 +5V Power Ethernet Figure 2: Development Board Overview © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 21: Figure 3: Default Jumper Settings Of The Phycore Development Board Pcm-991 With Phycore-Mpc565

    Getting Started • Configure the jumpers on the phyCORE Development Board as indicated in the figure below. This correctly routes the interface signals to applicable connectors and establishes signal connection between on-board peripherals and the phyCORE-MPC565 module. JP29 JP28 JP12...
  • Page 22: Figure 4: Power Connector

    MPC565 processor is waiting in debug mode. The phyCORE-MPC565 should now be properly connected via the Development Board to a host-PC and power supply and you are now ready to use the Freescale CodeWarrior tool chain to establish communication.
  • Page 23: Launching The Codewarrior Ide

    Example ftp://ftp.phytec.de/pub/ Products/phyCORE-MPC565/CW8.7/Hello_FL.zip to your hard disc. Navigate to C:\PHYBasic\phyCORE-MPC565\Demos, create the folder CW8.7 and decompress the example into this folder. • Launch the Freescale CodeWarrior IDE by double-clicking on the CodeWarrior icon or by selecting CodeWarrior from within the Programs\Freescale CodeWarrior\PowerPC 5xx V8.7\...
  • Page 24 QuickStart Instructions • In the IDE Preference Panels window, select Debugger -> Remote Connections. • Click on the Add button and enter the settings shown below in the New Connection window: © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 25 • Confirm by clicking the OK button. • You should now be able to view the new connection MSI Wiggler 0x10000000 in the Remote Connections window. • Confirm with the Apply button and click OK. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 26: Downloading Example Code With Codewarrior Ide

    • Enter a name such as "Connect to Com1" (be sure to use an available COM port for your system) and select an icon of your choice to establish a new connection using HyperTerminal. • Click OK to advance to the connection window. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 27 Data bits = 8; Parity = None; Stop Bits = 1; Flow Control = None. Not shown: Start Bits = 1. • Selecting OK advances you to the COM Direct – HyperTerminal monitoring window. Notice the connection status report in the bottom lower corner of the window. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 28 QuickStart Instructions HyperTerminal is now prepared to view the output of the example program once it is executed. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 29: Running The Hello_Fl.mcp Demo Project In Ram

    HyperTerminal session open and connected to the target hardware. • Open the Hello_Fl.mcp project file by selecting File \ Open from the pull-down menu and navigating to PHYBasic\phyCORE-MPC565\Demos\CW8.7\Hello_Fl. • The Hello_Fl.mcp project file will open in a project window. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 30 QuickStart Instructions If not already selected, select the software target "ram" from the pull- down at the top of the project window. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 31 • The Make process generates an output binary (ram.elf). The Make status window will appear within the CodeWarrior IDE while the project is being compiled and linked. Once complete the project window will be visible. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 32 Project / Run item in the main menu bar. • The following status window will appear during the download. • Once download is complete, you will advance to a more detailed project window that displays the source code in its lower panel. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 33 This will run the main code, starting from the location indicated by the blue arrow in the source window [first line after main()]. The lower portion of the ram.elf (Thread 0x0) window will indicate that the demo program is executing out of RAM. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 34 "UART_1> Hello world Running out of external SRAM (2x LED)" The red LED D6 will flash in a pattern with short on and long off intervalls. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 35 Getting Started • To end the debug session click on the Kill thread button at the top of the project window (or press <Shift>+<F5> or select Debug / Kill in the main tool bar). © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 36: Downloading Hello_Fl To The Mpc565 On-Chip Flash

    QuickStart Instructions 2.5.3 Downloading Hello_Fl to the MPC565 On-Chip Flash • Make sure Jumper JP17 on the phyCORE-MPC565 Development Board is closed at default position 1+2 (refer to Figure 3). • From the pull-down menu, at the top of the Hello_Fl.mcp project window, select the software target "rom".
  • Page 37 • Open the Flash Programmer window by selecting Tools / FlashProgrammer from the pull-down menu. The following window will appear: • Click on the Load Settings… button. • Browse to the phyCORE-MPC565_internal_flash.xml file located C:\Freescale\CodeWarrior EPPC V8.7\bin\ Plugins\Support\Flash_Programmer\EPPC folder and open the file. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 38 • Back in the Flash Programmer main window click on Erase/Blank Check. • Make sure both check boxes are enabled (as shown below) and click on the Erase button to erase the entire on-chip Flash memory. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 39 • If you wish you can do a Blank Check at the end of the Flash erase sequence to verify the Flash sectors are blank. Simply click on the applicable button. • Now go to the on Program/Verify section of the Flash Programmer window. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 40 PHYBasic\phyCORE-MPC565\Demos\CW8.7\Hello_Fl\Bin folder in the Select File to Program window. • Select the rom.mot file from the list of available files and Open it. The Flash Programmer window will reappear and should look like this: © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 41 Flash. • The Status: line shows the individual steps that are performed during the Flash download. • The following status line will appear at the end of the download sequence: © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 42 • Switch back to the HyperTerminal program to view the output of the demo program, which will print the character string, "UART_1> Hello world Running out of internal FLASH (3x LED)“ © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 43: Downloading Hello_Fl To The External Standard Flash (Pcm-019-1010E Only)

    2.5.4 Downloading Hello_Fl to the External Standard Flash (PCM-019-1010E Only) This example demonstrates burning code to the external standard Flash on the phyCORE-MPC565. The example program will be downloaded to the standard Flash devices at U5/U6 (AM29LV type). Note: This example only applies to phyCORE-MPC565 modules with part number PCM-019-1010E and the latest EPLD firmware.
  • Page 44 QuickStart Instructions • Click on the Load Settings… button • Browse to the phyCORE-MPC565_external_standard_flash.xml file located in PHYBasic\phyCORE-MPC565\Demos\CW8.7\Hello_Fl\ BurnExtRom folder and open the file. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 45 Getting Started • Click on Flash Configuration to check that the correct Flash device is as follows: • Click on Erase / Blank Check. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 46 Flash erasure. • If you wish you can do a Blank Check at the end of the Flash erase sequence to verify the Flash sectors are blank. Simply click on the applicable button. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 47 • Select the output file that will be downloaded into the external standard Flash. Click on the Browse… button in the upper right- hand corner of this window. • Navigate to the PHYBasic\phyCORE-MPC565\Demos\CW8.7\Hello_Fl\Bin folder in the Select File to Program window. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 48 Flash download. • The following status line will appear at the end of the download sequence: • If you wish to verify the Flash download simply click on the Verify button to start this procedure. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 49 • Switch back to the HyperTerminal program to view the output of the demo program, which will print the character string, "UART_1> Hello world Running out of external Flash (3x LED)" © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 50: Downloading Hello_Fl To The External Burst Flash (Pcm-019-3230 Only)

    2.5.5 Downloading Hello_Fl to the External Burst Flash (PCM-019-3230 Only) This example demonstrates burning code to the external burst Flash on the phyCORE-MPC565. The example program will be downloaded to the burst Flash devices at U3 (AM29BDD type). Note: This example only applies to phyCORE-MPC565 modules with part number PCM-019-3230.
  • Page 51 BurnExtRom folder and open the file. • After loading these settings, the Target Configuration window should look as follows: • Click on Flash Configuration to check that the correct Flash device is as follows: © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 52 QuickStart Instructions • Select the Erase/Blank Check from the Flash Programmer window. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 53 Flash erasure. • If you wish you can do a Blank Check at the end of the Flash erase sequence to verify the Flash sectors are blank. Simply click on the applicable button. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 54 • Select the output file that will be downloaded into the external burst Flash. Click on the Browse… button in the upper right-hand corner of this window. • Navigate to the PHYBasic\phyCORE-MPC565\Demos\CW8.7\Hello_Fl\Bin folder in the Select File to Program window. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 55 • Select the rom.mot file from the list of available files and Open it. The Flash Programmer window will reappear and should look like this: • Now click on the Program button to start downloading the rom.mot file into the on-chip Flash. © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 56 • Click No when you are prompted to save these new settings. You have now successfully downloaded the Hello_Fl example program to the external burst Flash on the phyCORE-MPC565. • Disconnect the power adapter from Development Board. • Disconnect the DB-25 parallel cable.
  • Page 57 Getting Started • Switch back to the HyperTerminal program to view the output of the demo program, which will print the character string, "UART_1> Hello world Running out of external FLASH (3x LED)" © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 58: Creating A New Project

    QuickStart Instructions 2.6 Creating a New Project For ease of creating a new project for the phyCORE-MPC565 it is recommended that the given Hello_Fl project is used as a template. The Hello_Fl project already has the target, linker, compiler,...
  • Page 59 How would you improve this manual? Did you find any mistakes in this manual? page Submitted by: Customer number: Name: Company: Address: Return to: PHYTEC Technologie Holding AG Postfach 100403 D-55135 Mainz, Germany Fax : +49 (6131) 9221-26 © PHYTEC Meßtechnik GmbH 2009 L-647e_2...
  • Page 60 Published by © PHYTEC Meßtechnik GmbH 2009 Ordering No. L-647e_2 Printed in Germany...

Table of Contents