Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Overview

This page is for quick tips to help you with RL78 MCUs, its software, tools, and boards.ย  If you have any tips, please let us know and we will include them here.ย ย 

RL78 Tips and Tricks

Here are the frequently asked RL78 questions and answers to them.ย  There are a few tips and tricks also to help your journey with your development.ย ย 

What is Self RAM for

RL78

MCUs?In RL78 series MCUs, "Self RAM" refers to the RAM area that must be allocated or reserved when the user utilizes the RL78 series

Flash Self

-

Programming

Library.

The relevant application documentation for the RL78 series Flash Self-Programming Library includes descriptions of Self RAM. For example, the section 9.4 "Defining the Internal RAM Area" in the RL78 Family Flash Self-Programming Library Type01 Package Ver.4.00 Release Note provides detailed information about Self RAM allocation.

Taking e2 studio and the CC-RL compiler as an example.

In the default configuration, the user RAM area is allocated at the beginning address of the RAM region (for example, this starts at address 0xFEF00 for R5F100LEA). However, when using the Flash Self-Programming Library, it is necessary to reserve the address range from 0xFEF00 to 0xFF2FF as the Self RAM area. Therefore, the user RAM area must be allocated outside of this range. For the R5F100LEA, the starting address of the user RAM must be modified from 0xFEF00 to 0xFF300.

Users can set the reserved Self RAM area in the following two ways.

Method 1: Manual Method
First, navigate to Project Properties โ†’ C/C++ Build โ†’ Settings โ†’ Linker โ†’ Sections and uncheck Layout sections automatically. Then, manually edit the section to change the starting address of the RAM from 0xFEF00 to 0xFF300.

Image Removed

Method 2: Automatic Method
First, navigate to Project Properties โ†’ C/C++ Build โ†’ Settings โ†’ Linker โ†’ Sections and check Layout sections automatically.

Image Removed

Then, in Project Properties โ†’ C/C++ Build โ†’ Settings โ†’ Linker โ†’ Device โ†’ RAM Area Without Section, select Self RAM Area from the dropdown menu.

Image Removed

InfoPlaceholder

Considerations

Some quick tips to help you with Flash Self-programming RL78 MCUs.ย 

RL78 Flash Self Programming Considerationsย 

Link Executables of Any Size

This tip shows you how to link executable files of any size.ย  This could be needed as RL78 MCUs several addressing modes e.g., SFR addressign, register addressing, short direct addressing and direct addressing to name a few.ย  RL78 MCUs utilize ES and CS registers to expand the addressign spaces to 20 bits.ย ย 

Link Executables of Any Size



Table of Contents