Skip to main content
Knowledgebase
Home
Renesas Electronics Europe - Knowledgebase

How to create a new Synergy project

Latest Updated:03/27/2018

Overview

This guide will help you create your first project that can be run on Renesas Synergy boards using the Integrated System Development Environment (ISDE) based on e2 studio. The steps described below are usually followed every time a new project for Synergy is created from scratch.

Goal

After completing this how-to guide you will be able to create a basic Synergy project that is ready to be compiled and run on a Renesas Synergy board.

Initial project configuration

  1. Begin by opening e2studio ISDE and pointing to workspace directory of your choice.
  2. Navigate to File -> New -> Synergy C/C++ Project.
  3. Select Renesas C Executable Project and click next.
  4. Enter the desired project name and select the toolset (GCC ARM is the default).
  5. Select a valid license file. Click next.
    1. Note: If the license entry is empty, click Change license file and select the location of the license file (usually at <install location> \internal\projectgen\licenses\ <license>. Click OK and then Next.
  6. On the next page, select your SSP Version and your target board. (Projects created for a specific development or starter kit will usually not run on a different board). The device field is filled automatically when a non-custom board is selected.
  7. Additional toolchain options are also available. For GCC, it is recommended to leave these unchanged. In case where fields are empty, please make sure you have correctly installed and registered the GCC ARM Embedded toolchain.
  8. On the final tab, you're able to select project template as a foundation for your code. For most applications, the board-specific Board Support Package (BSP) is suitable. 

Using Synergy Project Configurator

The initial setup created the basic directory structure for your project. The Synergy Project Configurator should be opened automatically and you can select between several tabs at the bottom of the configurator window:

  • Summary tab breaks down selected software components as well as target board and device.
  • BSP tab shows the selected SSP version, Board and Device. Note that some components included in the project may not be compatible with a different target board (eg. when moving graphics LCD project form S7 onto S3 board). The Properties window in the bottom left is available when the BSP tab is selected. It allows you to replace the default board support package settings. This is for experienced users only. 
  • Clocks tab provides detailed configuration for clock generation circuit module. For most projects, these settings should be left at their default values.
  • Pins tab is used to create a pin configuration file. Most connections on the chip package can be used for multiple peripherals. When using external peripherals such as graphic LCD or pushbutton switches, their pins have to be connected and set to the appropriate characteristics (direction, pull up, drive capacity and output level) in order to be functional and addressable from within the source code. Note that JTAG pins should always stay connected during development, as disconnecting them will leave the board inaccessible by the programmer and debugger.
  • Threads tab is the main place used for configuring your project contents. Here, you can create additional threads (thus, enabling the ThreadX RTOS) and populate them with drivers, frameworks and RTOS objects (such as queues or event flags). Each item has it's own settings that can be adjusted on the Properties window on the bottom left half of the screen.
  • Components tab lists all the modules available from the installed Synergy Support Package. Installing more than one version of SSP will enable you to choose between two versions of a given module. Selection boxes are used to include the features in the project but it's also done automatically, when populating Modules using the Threads tab, with the same entires.

After the project has been configured the  Generate Project Content button has to be pressed in order to export the project setup into compatilable C code.

Understanding the directory structure of a Synergy project

Project contents are grouped into different folders, depending on their type and purpose:

  • src folder contains user code for execution once the system has booted up and is running
    • synergy_gen folder contains files generated by Synergy Project Configurator and they should not be edited as any changes will be overwritten with the configurator output. This source code usually defines API instances for the modules selected as well as interrupt function prototypes.
    • hal_entry.c file features hal_entry function that is called at the end of start-up procedure. It is only relevant in non-RTOS projects (only one thread: HAL/Common in the Threads tab in the configurator) as the function is not called during ThreadX start-up.
    • new_thread_entry.c and any other _entry.c file holds user code executed inside the threads that were created using the configurator. Similarly to hal_entry file, the function will exit once it reaches the end and therefore for continuous execution, it is advised to place the code in a permanent loop inside that function.
  • synergy directory stores complete board support package for the target device as well as selected SSP components (that includes HAL drivers and frameworks). Changes in the Synergy Configurator usually reflect on the contents of this folder.
  • script holds the linker script file used to pre-configure the memory space on the target device. This file is always the same for a given board.
  • synergy_cfg folder contains low-level board setup such as pin, interrupt and clock configuration files. These are also generated by the configurator and shouldn't be edited manually.
  • configuration.xml is the Synergy Configurator file. It's explained in detail in the previous section.
  • .pincfg file is used by the ISDE to generate the actual pin setup file (bsp_pin_cfg.h). Every Synergy project is created with deafult pin settings that can be altered using Synergy Configurator.
  • .launch and .jlink files store debug and runtime configuration of the project and in most cases, they shouldn't be edited by user.

What's Next

Now, you should able to create and edit Synergy projects. Feel free to revisit this guide to refresh your understanding of the e2 studio ISDE.

You're now ready to learn more about project development. The Getting Started with Development in SSP article covers all the basic tasks you will need to use the Synergy ISDE for common development activities. Check it our here.