MCBSTM32F200/400 User's Guide: MCBSTM32F200/400 User's Guide

Keil, An ARM® Company MCBSTM32F200/400 User's Guide

The MCBSTM32F200 User's Guide describes the MCBSTM32F200 Evaluation Board and contains detailed operating instructions for the hardware.

  • Introduction gives an overview of the MCBSTM32F200 Board, the features, hardware and software requirements, where to find information quickly, and where to find Technical Support.
  • Setup shows the MCBSTM32F200 Board components, how to connect, configure, and use the board, and describes the jumpers.
  • Theory of Operation explains the components of the MCBSTM32F200 board in detail.
  • Writing Programs describes how to write programs, download to flash, and configure your project for debugging for the MCBSTM32F200 board.
  • Example Programs lists the example programs available on the installation CD and on the Keil website. There are step-by-step instructions on building and running the BLINKY example programs.

  • The statements made in this manual are valid for both boards, the MCBSTM32F200 and MCBSTM32F400, unless a differentiation is made explicitly. Both use the same base board and on-chip peripherals. Only the MCUs differ.

Revision History

  • August 2011: Initial revision.
  • August 2013: Correct J6 jumper description.
  • June 2014: Updated for MDK V5.

Copyright © Keil, An ARM Company. All rights reserved.


MCBSTM32F200/400 User's Guide: Debugging with ULINK

Debugging with ULINK

Follow these steps to program debugging using the µVision Debugger and the ULINK USB-JTAG Adapter. Detailed information can be found in the µVision User's Guide in the Creating Applications chapter.

  1. Connect the ULINK to the JTAG connector of the MCBSTM32F200 Board. Note that the red cable marks pin 1 of the JTAG-connector.

    MCBSTM32F200 Board with ULINK2

  2. Power up the MCBSTM32F200 Board.
  3. Configure the Debugger in the Project — Options for Target — Debug dialog.

    Options for Target Button Use the Options for Target toolbar button and click the Debug tab to display the Debug dialog.

    Use: ULINK Cortex Debugger Select Use: and ULINK Cortex Debugger in the drop-down to choose the ULINK USB-JTAG Adapter as the debugging tool.

    Debug Load & Run Options Check the Load Application at Startup and the Run to main() options to load your application and execute code up to the beginning of your main() function when the debugger starts.

  4. Click the Settings button to open the Cortex-M Target Driver Setup dialog.

    This dialog displays the IDCODE of the ARM device on the MCBSTM32F200 Board.

    JTAG Interface Options Check the SWJ checkbox and select the SW option under Port to use the Single Wire mode interface. Max Clock should be set to 1MHz.

    Download Options Select the Verify Code Download option under Download Options to compare the loaded application program with the Flash ROM content. You may disable this option to speed up the debugger start.

  5. Start the Debugger.

    Start/Stop Debug Button Use the Start/Stop Debug Session toolbar button to start debugging the program.

    Or

    Use the µVision command, Debug — Start/Stop Debug Session, to start debugging the program.


MCBSTM32F200/400 User's Guide: Debugging Programs

Debugging Programs

µVision IDE offers a very powerful and comprehensive set of debugging tools designed to make program testing easier and reduce the time it takes to produce a working application.

The required steps for configuring the debugger on the MCBSTM32F200 board are described in the topic Debugging with ULINK.

You may debug your application software via the CoreSight debug port, for example, by connecting the Keil ULINK USB-JTAG Adapter to the JTAG interface.

Using the µVision debugger and the CoreSight debug port capability of the MCBSTM32F200, you may set breakpoints and step through your code, and also view the status of on-chip peripherals using the Peripheral dialogs custom-designed for the STM32F207IG device.


MCBSTM32F200/400 User's Guide: BLINKY

BLINKY

The BLINKY example program toggles the LEDs sequentially. The toggle speed of the LEDs is based on a 10ms system clock interrupt..

The BLINKY example project demonstrates assembling, compiling, linking, downloading, and debugging using the µVision IDE on the MCBSTM32F200 board. The on-board LEDs make it easy to visually verify that the program loads and executes properly.

Loading BLINKY with MDK V4

To load the BLINKY project, select Open Project from the Project menu and open BLINKY.UVPROJ from the following folder:

  • \KEIL\ARM\BOARDS\KEIL\MCBSTM32F200\BLINKY\

Open Project dialog

Project Workspace When the BLINKY project opens, the µVision Project Workspace window displays the source files that make up the project.

  • startup_stm32f2xx.s contains the CPU startup code for the STMicroelectronics STM32F2xx devices.
  • system_stm32f2xx.c configures system clock and external memory setup options.
  • Blinky.c contains the application modules that set up the system interrupt and toggles the LEDs.
  • LED.c, contains the functions to initialize and manipulate the GPIO ports that control the on-board LEDs.

The Abstract.txt file contains documentation about the project.

Loading BLINKY with MDK V5

To load the BLINKY project, select Open Project from the Project menu and open BLINKY.UVPROJ from the folder where you copied the example.

Project Workspace When the BLINKY project opens, the µVision Project Workspace window displays the source files that make up the project.

  • STM32F2xx_OPT.s file allows you to easily set the Flash read and write protection options for the device for the STMicroelectronics STM32F2xx devices.
  • STM32F2xx_OTP.s allows you to configure the Flash one-time programmable area at the block or byte level for the STMicroelectronics STM32F2xx devices.
  • Blinky.c contains the application modules that set up the system interrupt and toggles the LEDs.
  • The Abstract.txt file contains documentation about the project.
  • LED.c, contains the functions to initialize and manipulate the GPIO ports that control the on-board LEDs.
  • GPIO_STM32F2xx.c contains the GPIO interface code for the STMicroelectronics STM32F2xx devices.
  • RTE_Device.h contains the CPU startup configuration for the STMicroelectronics STM32F2xx devices.
  • startup_stm32f2xx.s contains the CPU startup code for the STMicroelectronics STM32F2xx devices.
  • system_stm32f2xx.c configures system clock and external memory setup options.

Editing BLINKY

You may edit Blinky.c or review the source code. Double click on Blinky.c in the Files page of the Project Workspace window. µVision loads and displays the contents of Blinky.c in an editor window.

Running BLINKY

Perform the following four steps to run the BLINKY Example on the MCBSTM32F200 Evaluation Board:

  1. Building BLINKY
  2. Downloading BLINKY
  3. Debugging BLINKY
  4. Verifying Program Operation


MCBSTM32F200/400 User's Guide: Building BLINKY

Building BLINKY

Build the BLINKY example program following this procedure. The executable files are placed in an output folder, ready for downloading.

Build Target Button When you are ready to compile and link your project, use the Build Target command from the Project menu or the Build toolbar. On the Build toolbar, select the appropriate target for your program.

µVision translates and links the source files and creates an absolute object module that you may load into the µVision debugger for testing. The status of the build process displays in the Build page of the Output Window.

Once the BLINKY application is built, if you selected the STM32F207 Flash target, proceed with the Downloading step. If the STM32F207 RAM target is selected, go directly to the Debugging step.

Note

  • You should not encounter any errors when you use µVision with the provided sample projects.


MCBSTM32F200/400 User's Guide: Debugging BLINKY

