Getting started with RH850

Parent Previous Next

For the best evaluation experience we recommend to use the samples, which come already prepared, built and ready-to-go.

Setting up a new RH850 workspace

In this tutorial we will set up a new RH850/F1H workspace, which will be debugged using an iC5000 emulator. We'll be using the On-chip trace buffer.


First create a new workspace by clicking File / Workspace / New Workspace. Choose a file name and location:

New Workspace dialog


New dialog will appear, prompting you to choose the hardware plugin. For use with iSystem tools, such as iC5000, choose the default option, iSYSTEM Development Tools:

Plug-in selection dialog


Hit OK to create a new workspace. The workspace needs to be configured now.

Hardware configuration

Open the Hardware / Hardware dialog and select iC5000 as the Hardware Type:

Hardware Configuration dialog


Connecting to the debugger via the USB

USB communication is set by default. Connect the debugger via the USB and turn it on. Open Hardware / Hardware / Communication tab and click Test to verify that the communication with the emulator can be successfully established.


Communication test result



Connecting to the debugger via the Ethernet

In case you want to communicate with iC5000 via the Ethernet, you may need to connect it via the USB first and set the Ethernet settings. This can be done by powering on the emulator and clicking the System Configuration button in the Hardware / Hardware / Hardware Type dialog. By default the IP address is allocated dynamically, if the DHCP server is available. If the DHCP server is not available, then enter the desired settings and click Apply changes button in order to save them:


System Configuration dialog


The emulator needs to be power-cycled in order for the changes to take place. Open the Communication tab of the Hardware Configuration window to select TCP/IP communication. Either enter the emulators IP address or choose the emulator from the drop-down menu. Now connect the iC5000 via the Ethernet port. Power-cycle the emulator and click Test to check, if the communication is successful.


Communication settings


Specifying the CPU and target board settings

Open the Hardware / Emulation Options dialog and choose the Renesas V850 family from the drop-down menu. Choose the RH850 from the POD/iCARD/iTAG menu and select the CPU you are using. In this case we're using R7F7015032:


CPU selection in the Emulation Options


Next click the CPU Setup button. Most settings are set by default and need to be changed only in specific cases. Following are the ones that need to be configured based on your target board.

Debugging settings

Enter the frequency of the External Oscillator that is present on your target board. This frequency is used by the Renesas native FP5 protocol - flash operations might fail if the value is incorrect.


Entering the Ext. Oscillator clock in the Debugging tab

Advanced CPU Settings

LPD port is set by default. In case the CPU is not yet configured / is configured to use JTAG port, check the Configure device to use this port checkbox.


Advanced CPU Configuration


Verifying the settings

Above settings are crucial to establishing a debug session. If any setting is incorrect, debug session will not be established. In order to verify that above settings are correct, CPU reset should be performed:

Turn off the debugger.

Connect the debug cable to the target board.

Connect the ground wire to the target board.

Turn on the iC5000 debugger.

Then turn on the target board.

Click Debug / Run control / CPU Reset to make sure that debug session can be successfully established.

iC5000 debugger connected to the RH850\F1H target board

Adding a download file

In order to download the application to the microcontroller, the download file must be specified in the workspace. In this tutorial we assume, that the download file containing executable code and debug information is built with a third-party build tool. Open Debug / Files for download window and select New. Choose the desired download file and hit OK. Based on the download file type you may review the available options and click OK to confirm. Download File options dialog will open. If your code needs to be loaded at an offset, enter the offset for the code and the symbols. Click OK to confirm the Download file settings.


Download File options


Enable the Verify against Loaded code option in the Options tab to verify the download process:

Download Options


winIDEA needs to locate the source files in order to be able to debug the application on the source code level. Open Debug / Debug Options / Directories tab and add path to the source files to the alternate project files search directories list. Enable the Search subdirectories option if necessary.


Source file folder added to the alternate project files search directories list

Start debugging

Download the application by choosing Debug / Download. The download will be verified and you will be notified about any download errors, if they occur. You may now debug you application.


winIDEA with most commonly used debug windows

Setting up the Analyzer

To use the On-chip trace buffer, open the Hardware / Analyzer Setup dialog. On-chip trace buffer is already chosen by default. Cycle duration needs to be entered in order to properly display the Profiler timeline. Calculate the cycle duration based on the CPU clock and enter the duration in the Cycle duration field:


Analyzer Setup dialog

To learn how to use the winIDEA Analyzer, please read the dedicated chapters.

Further read

For more detailed information on RH850 debug read the RH850 emulation technical note.

For more information on the Analyzer read the Analyzer help topics.

For more information on the debug windows read the Debug Windows and the Debug Options chapters.