Renesas RX111 User Manual

(http://www.renesas.com).
RX111 Group
Renesas Starter Kit Tutorial Manual
For CubeSuite+
Rev. 1.00 Jul 2013
32
RENESAS MCU RX
32
User’s Manual
Family / RX100 Series
All information contained in thes e m aterials, includi ng produc ts and prod uct s pecif ications, r eprese nts information on the prod uct at the tim e of p ublicat ion a nd is su bjec t to c hange b y Renesas E lectron ics Corporation without notice. Please review the latest information published by Renesas Electronics Corporation through various means, including the Renesas Electronics Corporation website
(2012.4)
Notice
1. Descriptions of circuits, software and other related information in this document are provided only to illustrate the operation of semiconductor products and application examples. You are fully responsible for the incorporation of these circuits, software, and information in the design of your equipment. Renesas Electronics ass um es no responsibility for any losses incurred by you or third parties arising from the use of these circuits, software, or information.
2. Renesas Electronics has used reasonable c are in preparing the information included in this document, but Renesas Electronics does not warrant that such information is error free. Renesas Electronics assumes no liability whatsoever for any damages incurred by you resulting from errors in or omissions from the information included herein.
3. Renesas Electronics does not assume any liability for infringement of patents, copyrights, or other intellectual property rights of third parties by or arising from the use of Renesas Electronics products or technical information described in this document. No license, express, implied or otherwise, is granted hereby under any patents, copyrights or other intellectual property rights of Renesas Electronics or others.
4. You should not alter, modify, copy, or otherwise misappropriate any Renesas Electronics product, whether in whole or in part. Renesas Electronics assumes no responsibi li ty for any losses incurred by you or third parties arising from such alteration, modification, copy or otherwise misappropriation of Renesas Electronics product.
5. Renesas Electronics products are classified according to the following two quality grades : “Standard” and “High Quality”. The recommended applications for each Renesas Electronics product depends on the product’s qual ity grade, as indicated below.
“Standard”: Computers; office equipment; communications equipment; test and measurement equipment; audio and visual equipment; home electronic appliances; machine tools; personal electronic equipment; and industrial robots etc.
“High Quality”: Transportation equipment (automobiles, trains, ships, etc.); traffic control systems; anti-disaster systems; anticrime systems; and safety equipment etc.
Renesas Electronics products are neither intended nor authorized for use in products or systems that may pose a direct threat to human life or bodily injury (artificial life support devices or systems, surgical implantations etc.), or may cause serious property damages (nuclear reactor control systems, military equipment etc.). You must check the quality grade of each Renesas Electronics produc t before using it in a particular application. You may not use any Renesas Electronics product for any application f or which it is not intended. Renesas Electronics shall not be in any way liable for any damages or losses incurred by you or third parties arising from the use of an y Renesas Electronics product for which the product is not intended by Renesas Electronics.
6. You should use the Renesas Electronics products described in this document within the range specified by Renesas Electronics, especially with respect to the maximum rating, operating supply voltage range, movement power voltage range, heat radiation characteristics, installation and other product characteristics. Renesas Electronics shall have no liability for malfunctions or damages arising out of the use of Renesas Electronics products beyond such specified ranges.
7. Although Renesas Electronics endeavors to improve the quality and reliability of its produ c ts, semiconductor products have specific characteristics such as the oc currence of failure at a certain rate and m al functions under certain use conditions. Further, Renesas Electronics products are not subject to radiation resistance design. Please be sure to implement safety measures to guard them against the possibility of physical injury, and injury or damage caused by fire in the event of the failure of a Renesas Electronics product, such as safety design for hardware and software including but not limited to redundancy, fire control and malfunction prevention, appropriate treatment for aging degradation or any other appropriate measures. Because the evaluation of microcomputer software alone is very difficult, please evaluate the safety of the final products or systems manufactured by you.
8. Please contact a Renesas Electronics sales office for details as to environmental matters such as the environmental compatibility of each Renesas Electronics product. Please use Renesas Electronics products in compliance with all applicable laws and regulations that regulate the inclusion or use of controlled substances , including without limitation, the EU RoHS Directive. Renesas Electronics as s umes no liability for damages or losses occurring as a result of your noncompliance with applicable laws and regulations.
9. Renesas Electronics products and technology ma y n ot be used for or incorporated into any products or systems whose manufacture, use, or sale is prohibited under any applicable domestic or foreign laws or regulations. You should not use Renesas Electronics products or technology desc ribed in this document for any purpos e relating to military applications or use by the military, including but not limited to the development of weapons of mass destruction. When exporting the Renesas Electronics products or technology described in this document, y ou should comply with the applicable export control laws and regulations and follow the procedures required by such laws and regulations.
10. It is the responsibility of the buyer or distributor of Renesas Electronics products, who distributes, disposes of, or otherwise places the product with a third party, to notify such third party in advance of the c ontents and c ondi tions set forth in this document, Renesas Electronics assumes no responsibility for any losses incurred by you or third parties as a result of unauthorized use of Renesas Electronics products.
11. This document may not be reproduced or duplicated in any form, in whole or in part, witho ut prior written consent of Renesas Electronics.
12. Please contact a Renesas Electronics sales office if you have any questions regarding the information contained in this document or Renesas Electronics products, or if you have any other inquiries.
(Note 1) “Renesas Electronics” as used i n this document means Renesas Electronics Corporation and also includes its
majority owned subsidiaries.
(Note 2) “Renesas Electronics product(s)” means any product developed or manufactured by or for Renesas Electronics.
The RSK is not guaranteed to be error free, and the entire risk as to the results and performance of the RSK is
conditions. A safe separation distance should be used between this and any sensitive equipment. Its use outside the
equipment causes harmful interference to radio or television reception, which can be determined by turning the
Disclaimer
By using this Renesas Starter Kit (RSK), the user accepts the following terms:
assumed by the User. The RSK is provided by Renesas on an “as is” basis without warranty of any kind whether express or implied, including but not limited to the implied warranties of satisfactory quality, fitness for a particular purpose, title and non-infringement of intellectual property rights with regard to the RSK. Renesas expressly disclaims all such warranties. Renesas or its affiliates shall in no event be liable for any loss of profit, loss of data, loss of contract, loss of business, damage to reputation or goodwill, any economic loss, any reprogramming or recall costs (whether the foregoing losses are direct or indirect) nor shall Renesas or its affiliates be liable for any other direct or indirect special, incidental or consequential damages arising out of or in relation to the use of this RSK, ev en if Renesas or its affiliates have been advised of the possibility of such damages.
Precautions
The following precautions should be observed when operating any RSK product:
This Renesas Starter Kit is only intended for use in a laboratory environment under ambient temperature and humidity laboratory, classroom, study area or similar such area invalidates conformity with the protection requirements of the
Electromagnetic Compatib ili t y Directive and cou ld lead to prosec utio n.
The product generates, uses, and can radiate radio frequency energy and may cause harmful interference to radio communications. However, there is no guarantee that interference will not occur in a particular installation. If this
equipment off or on, you are encouraged to try to correct the interference by one or more of the following measures;
ensure attached cables do not lie across the equipm ent
reorient the receiving antenna
increase the distance between the equipment and the receiver
connect the equipment into an outlet on a circuit different from that which the receiver is connected
power down the equipment when not in use
consult the dealer or an experienced radio/TV technician for help NOTE: It is recommended that wherever
possible shielded interface cables are used.
The product is potentially susceptible to certain EMC phenomena. To mitigate against them it is recommended that the following measures be undertaken;
The user is advised that mobile phones should not be used within 10m of the product when in use.
The user is advised to take ESD precautions when handling the equipment.
The Renesas Starter Kit does not represent an ideal reference design for an end product and does not fulfil the regulatory standards for an end product.
Particular attention should be paid to the precautionary notes when using the manual. These notes occur within the body
How to Use This Manual
1. Purpose and Target Readers
This manual is designed to prov ide the user with an u nderstanding of how to use the e and debug software for the R SK pl atform. It is intended f or us er s des ign ing sample code on the RSK pl atform, using the many different incorporated peripheral devices.
The manual comprises of step-by-step instructions to load and debug a project in e intend to be a complete guide to software development on the RSK platform. Further details regarding operating the RX111 microcontroller m ay be found in the Hardware Ma nual and within the provided sam ple code.
of the text, at the end of each section, and in the Usage Notes section.
The revision history summarizes the locations of revisions and additions. It does not list all revisions. Refer to the text of the manual for details.
The following documents apply to the RX111 Group. Make sure to refer to the latest versions of these documents. The newest vers ions of the doc um ents listed m a y be obtained from the Renesas Electronic s Web site.
Document Type Description Document Title Document No.
User’s Manual Describes the technical details of the RSK hardware. RSKRX111 User’s
Manual
Tutorial Provides a guide to setting up RSK environment,
running sample code and debugging programs.
Quick Start Guide Provides simple instructions to setup the RSK and
run the first sample, on a single A4 sheet.
Schematics Full detail circuit schematics of the RSK. RSKRX111
Hardware Manual Provides technical details of the RX111
microcontroller.
RSKRX111 Tutorial Manual
RSKRX111 Quick Start Guide
Schematics RX111 Group
Hardware Manual
2
studio I DE to de velop
2
studio, but does not
R20UT2193EG
R20UT2194EG
R20UT2195EG
R20UT2192EG
R01UH0365EJ
Abbreviation
Full Form
ADC
Analog-to-Digital Converter
E1
On-chip Debugger
EMC
Electromagnetic Compatibility
ESD
Electrostatic Discharge
LCD
Liquid Crystal Display
LED
Light Emitting Diode
MCU
Micro-controller Unit
PmodTM
This is a Digilent Pmod™ Compatible connector. PmodTM is registered to Digilent Inc. RSK
Renesas Starter Kit
LIN
Local Interconnect Network
2. List of Abbreviations and Acronyms
Digilent-Pmod_Interface_Specification (Link valid at 26Jun2013)
Table of Contents
1. Overview ............................................................................................................................ 7
1.1 Purpose ...................................................................................................................................................... 7
1.2 Features ..................................................................................................................................................... 7
2. Introduction ........................................................................................................................ 8
2.1 Note Regarding Source Code .................................................................................................................... 8
3. Tutor ial Projec t Wor ks pac e ................................................................................................ 9
3.1 Introduction ................................................................................................................................................ 9
3.2 Starting CubeSuite+ and Connecting the E1 Debugger ............................................................................ 9
3.3 Configuring the Debug Tool (E1) ............................................................................................................. 12
3.4 Build Configuration ................................................................................................................................... 13
4. Building the Tutorial Program .......................................................................................... 15
4.1 Building the Code ..................................................................................................................................... 15
4.2 Connecting the Debugger ........................................................................................................................ 16
4.3 Saving Project Settings ............................................................................................................................ 17
5. Downloading and Running the Tutorial ............................................................................ 18
5.1 Downloading the Program Code .............................................................................................................. 18
5.2 Running the Tutorial ................................................................................................................................. 18
6. Reviewing the Tutorial Program ....................................................................................... 19
6.1 Program Initialisation ............................................................................................................................... 19
6.2 Main Functions ......................................................................................................................................... 20
7. Additional Information ...................................................................................................... 23
RSKRX111 R20UT2194EG0100
Rev. 1.00 RENESAS STARTER KIT
Jul 3, 2013

1. Overview

1.1 Purpose

This RSK is an evaluation tool for Renesas microcontrollers. This manual describes how to get the RSK tutorial started, and basic debugging operations.

1.2 Features

This RSK provides an evaluation of the following features:
Renesas microcontroller programming
User code debugging
User circuitry such as switches, LEDs and a potentiometer
Sample application
Sample peripheral device initialisation code
The RSK board contains all the circuitry required for microcontroller operation.
R20UT2194EG0100 Rev. 1.00 Page 7 of 27 Jul 3, 2013
RSKRX111 2. Introduction

2. Introduction

This manual is designed to answer, in tutorial form, the most common questions asked about using a Renesas Starter Kit (RSK). The tutorials help explain the following:
How do I compile, link, download and run a simple program on the RSK?
How do I build an embedded application?
How do I use Renesas’ tools?
The project generator will create a tutorial project with three selectable build configurations:
‘DefaultBuild’ is a project with debug support and optimisation level set to two.
‘Debug’ is a project built with the debugger support included. Optimisation is set to zero.
‘Release’ is a project with optimised compile options, producing code suitable for release in a product.
Files referred to in this manual are installed using the project generator as you work through the tutorials. The tutorial examples in this manual assume that installation procedures described in the RSK Quick Start Guide have been completed. Please refer to the Quick Start Guide for details of preparing the configuration.
Some of the illustrative screenshots in this document will show text in the form RXxxx. These are general screenshots and are applicable across the whole RX family. In this case, simply substitute for RXxxx RX111.
These tutorials are designed to show you how to use the RSK and are not intended as a comprehensive introduction to the CubeSuite+ debugger, compiler toolchains or the E1 emulator. Please refer to the relevant user manuals for more in­depth information.

2.1 Note Regarding Source Code

It is possible that line numbers for source code illustrated in this document do not match exactly with that in the actual source files. It is also possible that the source address of instructions illustrated in this manual differ from those in user code compiled from the same source. These differences are minor, and do not affect the functionality of the sample code nor the validity of this manual.
R20UT2194EG0100 Rev. 1.00 Page 8 of 27 Jul 3, 2013
RSKRX111 3. Tutorial Project Workspace

3. Tutorial Project Workspace

3.1 Introduction

CubeSuite+ is an integrated development tool that allows the user to write, c ompile, program and debu g a software project on the RX, 78K, RL and V850 fam il y of Renesas microcontrollers. Cube Suite + will hav e been installed during the installation of the software support for the Renesas Starter Kit product. This manual wil l describe the stages required to create and debug the supplied tutorial code.

3.2 Starting CubeSuite+ and Connecting the E1 Debugger

To use the program, start CubeSuite+ from the Windows The first time CubeSuite+ is started, the One Point Advice dialog box will be shown:
TM
Start Menu.
The One Point Advice dialog box provides s ome useful tips when using CubeSuite+. Pres s ‘OK’ to skip the advice and close the One Point Advice dialog. The user will then be presented with the Start panel.
Under the ‘Open Sample RSK Project’, open a new Tutorial project by selecting the RSKRX111_Tutorial project template and click on ‘Go’ as shown below. This will save a copy of the RSKRX111_Tutorial project.
R20UT2194EG0100 Rev. 1.00 Page 9 of 27 Jul 3, 2013
Loading...
+ 18 hidden pages