Debugging BLINKY

Debug the BLINKY example program following this procedure. The debugged program is ready for the serial output check.

Start/Stop Debug Button Use the Start/Stop Debug Session toolbar button or the µVision command Debug — Start/Stop Debug Session to connect the debugger to the Keil ULINK Adapter. The CPU stops and connects to the CoreSight debug port of the STM32F207IG device. For more details on the debugging features, refer to the µVision User's Guide.


MCBSTM32F200/400 User's Guide: Downloading BLINKY

Downloading BLINKY

When the BLINKY build is complete, you may download the application to the on-chip Flash ROM using the Keil ULINK USB-JTAG Adapter.

Download to Flash Button Click the download button

When you use the Download command for the first time, you must configure the Flash options under Project — Options for Target — Utilities as described in Downloading to Flash.

After configuration, the Flash — Download command uses the Keil ULINK USB-JTAG Adapter for Flash programming.

The BLINKY application starts executing when you press RESET on the MCBSTM32F200 board to verify the program downloaded.

Note

  • You may enable the option Update Target before Debugging to download the BLINKY project whenever you start a Debug Session.

The downloaded program is ready for debugging.


MCBSTM32F200/400 User's Guide: Verifying Program Operation

Verifying Program Operation

To verify the BLINKY program is operating correctly, start the program running either from the debugger via JTAG or by pressing the RESET button, or just cycling power on the board. The 8 LEDs will flash sequentially right-to-left, then left-to right continuously.


MCBSTM32F200/400 User's Guide: Example Programs

Example Programs

The Keil MDK-ARM Development Tools download includes several example programs that are configured for the Keil MCBSTM32F200 Board.

The examples are configured for two µVision targets:

  • STM32F207 RAM - where the program runs in internal RAM.
  • STM32F207 Flash - where the program runs from internal Flash.

All examples use the same file structure:

  • Abstract.txt contains a short description of the example.
  • startup_stm32f2xx.s contains the startup code for the microcontroller.
  • system_stm32f2xx.c contains the system initialization code for the microcontroller.
  • Example dependent source code.

MDK V4 Examples

Each example project is stored in a separate sub-folder of:

  • \KEIL\ARM\BOARDS\KEIL\MCBSTM32F200\ for the MCBSTM32F200 board.
  • \KEIL\ARM\BOARDS\KEIL\MCBSTM32F400\ for the MCBSTM32F400 board.

The following example program is installed automatically:

  • BLINKY
    The Blinky project is a simple example that demonstrates configuring and controlling multiple GPIO ports to blink the on-board LEDs sequentially. SysTimer is used in interrupt mode and ticks every 10ms which toggle the LED flash sequence.

MDK V5 Examples

The examples provided for MDK V5, are included in the Device Family Pack and my be copied to the folder of your choice using the Pack Installer. To do this:

  1. In uVision V5, click the Pack Installer [image] icon.
  2. Click the Examples tab, and locate the Blinky (MCBSTM32F200) example.

  3. Pack Installer: Copy Example

  4. Click the Copy button to copy the example project to a folder of your choice.

  5. Pack Installer: Copy Example Dialog

    The checkboxes retain example project folder structure and open the project in a new instance of uVision.


MCBSTM32F200/400 User's Guide: Programming Flash

Programming Flash

The MCBSTM32F200 board supports downloading programs to Flash memory using the ULINK USB-JTAG adapter through the JTAG connector.

MCBSTM32F200 Board Connected to ULINK2

The ULINK USB-JTAG interface also supports emulation and debug capabilities for the MCBSTM32F200 board.


MCBSTM32F200/400 User's Guide: Downloading to Flash

Downloading to Flash

Download using the Keil ULINK JTAG-Adapter. The steps to setup ULINK for Programming Flash within µVision IDE are:

  1. Connect the ULINK to the JTAG connector of the MCBSTM32 Board. Note that the red cable marks pin 1 of the JTAG-connector.

    MCBSTM32F200 connected to ULINK2

    Note

    • The JTAG interface could be disabled by random CPU instructions or by the power-down mode of the device. If this occurs, enable the on-chip boot loader, so the STM32F20x device can execute a valid program.
      For more information refer to the web-based Keil Support Knowledgebase, for example to the article ULINK: RECOVER STR71X WHEN JTAG DISABLE.
  2. On the MCBSTM32F200 board, make sure the BOOT0 jumper is set to the GND position. When BOOT0 is grounded, the position of the BOOT1 jumper does not matter.
  3. Power up the MCBSTM32F200 Board.
  4. Configure Flash Programming in the Project — Options for Target — Utilities dialog.

    Use Target Driver Option Set the Use Target Driver for Flash Programming option, then select the ULINK Cortex-M3 Debugger as the Flash programming tool.

    Update Target Option Check the Update Target before Debugging option to ensure that the Flash ROM gets programmed whenever the debugger starts.

    Settings Button Click the Settings button to open the Flash Download Setup dialog for the next step.

  5. Configure the Flash Download Setup dialog as follows:

    Flash Download Function Set the Download Function options by first selecting Erase Sectors used by the application, then check Program and Verify to verify the Flash contains the downloaded application.

    RAM for Algorithm Setting Set the Start location for for the flash programming algorithm to 0x2000000 in RAM and set the Size to 0x0800.

    Programming Algorithm Click the Add button and find the STM32F2xx 1M On-chip Flash programming algorithm in the list of available algorithms. Select it, then click the Add button to add it to your target.

    Finally, click the OK button to save the Flash Download settings, then OK again to save the target options.

  6. Download to Flash

    Download To Flash Button Click the Download to Flash toolbar button. This executes the Flash download program (Target Driver or External) selected in Project — Options for Target — Utilities and downloads the application program into the STM32F207IG device.

    Or

    Use the µVision command Flash — Download to download the application program into the STM32F207IG device.

ULINK can be also used for application code debugging in Flash ROM or RAM of the STM32F207IG microcontroller.


MCBSTM32F200/400 User's Guide: Kit Contents

Kit Contents

The MCBSTM32F200 kit includes:

  • The MCBSTM32F200 Evaluation Board.
  • 1 USB A to Micro-B cable.
  • A µVision IDE Quick Start Guide.
  • Example Programs for the MCBSTM32F200 Evaluation Board are located in the folder KEIL\ARM\BOARDS\KEIL\MCBSTM32F200 for MDK V4 users. MDK V5 users may copy examples included with the the installation of the Keil MCBSTM32F200 Device Family Pack to a folder of their choice.

The MCBSTM32F400 kit includes:

  • The MCBSTM32F400 Evaluation Board.
  • 1 USB A to Micro-B cable.
  • A µVision IDE Quick Start Guide.
  • Example Programs for the MCBSTM32F400 Evaluation Board are located in the folder KEIL\ARM\BOARDS\KEIL\MCBSTM32F400 for MDK V4 users. MDK V5 users may copy examples included with the the installation of the Keil MCBSTM32F400 Device Family Pack to a folder of their choice.


MCBSTM32F200/400 User's Guide: Features

Features

The connectors on the evaluation board provide easy access to many of the STM32F207's on-chip peripherals.

  • Serial Port
    A standard DB9 connector is on the board for the STM32F207's built-in UART interfaces. This is a full duplex, serial port.
  • CAN Port
    A standard DB9 connector for applications requiring CAN communications.
  • USB 2.0 Full Speed and High Speed Ports
    2 standard USB Type mini-B connectors: One for full-speed and one for high-speed USB Device, Host and OTG communications.
  • 100/10M Ethernet Port
    A standard RJ45 connector on the MCBSTM32F200 board connects to an on-board Ethernet transceiver for applications requiring Ethernet communications.
  • VGA Camera and Microphone
    A 640 x 480 Color CMOS camera and on-board digital microphone for VGA image and digital sound capture.
  • LCD Display with Touch Screen
    A detachable, 240x320 TFT, color LCD display with 4-wire, resistive touch screen. You may use this graphic display device to show real-time debug and program status messages.
  • Stereo CODEC and Amplifier and On-board Microphone
    A low-power stereo CODEC with headphone and microphone amplifier. You may use this on-board device for audio applications.
  • Motion Detectors
    Both a low-power, 3-axis accelerometer and a 3-axis MEMS inertial rate sensor(gyroscope). You may use these on-board devices for applications requiring the detection of movement.
  • On-board Battery
    A removable, lithium battery is included on the MCBSTM32F200 to maintain power to the real-time clock when the board disconnects from the main power supply.
  • Analog Voltage Control for ADC Input
    An adjustable analog voltage source for testing the Analog to Digital converter built into the STM32F207 device.
  • MicroSD Card Connector
    A MicroSD Card connector for developing applications requiring access to MicroSD Cards.
  • External Memory
    The MCBSTM32F200 board includes:
    • 2 MB External SRAM
    • 8 MB External NOR Flash
    • 512 MB External NAND Flash
    • 8 KB EEPROM (I2C) with NFC (wireless near field communication) interface
  • JTAG and Cortex/ETM Download and Debug
    The MCBSTM32F200 board incorporates both a JTAG interface and a Cortex Debug + ETM interface. When coupled with the ULINK2 USB-JTAG adapter, the Serial Wire JTAG interface allows flash programming and debugging. With the ULINKPro adapter, the Cortex Debug/ETM interface allows flash programming and instruction trace debugging.


MCBSTM32F200/400 User's Guide: Hardware Requirements

Hardware Requirements

To use the MCBSTM32F200 or MCBSTM32F400 Evaluation Kit, you need:

  • The MCBSTM32F200 or MCBSTM32F400 Evaluation Board.
  • A PC with:
    • One USB port for downloading and debugging.
    • A second USB port if the board is not powered using an external adapter.

To download and debug, one of the following:

  • A Keil ULINK2 USB-JTAG Adapter.
  • A Keil ULINK-ME USB-JTAG Adapter.
  • A Keil ULINKPro USB-JTAG Adapter.

Plus:

  • 1 USB A-B cable for connecting the ULINK adapter.

And either:

  • 1 USB A to Micro A cable or USB A to Micro B cable

Or

  • A 8-12 VDC, 500mA external power adapter

to power the board.


MCBSTM32F200/400 User's Guide: Quick Start

Quick Start

Use the following table to locate important information about the MCBSTM32F200 board and get started quickly.

To… | See…
Connect power to the MCBSTM32F200 board. | Setup
Connect the MCBSTM32F200 via ULINK/JTAG to your PC. | Connecting the MCBSTM32F200
Read about the default configuration settings. | Configuring the MCBSTM32F200
Configure the tool options for the MCBSTM32F200 board. | Writing Programs
Learn more about µVision IDE. | µVision User's Guide
Review the MCBSTM32F200 schematics. | MCBSTM32F200 Schematics


MCBSTM32F200/400 User's Guide: MCBSTM32F200 Starter Kit

MCBSTM32F200 Starter Kit

The MCBSTM32F200 starter kit is the ideal way to begin working with the STM32 devices from STMicroelectronics.

MCBSTM32F200 Board with ULINK-ME

The starter kit includes:

  • MCBSTM32F200 Evaluation board
  • ULINK-ME USB-JTAG adapter
  • MDK-ARM (evaluation software)

These tools help you get started writing programs and testing the microcontroller and its capabilities. Example applications which run on the MCBSTM32F200 are included.

Note:

  • All references to ULINK or ULINK2 in this document apply to the ULINK-ME USB-JTAG adapter.


MCBSTM32F200/400 User's Guide: Software Requirements

Software Requirements

You must install the following required software to use the MCBSTM32F200 Evaluation Board:

Windows Operating System

The Keil µVision tool chain runs in these Windows Operating Systems:

  • Microsoft Windows XP
  • Microsoft Windows Vista
  • Microsoft Windows 7
  • Microsoft Windows 8

Tools and Examples

To compile, link and run applications on the MCBSTM32F200 Evaluation Board, you must install these Keil products:

  • The MDK-ARM which includes the µVision Debugger and provides several example programs for the MCBSTM32F200 Board.

Optional

  • The RL-ARM Real-Time Library which includes the RTX Real-Time Kernel, TCP/IP Protocol Suite, Flash File system, CAN Driver, and USB Driver. You may use this package to implement applications that connect by CAN, or USB.


MCBSTM32F200/400 User's Guide: Introduction

Introduction

You may use the Cortex-M3 based MCBSTM32F200 Evaluation Board to generate and test application programs for the STMicroelectronics STM32F207x microcontroller family or the Cortex-M4 based MCBSTM32F400 Evaluation Board for the STM32F407x microcontroller family. With this hands-on process, you can determine the hardware and software requirements for current and future product development.

The MCBSTM32F200 Evaluation Board ships with the STM32F207IG device that is a superset of several other device variants of the STM32F207x microcontroller seriesst/stm32f407ig/" target="_blank">STM32F407IG device that is a superset of several other device variants of the STM32F407x microcontroller series. The MCBSTM32F200 and MCBSTM32F400 boards contain all the hardware components required in a single-chip STM32x system.

MCBSTM32F200 Board

MCBSTM32F200 Board

Note

  • The MCBSTM32F200 and MCBSTM32F400 use the same base board and on-chip peripherals. Only the MCU is different between the two boards.


MCBSTM32F200/400 User's Guide: Theory of Operation

Theory of Operation

The Theory of Operation explains the MCBSTM32F200 board hardware. The descriptions help you to understand the MCBSTM32F200 board components and how to use the available I/O interfaces.

The MCBSTM32F200 is designed to be a very flexible evaluation board for the STMicroelectronics STM32F20x device series. The MCBSTM32F200 evaluation board can be expanded to build hardware prototypes.


MCBSTM32F200/400 User's Guide: Keil MDK-ARM

Keil MDK-ARM

To use the MCBSTM32F200 Board download the Lite Edition of the Keil Microcontroller Development Kit (MDK-ARM). The MDK-ARM Lite Edition includes:

  • Powerful and easy-to-use µVision IDE that includes editor, project management, and make capability.
  • µVision Debugger with complete CPU, peripheral simulation, and driver for the Keil ULINK USB-JTAG Adapter.
  • ARM Compilation Tools that include ANSI C/C++ Compiler and related utilities.
  • RTX RTOS Kernel for the ARM Compiler.
  • STM32F20x Software Library ported for the ARM Compilation Tools.
  • Extensive tutorials and documentation.

The restrictions for the MDK-ARM Lite Edition are:

  • The image ROM size of the generated application is limited to 32KB maximum.
  • The base address for code/constants is restricted to 0xXX000000, 0xXX800000, or 0x00080000 whereby XX stands for 00, 01, ..., FF. This allows memory start address like 0x00000000, 0x12800000 and so on.
  • It is not possible to generate position independent code or data.
  • The compiler does not generate a disassembly listing file.


MCBSTM32F200/400 User's Guide: Application Notes

Application Notes

Keil Software provides numerous Application Notes that discuss solutions to special problems. These are available on the Keil web site at: http://www.keil.com/appnotes/

Application Notes are available for topics like CAN and Ethernet Programming, Complex Device Simulation, and many more.


MCBSTM32F200/400 User's Guide: Writing Programs

Writing Programs

The Writing Programs topics introduce you to the Keil development tools and show you, step-by-step, the process of using them with the MCBSTM32F200 board. You will learn how to use µVision to create, compile, download, debug, and run a program on the MCBSTM32F200 board.

Writing programs for the MCBSTM32F200 board is easy.

  1. Create the Application Program using µVision IDE and the ARM C/C++ Compiler.
  2. Download the program to the on-chip Flash of the MCBSTM32F200 Board.
  3. Debug the program using the µVision Debugger and ULINK.

Note

  • Use the Keil MDK-ARM Lite Edition if no other version is installed on the computer.


MCBSTM32F200/400 User's Guide: Setup

Setup

Setting up the MCBSTM32F200 evaluation board is easy. Explanations for the board setup and its components are presented here. Details about the connecting and configuring procedures for the MCBSTM32F200 board are also presented, with a separate topic for the jumper descriptions. Setup includes using the MCBSTM32F200 board with ULINK.

The MCBSTM32F200 board requires a power connection and a ULINK-USB adapter between your development PC and the JTAG or Cortex Debug connector.

Before you start, make sure you have satisfied the hardware and software requirements.


MCBSTM32F200/400 User's Guide: Board Setup

Board Setup

The MCBSTM32F200 Evaluation Board may be powered:

  • From a PC via USB A to Micro-B cable.
  • From an 8-12 VDC, 500mA external power adapter.

For downloading and debugging, the MCBSTM32F200 Evaluation Board connects directly to the Keil µVision Debugger using the Keil ULINK USB-JTAG Adapter, so no additional software is required on the board.

MCBSTM32F200 Board Connected to ULINK2


MCBSTM32F200/400 User's Guide: Board Components

Board Components

The following illustration shows the important interface and hardware components of the MCBSTM32F200 board.

MCBSTM32F200 Board Components


MCBSTM32F200/400 User's Guide: Configuring the MCBSTM32F200

Configuring the MCBSTM32F200

The MCBSTM32F200 Evaluation Board is configured using 5 sets of jumpers. The MCBSTM32F200 Board ships with the following configuration:

Power Jumpers

Jumper | State | Description
J1 BAT/3V3 | 3V31 | Connects 3.3VDC to VBAT.
J19 3V3uC | ON1 | Supplies regulated 3.3VDC to VDD. This jumper can be removed for monitoring just the VDD current draw of the STM32F207IG device.
J20 3V3A | ON1 | Supplies regulated 3.3VDC to VDDA and VREF+ on the STM32F207IG device. This jumper can be removed for monitoring just the VDDA and VREF+ current draw of the STM32F207IG device.

Boot Config Jumpers

Jumper | Jumper | Mode | Description
J3 | J4 | User Flash1 | Maps User Flash to boot space.
J3 | BOOT0 | System Memory | Maps System Memory to boot space.
BOOT1 | J4 | n/a |
BOOT1 | BOOT0 | Embedded SRAM | Maps on-chip SRAM to boot space.

Note:

  • J3 and J4 above refer to the left-most position on the jumper block (pins 1-2). BOOT0 and BOOT1 refer to the right-most position on the jumper block (pins 2-3).
  • When the System Memory boot configuration is selected, UART3 may be used to reprogram on-chip Flash via the embedded bootloader.

Communications Jumpers

Jumper | State | Description
J2 USBHS_EN | ON1 | Enables high speed USB 2.0 communications via connector P3.
J13 TX1-TX3/4 | TX11 | Connects the RS232 transmit data signal (TXD) to TX1, Port PC10 of the MCU. NOTE: For V1.1 boards only, this jumper was mislabeled as RX3/4-RX1. It should be labeled TX1-TX3/4.
J14 RX1-RX3/4 | RX11 | Connects the RS232 receive data signal (RXD) to RX1, Port PC11 of the MCU. NOTE: For V1.1 boards only, this jumper is mislabeled as TX3/4-TX1. It should be labeled RX1-RX3/4.
J15 CAN1/CAN2 | CAN11 | Connects Ports PI9 and PH13 (CAN1) to TXD and RXD on the CAN controller.
J16 CAN Term | ON1 | Provides a 120 ohm resistor between CANH and CANL for terminating the CAN bus.

Note:

  • When Jumpers J13 and J14 select UART3/4 (pins PC10/11), the SD-card interface cannot be used because these pins are shared.

Audio/Video Jumpers

Jumper | State | Description
J5 M_DATA | ON1 | Connects the on-board microphone PDM output data to Port PC3 of the MCU.
J6 LS | ON1 | Selects the headphone jack (HP/Line Out) for audio output.
J7 M_CLK | ON1 | Supplies clock signal from Port PI1 to the on-board microphone.
J8 MICbiasR | ON1 | Connects MICBIAS from the MCU to the right microphone line in input.
J9 MICbiasL | ON1 | Connects MICBIAS from the MCU to the left microphone line in input.
J17 CAM_EN | ON1 | Enables the on-board VGA camera.

Debug Jumpers

Jumper | State | Description
J10 A19/TRACE | TRACE | Port PE3 is used for ETM Trace data capture.
J11 A20/TRACE | TRACE | Port PE4 is used for ETM Trace data capture.
J12 A21/TRACE | TRACE | Port PE5 is used for ETM Trace data capture.
J18 LED_EN | ON1 | Enables the 8, port-driven LEDs.

1 Factory setting of MCBSTM32F200.


MCBSTM32F200/400 User's Guide: Connecting the MCBSTM32F200

Connecting the MCBSTM32F200

To use the MCBSTM32F200 Evaluation Board with ULINK, you must:

  • Connect the ULINK adapter to the JTAG or the Cortex Debug connector of the MCBSTM32F200 board.
  • Connect the ULINK adapter to the PC via a standard USB AB cable.
  • Connect power from your PC to the board using the included USB A to Micro B cable.
  • Set the JTAG clock for your ULINK adapter.

The following picture shows how to connect ULINK to the MCBSTM32F200 board.

MCBSTM32F200 Board Connected to the ULINK2 JTAG Adapter


MCBSTM32F200/400 User's Guide: Setting the JTAG Clock

Setting the JTAG Clock

To get the best performance from your ULINK JTAG adapter, it's important to set the JTAG clock rate for the MCBSTM32F200 board. The following steps show you how this is done.

  1. Power up the MCBSTM32F200 Board.
  2. In µVision, Configure the Debugger in the Project — Options for Target — Debug dialog.

    Options for Target Button Use the Options for Target toolbar button and click the Debug tab to display the Debug dialog.

    Use: ULINK ARM Debugger Select the Use: radio button and then ULINK Cortex Debugger in the drop-down list to choose the ULINK USB-JTAG Adapter as the debugging tool.

  3. Click the Settings button to open the Cortex-M Target Driver Setup dialog.

    Target Driver Setup - ULINK2 Adapter Select the SW option from the Port: drop-down list to use the Serial Wire JTAG interface of the Cortex-M3 device.

    Since the Cortex-M3 device supports both JTAG and Serial Wire modes, check the SWJ checkbox.

    The Max Clock drop-down list sets the highest JTAG clock rate used to communicate to the target board. When using a ULINK2 or ULINK-ME adapter, the 1MHz setting works best with the MCBSTM32F200 board.


MCBSTM32F200/400 User's Guide: Jumper Descriptions

Jumper Descriptions

The jumpers used to configure the MCBSTM32F200 board are:

  • J1 BAT/3V3: Connects the 5 VDD inputs on the STM32F207IG to 3.3VDC.
  • J2 USBHS_EN: Enables high-speed USB 2.0 communications. This jumper must be installed to allow communications via the USBHS A and Micro-B connectors.
  • J3 BOOT1: Either grounds or drives the BOOT1 signal (PB2). high.
  • J4 BOOT0: Either grounds or drives the BOOT0 signal high.
  • J5 M_DATA: Connects the on-board microphone (MIC1) data to Port PC3.
  • J6 LS: Grounds the headphone detect switch (SPK/HP_SW) enabling output to the headphone jack (HP/Line Out) and disabling the on-board speaker.
  • J7 M_CLK: Provides a clock signal for the on-board microphone (MIC1) via Port PI1.
  • J8 MICbiasR: Connects a pre-set microphone bias voltage to the right channel microphone input.
  • J9 MICbiasL: Connects a pre-set microphone bias voltage to the left channel microphone input.
  • J10 A19/TRACE: When the jumper is in the A19 position, it allows PE3 to be used for extended NOR Flash and external SRAM addressing. When in the Trace position, it allows ITM Instruction Trace debugging.
  • J11 A20/TRACE: When the jumper is in the A20 position, it allows PE4 to be used for extended NOR Flash and external SRAM addressing. When in the Trace position, it allows ITM Instruction Trace debugging.
  • J12 A21/TRACE: When the jumper is in the A21 position, it allows PE5 to be used for extended NOR Flash addressing. When in the Trace position, it allows ITM Instruction Trace debugging.
  • J13 TX1-TX3/4: Connects TXD of the RS232 driver to UART3/4 (PC10) or UART1 (PB6).
    • NOTE: For V1.1 boards only, this jumper was mislabeled as RX3/4-RX1. it should be labeled TX1-TX3/4.
    • When jumper J13 selects UART3/4 (pin PC10), the SD-card interface cannot be used because this pin is shared.
  • J14 RX1-RX3/4: Connects RXD of the RS232 driver to UART3/4 (PC11) or UART1 (PB7).
    • NOTE: For V1.1 boards only, this jumper was mislabeled as TX3/4-TX1. it should be labeled RX-1-RX3/4.
    • When jumper J14 selects UART3/4 (pin PC11), the SD-card interface cannot be used because this pin is shared.
  • J15 CAN1/CAN2: Configures the CAN controller as CAN1 (PI9 and PH13) or CAN2 (PB5 and PB13).
  • J16 CAN Term: Terminates the CAN bus with a 120 ohm resistor.
  • J17 CAM_EN: Enables the on-board VGA camera.
  • J18 LED_EN: Enables the 8 on-board LEDs.
  • J19 3V3uC: Connects 3.3VDC to VDD on the MCU. This jumper can be used to monitor VDD current drawn by the MCU.
  • J20 3V3A: Connects 3.3VDC to VDDA and VREF+ on the MCU. This jumper can be used to monitor VDDA and VREF+ current drawn by the MCU.
  • P2 GND/SWO: This header provides access to the Serial Wire Output (SWO) signal (PB3) and ground reference. They may be used in conjunction with J19 and J20 for external power measurement and profiling devices.

Note

  • The BOOT0 and BOOT1 jumpers configure the microcontroller startup (boot) mode. This setting tells the microprocessor the location (User Flash, System Memory or Embedded SRAM) of the boot code.
  • Jumpers J10, J11 and J12 must be installed in the rightmost position to use ETM Trace Enable option for ULINKPro in the uVision debugger. Configuring the jumpers for ETM Trace reduces the amount of addressable external NOR Flash and external SRAM to 1MB.

MCBSTM32F200 Board Jumpers


MCBSTM32F200/400 User's Guide: Accelerometer

Accelerometer

Accelerometer

The MCBSTM32F200 board includes a low-power, 3-axis STMicroelectronics LIS3Dh accelerometer at location IC26. It is controlled using an I2C serial interface connected to port pins PB8 and PB9.

MEMS Gyroscope

The MCBSTM32F200 board also includes a low-power, 3-axis STMicroelectronics L3G4200D MEMS inertial rate sensor(gyroscope) at location IC25. Like the accelerometer, it is controlled over an I2C serial interface and is also connected to port pins PB8 and PB9.

MCBSTM30 Board Accelerometer


MCBSTM32F200/400 User's Guide: Block Diagram

Block Diagram

The hardware block diagram displays the input, configuration, power system, and User I/O on the board. This visual presentation helps you to understand the MCBSTM32F200 board components.

MCBSTM32F200 Block Diagram


MCBSTM32F200/400 User's Guide: Push Buttons

Push Buttons

The four push buttons on the MCBSTM32F200 board are:

  • The User push button connects to port pin PG15 of the STM32F207IG device and is available for general use.
  • The Tamper push button connects to port pin PC13 of the microcontroller controlling the anti-tamper feature of the STM32F207IG device.
  • The Wakeup push button connects to port pin PA0 of the microcontroller. This wakes up the microcontroller out of sleep mode.
  • The Reset push button connects to the voltage monitor and the power-up reset circuit. This resets the microcontroller.

MCBSTM32F200 Board Buttons


MCBSTM32F200/400 User's Guide: Camera

Camera

The on-board CMOS color camera CAM1 (OmniVision OVM7690) supports 640x480 pixel image capture and connects using an 8-bit interface. The camera connects to the MCU via transceivers IC19 and IC22.

Removing jumper J17 disables both transceivers which isolates the camera, effectively disabling it.

MCBSTM32F200 VGA Camera


MCBSTM32F200/400 User's Guide: CAN Interface

CAN Interface

The CAN Interface uses an SN65HVD230 (marked as VP230) CAN driver at IC18 on the MCBSTM32F200 board.

MCBSTM32F200 Board CAN Interface

The CAN DB9 connectors are wired so that Pin 2 provides the CANL signal and Pin 7 provides the CANH signal. These pins are connected to a SN65HVD230 CAN driver. The jumpers at J15 allow you to configure the CAN driver IC to the CAN1 or CAN2 interface on the MCU.

Jumper J16 incorporates a 120 ohm termination resistor between the CANL and CANH signals.

MCBSTM32F200 CAN DB9 Connector

Note

  • CAN termination resistors make it easy to connect the MCBSTM32F200 board to your CAN network but they are not always required. When connecting the MCBSTM32F200 Board to a CAN network, you may need to remove jumper J16.


MCBSTM32F200/400 User's Guide: Configuration

Configuration

The MCBSTM32F200 evaluation board is very flexible and configures easily to suit your needs. Configuration jumpers control the built-in features such as debug interfaces, VGA camera, audio drivers, CAN driver, and LEDs.

Refer to Configuring the MCBSTM32F200 and Jumper Descriptions for descriptions of the possible settings.

After changing configuration jumpers, you must reset the MCBSTM32F200 board.

Note

  • The STM32F207IG device provides many configuration options. For more information, please refer to the Schematics page.


MCBSTM32F200/400 User's Guide: Microcontroller

Microcontroller

The STMicroelectronics STM32F207IG microcontroller (IC1) is provided with the MCBSTM32F200 board, and the STMicroelectronics STM32F407IG microcontroller (IC1) with the MCBSTM32F400 board. Both are high-end STM32F devices with on-chip CAN, Ethernet, USB (full and high-speed) connectivity and parallel camera interface.

A 25.0 MHz oscillator (Q1) provides the clock signal for the MCU.

MCBSTM32F200 Board MCU


MCBSTM32F200/400 User's Guide: Ethernet Interface

Ethernet Interface

The Ethernet Interface on the MCBSTM32F200 board uses the 10/100 Fast Ethernet 3.3V STMicroelectronics ST802RT1A controller (IC10).

MCBSTM32F200 Board - Ethernet Interface


MCBSTM32F200/400 User's Guide: ETM Interface

ETM Interface

The ETM Interface connector provides instruction-level trace debugging support for the STRM32F107VC device.

MCBSTM32F200 Board ETM Connector

A 20-pin header (Samtec FTSH-120) is included for connecting to Cortex Debug and ETM Trace hardware.

20-pin ETM Trace Connector Pin Identification

Note

  • When using ETM Instruction Trace, the J10, J11 and J12 jumpers must be installed in the rightmost position. This allows ETM Instruction Trace, but limits the amount of NOR Flash or external SRAM to 1MB. Moving the jumpers to the leftmost position expands the NOR Flash or external SRAM limit, but ETM Instruction Trace cannot then be used.


MCBSTM32F200/400 User's Guide: Joystick

Joystick

The 5-position joystick control on the MCBSTM32F200 board grounds one of 5 GPIO pins (X+, X-, Y+, Y- and IN3) on the STMPE811 Touchscreen Controller (IC27) depending on how the the joystick control handle is positioned. Each position is sent to the MCU via I2C. The control may be positioned left, right, up, down or pushed toward the board (center).

  • The Left joystick position connects the Y+/GPIO-5 pin of the STMPE811 Touchscreen Controller to ground.
  • The Right joystick position connects the X+/GPIO-4 pin of the STMPE811 Touchscreen Controller to ground.
  • The Up joystick position connects the IN3/GPIO-3 pin of the STMPE811 Touchscreen Controller to ground.
  • The Down joystick position connects the X-/GPIO-6 pin of the STMPE811 Touchscreen Controller to ground.
  • The Center joystick position connects the Y-/GPIO-7 pin of the STMPE811 Touchscreen Controller to ground.

MCBSTM32F200 Board Joystick


MCBSTM32F200/400 User's Guide: JTAG Interface

JTAG Interface

The JTAG Interface connector provides debugging and emulator support for the STM32F207IG device. The JTAG Interface allows application debugging and programming of on-chip and off-chip Flash devices.

MCBSTM32F200 Board JTAG Connector

The standard JTAG 20-pin connector works with the Keil ULINK and many third party tool vendors. The Cortex Debug connectors work with the Keil ULINK2, ULINK-ME and ULINKpro adapters, plus many third party tool vendors.

Cortex Debug and JTAG Pin Identification

Serial Wire Mode Interface

The MCBSTM32F200 board also supports the Serial Wire Mode of Cortex-M3 based devices. In Serial Wire mode, only the pins TCLK and TMS are used. TDO is an optional trace data output pin.


MCBSTM32F200/400 User's Guide: LCD Panel w/Touch Screen

LCD Panel w/Touch Screen

The LCD-TFT color graphics display panel (AMPIRE AM240320L8TNQW) contains a 240x320 pixel screen and connects using a 16-bit interface. The LCD panel is mounted on the MCBSTM32F200 Display Board, and connects to MCBSTM32F200 Base Board via 34-pin header.

This LCD panel includes a 4-wire, resistive touch screen controlled by an STMicroelectronics STMPE811 touch screen controller (IC2).

MCBSTM32F200 LCD Panel

See External Memory for chip select and addressing assignments for the LCD panel.


MCBSTM32F200/400 User's Guide: LEDs

LEDs

The MCBSTM32F200 board has the following LED indicators:

  • The USB_FS LED indicates 5VDC is present on the full-speed USB VBUS connector.
  • The USB_HS LED indicates 5VDC is present on the high-speed USB VBUS connector.
  • The FS_ERR LED indicates a fault condition (short circuit, over-current or over-temperature) at the IC7 full-speed USB power switch.
  • The HS_ERR LED indicates a fault condition (short circuit, over-current or over-temperature) at the IC9 high-speed USB power switch.
  • The 8 Port LEDs marked PG.6 - PG.8, PH.2, PH.3, PH.6, PH.7 and PI.10 connect to their respective port pins when jumper LED is installed. These LEDs are useful for indicating program status while testing your applications.
  • The ORANGE LED (right/lower) on the Ethernet connector indicates LAN traffic is present.
  • The GREEN LED (left/upper) on the Ethernet connector indicates a good link connection to the LAN.

MCBSTM32F200 Board - LEDs


MCBSTM32F200/400 User's Guide: External Memory

External Memory

In addition to the Flash and RAM internal to the STM32F207IG (or STM32F407IG) MCU, the MCBSTM32F200/400 board contains the following external memory:

  • 2 MB External SRAM located at IC13. Note: If jumpers J10, J11 and J12 are configured for ETM Trace, only 1 MB of this SRAM is accessible.
  • 8 MB External NOR Flash located at IC16. Note: If jumpers J10, J11 and J12 are configured for ETM Trace, only 1 MB of this Flash is accessible.
  • 512 MB External NAND Flash located at IC14 (on the back side of the board).
  • 8 KB EEPROM with NFC (wireless near field communication) interface located at IC15. The NFC antenna is located at L10.

MCBSTM32F200 Board External Memory

Chip Select and Addressing for External Memory and LCD

The table below identifies the chip select, pin and address area for the external memory and LCD devices on the MCBSTM32F200 board.

Device | Chip Select / Pin | Address Area
NOR-Flash | FSMC_NE1 / PD7 | 0x60000000 - 0x607FFFFF
NAND-Flash | FSMC_NCE3 / PG9 | Not directly mapped to a memory area.
SRAM | FSMC_NE3 / PG10 | 0x68000000 - 0x681FFFFF
LCD | FSMC_NE4 / PG12 | 0x6C000000 - 0x6C000003


MCBSTM32F200/400 User's Guide: Microphone

Microphone

Microphone Input

The MCBSTM32F200 board includes a standard stereo microphone mini-connector for input to the on-board Cirrus CS42L52 CODEC. Installing jumpers J9 and J8 applies a bias voltage separately to the left and right microphone inputs (AIN3A and AIN3B). The bias voltage (MICBIAS) value is a software configurable parameter within the CODEC.

On-board Microphone

The MCBSTM32F200 board also contains a MEMS digital microphone (MIC1) for for capturing monaural audio. The jumpers J5 and J7 enable the microphone by connecting its M_DATA and M_CLK signals to ports PC3 and PI1 on the MCU.

MCBSTM32F200 Board - Microphone


MCBSTM32F200/400 User's Guide: Potentiometer

Potentiometer

The potentiometer on the MCBSTM32F200 board connects to port pin PF9 (ADC3_IN7). The voltage range is 0.0-3.3 Volts.

MCBSTM32F200 Board Potentiometer


MCBSTM32F200/400 User's Guide: Power Supply

Power Supply

The MCBSTM32F200 Board can be powered through two different connectors:

  • USBFS or USBHS: The board is supplied automatically with 5 V when connected to a PC through a USB A to Micro B cable. The STM32 microcontroller can use the USB interface as a USB device.
  • PWR: Power may also be supplied by an 8-12 VDC external power supply which must be capable of providing up to 500mA of current. IC2 reduces and regulates this to 5.0VDC.

The voltage regulators IC3 and IC4 generate 3.3 Volts DC to supply all components on the board. When jumper J1 is in the BAT position, the CR1220 lithium battery supplies power to the CPU to maintain the real-time clock.

MCBSTM32F200 Board Power Connections

The PWR connection uses a standard 5.5mm barrel plug with a 2.1mm inner diameter. The center conductor provides positive voltage.


MCBSTM32F200/400 User's Guide: Prototyping Area

Prototyping Area

The provides blocks for connecting the address and data lines, and ports PA, PB, PC, PD, PE, PF, PG, PH, PI and 3.3VDC and ground. A block for ADC1, ADC2 and ADC3 signal input to the additional A-to-D capability of the LIS3DH MEMS motion sensor(IC26).

MCBSTM32F200 Board Prototyping Area

Note

  • All microcontroller signals are brought out to pins and are driven directly by the microcontroller. Exercise caution to avoid overloading these signal lines.


MCBSTM32F200/400 User's Guide: Schematics

Schematics

The MCBSTM32F200 Evaluation Board consists of a Display Board mounted to the Base Board. Detailed Base Board schematics and Display Board schematics are available in large format on the MCBSTM32F200 Evaluation Board information section of the Keil web site.

For MDK V5 installations, if you have installed the Keil::STM32F2xx or Keil::STM32F4xx Device Family Pack, you can view the MCBSTM32F200/MCBSTM32F400 schematic PDF installed on your PC. Open an MCBSTM32F200 or MCBSTM32F400 example project, such as Blinky, click the Books tab in the Project Window, then click the MCBSTM32F200 Schematics (MCBSTMF200) or the MCBSTM32F400 Schematics (MCBSTM32F400) in the Board Data Books section.

MCBSTM32F200 Base Board Schematics

MCBSTM32F200 Base Board Schematics
MCBSTM32F200 Base Board Schematics
MCBSTM32F200 Base Board Schematics
MCBSTM32F200 Base Board Schematics
MCBSTM32F200 Base Board Schematics
MCBSTM32F200 Base Board Schematics
MCBSTM32F200 Base Board Schematics
MCBSTM32F200 Base Board Schematics
MCBSTM32F200 Base Board Schematics
MCBSTM32F200 Base Board Schematics
MCBSTM32F200 Base Board Schematics
MCBSTM32F200 Base Board Schematics

MCBSTM32F200 Display Board Schematics

MCBSTM32F200 Display Board Schematics

Copyright © Keil, An ARM Company. All rights reserved.


MCBSTM32F200/400 User's Guide: MicroSD Connector

MicroSD Connector

The MCBSTM32F200 board supports one MicroSD memory card connector that allows you to connect MicroSD memory cards.

MCBSTM32F200 MicroSD Connector


MCBSTM32F200/400 User's Guide: Serial Port

Serial Port

The MCBSTM32F200 board connects the on-chip serial UART to the ST3232C (IC17), which converts the logic signals to RS-232 voltage levels.

MCBSTM32F200 Board Serial Port

Jumpers J13 and J14 allow you to connect transmit data (TXD) and receive data (RXD) signals from the ST3232C to UART1 or UART3/UART4 on the MCU.

Note

  • For V1.1 boards only, the RX3/4-RX1 label printed at J13, and the TX3/4-TX1 label printed at J14 are incorrect. For this version of the board, they should be labeled:
    J13 TX1-TX3/4
    J14 RX1-RX3/4
    as shown in the above picture.

The serial port (UART1/3/4) is configured as a standard 3-wire interface. The DB9 connector is wired directly to the ST3232C serial interface. Refer to the figure below for details.

Serial Port DB9 Diagram


MCBSTM32F200/400 User's Guide: Speaker/Headphone

Speaker/Headphone

The MCBSTM32F200 board includes a speaker controlled by the low power stereo CODEC amplifier (IC6).

Jumper J6 (LS) controls loudspeaker (SPK1) and headphone/line output jack (HP/Line Out) from the CODEC amplifier. Installing Jumper J6 enables the headphone jack and disables the speaker. Removing Jumper J6 disables the headphone jack and enables the speaker.

MCBSTM32F200 Board Speaker


MCBSTM32F200/400 User's Guide: Technical Data

Technical Data

1 × MicroSD Memory Card connector,
1 × JTAG Interface,
1 × Cortex Debug Interface,
1 × Cortex Debug + ETM Interface,

Parameter | Description
Supply Voltage | 5 Volts DC (provided by the USB bus of a PC), or 8-12 Volts DC power from an external power supply.
Supply Current | 300mA typical, 375mA maximum
XTAL Frequency | 25 MHz
Microcontroller | STMicroelectronics STM32F207IG (MCBSTM32F200) or STMicroelectronics STM32F407IG (MCBSTM32F400)
Peripherals | 1 × RS232 Interface, 1 × CAN Interface, 2 × USB Device, Host and OTG Interfaces (Full-speed and high-speed), 1 × Ethernet Interface, 1 × Wireless Near Field Communication (NFC) Interface, 1 × Color graphic display (240x320), 1 × Color CMOS camera (640x480), 1 × Digital microphone, 1 × 3-axis accelerometer, 1 × 3-axis MEMS inertial rate sensor(gyroscope), 4 × Push buttons (Reset, Wake Up, Tamper, User), 1 × Joystick (5-position), 1 × Analog Input (connected to potentiometer), 1 × Low power, Stereo CODEC (with headphone, speaker, and microphone support)
Board Size | 124mm x 170mm (4.875" x 6.69").


MCBSTM32F200/400 User's Guide: USB Interface

USB Interface

The MCBSTM32F200 board supports connectors for both USB full-speed and USB high-speed operation.

  • USB Device: In this mode, a USB A to Micro B cable may used to connect to a PC. The board may be powered through this USB interface.
  • USB Host or USB OTG: In these modes, a Micro A USB cable is used to connect to a USB device or a USB OTG device. A USB host or USB OTG interface must be able to provide enough power to the connected USB device. When USB power from the PC is insufficient, power the board using an external 8-12 VDC power adapter. Both the full-speed and high-speed VBUS power is switched with an STMPS2141 (IC7 and IC9), which provides, over current, short circuit and over temperature fault protection. The FS_ERR and the HS_ERR LEDs indicate when any of these fault conditions exist for the full-speed and high-speed VBUS signals, respectively.

Jumper J2 must be installed to enable the USB high-speed controller.

MCBSTM32F200 USB Connector


MCBSTM32F200/400 User's Guide: Building a Program

Building a Program

When the building a program function starts, you may watch the progress in µVision's Command window. The created executable files are placed in an output folder, ready for downloading. The steps and progress are:

  1. Start the build

    Build All Button Click on the Build toolbar button to generate your application program. µVision translates all your source files and links the project.

  2. Monitor progress

    The build activity progress (assembling, compiling and linking) displays in µVision's Command window. Any errors or warnings detected during the build process also display in this window.

    Target Build Output Window

  3. Program Files

    The build creates an Executable File in ELF Format which is placed in the Output folder that you designated earlier. When you use the ULINK USB-JTAG adapter, the ELF file is required to download to the MCBSTM32F200 board using the JTAG.

    The build creates an Intel HEX executable file which is placed in the same output folder for external program downloading through the serial port.

The program is now built and ready for test.


MCBSTM32F200/400 User's Guide: Creating an MDK V4 Project

Creating an MDK V4 Project

Follow the steps below to create a new project file and to specify and organize your source (and debug) files that are a part of this project.

  1. Select the ARM Toolset that you want to use for your project.
    The default configuration is the MDK Toolset and the information below is based on selecting the ARM Compiler.
  2. Create a New Project File with the µVision menu command Project — New — µVision Project.
    Select a microcontroller from the Device Database®. The MCBSTM32F200 Board comes with the ST STM32F207IG, however, you may also use it to develop code for other STM32F20x device variants, since the STM32F207IG represents a superset of several other STM32F20x devices.
  3. Add Startup Code from the folder ..\ARM\STARTUP\ST to your project. After selecting, µVision prompts with the following dialog:

    'Copy STM32F20x.s Startup Code' Dialog

    Answer Yes since this startup code works with most STM32F20x projects.

  4. Add your own Source Code to the project using the µVision editor (or any editor of your choice) by either:
    • Right clicking the mouse in the Project Window on a group and select Add Files to Group from the context menu.

    • Or

    • Opening the Project — Components, Environment and Books — Project Components dialog.
      Within this dialog, you may create and organize files into groups, or create other project targets with different tool configurations.

      Components, Environments and Books Dialog


MCBSTM32F200/400 User's Guide: Creating an MDK V5 Project

Creating an MDK V5 Project

Follow the steps below to create a new MDK project using the Keil Run-Time Environment (RTE) and to specify and organize your source (and debug) files that are a part of this project.

  1. Select the ARM Toolset that you want to use for your project.
    The default configuration is the RealView Toolset and the information below is based on selecting the RealView Compiler.
  2. Create a New Project File with the µVision menu command Project — New — µVision Project.
    Select a microcontroller from the Device Database®. The MCBSTM32F200 Board comes with the ST STM32F207IG, however, you may also use it to develop code for other STM32F20x device variants, since the STM32F207IG represents a superset of several other STM32F20x devices. This is equally true for the STM32F407IG device on the the MCBSTM32F400 boards.
  3. When you select the STM32F207IG device for the MCBSTM32F200 board, or the STM32F407IG device for the MCBSTM32F400 board from the Device Database. because that device is supported by a Software Pack (as indicated by the colored [image] icon) , the Manage Run-Time Environment dialog displays for the device you selected.
  4. Expand the Board Support folder and select the MCBSTM32Fx00 board you will be using. Then:
    1. Expand the MCBSTM32F200 or MCBSTM32F400 folder to display and select the components on the board you will be using in your application.
    2. Expand and select any File System, Graphics, Network or USB components you will be using in your application.
    3. Click the Resolve button to let uVision resolve as many required components based on your choices.
    4. In Validation Output, double-click any missing components to display them, then select them for your application, until all missing components have been resolved.
  5. Add your own Source Code to the project using the µVision editor (or any editor of your choice) by using one of the many ways to Add Source Files to Your Project.


MCBSTM32F200/400 User's Guide: Configuring Output Files

Configuring Output Files

Configure the Output Files in the Project — Options for Target — Output dialog. The steps for configuring these files are:

  1. Select Folder for Objects... this allows you to specify sub-folders for the output files.

    Options for Target — Output — Select Folder

  2. Enable Debug Information to store symbolic debug information within the executable file for source level program testing with the µVision debugger.

    Options for Target — Output — Debug Information Selection

  3. Enable Create HEX File to generate an Intel HEX file for Flash programming with external utilities.

    Options for Target — Create HEX File


MCBSTM32F200/400 User's Guide: Setting Target Options

Setting Target Options

You must select the speed and memory configurations for your target hardware. Since these features of the MCBSTM32F200 are fixed, copy the settings as shown below. The steps for setting the target options are:

  1. Open the Target Tab of the Project — Options for Target dialog.

    Options for Target - XTAL Type in the XTAL (MHz) of 25.0 for the oscillator frequency.

  2. Enter the memory ROM area for your target system in IROM1.

    Options for Target - IROM1 Enter the starting address of 0x8000000 in Start and the size of 0x80000 in Size.

    The MCBSTM32F200 has on-chip ROM from 0x8000000 to 0x807FFFF for a total of 0x80000 bytes.

    Clicking the Startup radio button assigns your startup code to this area of memory.

  3. Enter the RAM memory area for your target system in IRAM1.

    Options for Target - IRAM1 Enter the starting address of 0x2000000 in Start and the size of 0x10000 in Size.

    The MCBSTM32F200 has on-chip RAM from 0x20000000 to 0x2000FFFF for a total of 0x10000 bytes.

Note

  • In the licensed (non-evaluation) version of MDK-ARM, the Memory Areas parameters automatically configure the scatter file for the RealView Linker/Locator.


MCBSTM32F200/400 User's Guide: Creating Application Programs

Creating Application Programs

The required steps for creating application programs are outlined here.

µVision includes a Project Manager that makes it easy for you to design applications quickly. The topics below show you how to create a project, set the target options, configure the output files, and build an application program that is ready to download to the MCBSTM32F200 board.

The release of MDK-ARM V5.00 allows you to create a new project with the help of a Software Component Pack and the RTE Manager. Start with the Creating an MDK V5 Project step below when creating a project using MDK V5.00 or later.

  1. Creating an MDK V4 Project
    or
    Creating an MDK V5 Project
  2. Setting Target Options
  3. Configuring Output Files
  4. Building a Program

Detailed information can be found in the µVision User's Guide in the Creating Applications chapter.