element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Embedded and Microcontrollers
  • Technologies
  • More
Embedded and Microcontrollers
Blog Renesas Solution Starter Kit for RX23E-A: build and run the Thermocouple application
  • Blog
  • Forum
  • Documents
  • Quiz
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Embedded and Microcontrollers to participate - click to join for free!
  • Share
  • More
  • Cancel
Group Actions
  • Group RSS
  • More
  • Cancel
Engagement
  • Author Author: Jan Cumps
  • Date Created: 23 Jun 2023 3:08 PM Date Created
  • Views 584 views
  • Likes 5 likes
  • Comments 3 comments
  • RoadTest
  • RX23e-a
  • d2a28d6e-11d8-11ee-be56-0242ac120002
Related
Recommended

Renesas Solution Starter Kit for RX23E-A: build and run the Thermocouple application

Jan Cumps
Jan Cumps
23 Jun 2023

The thermocouple appnote for Road test: Renesas Solution Starter Kit for RX23E-A comes with example firmware. In combination with the stater kit PC Tool, you get a temperature display. The firmware source is available as an e² studio project, but there's no ready-to-load binary. In this post I show how to build it. If you're not into source code: I'll attach the binary in a format that can be loaded on the board with Renesas' Flash Programmer.

image

What do you need:

  • The software from  Renesas Solution Starter Kit for RX23E-A: get up and running (at least the PC Tool. The rest is optional)
  • e² studio, with support for rx23, and the CCRX toolchain (optional)
  • Flash Programmer software

Load and build the example in e² studio (optional)

Start e² studio, and select Import Sample Project from the Welcome Page. Select Online -> RX. Select the device:
image
Select the Thermocouple project and import it
image

Right-click on the imported project, and select Properties. Navigate to C/C++ Build -> Settings -> Toolchain. Select the Renesas CCRX chain.
image
By default, the project build binaries for a debugger. To load it on to our starter kit with Flash Programmer, we need to generate a .mod file. Switch to the Tool Settings tab, and navigate to Converter -> Output. Select Motorola S format file
image
Apply and Close. Build (your 60 days evaluation time starts ticking now)

Load the firmware to the board

Disconnect your board. Change JP17 from Emulator to USB. Plug your board back in. 

Run Renesas Flash Programmer, and start a new project. Select RX200, give your project a name, and select COM port. Then click on Tool Details and select the COM of your board. Now browse to the .mod file that was generated during the build. You'll find it in the HardwareDebug/ subfolder of your e² studio project. Alternative, download the one I attached to this blog. Press Start and the firmware gets loaded.
image

When done, unplug the board, and move JP17 back to Emulator.

Run  the application

Set the jumpers as indicated in the appnote
image

Start PC Tool and Connect. You will notice that the 1st 4 tabs are disabled. But the Application tab now works. It shows the temperature in a graph.
image

Restore the original firmware

You can use Flash Programmer to restore the original firmware. Follow the same steps, but take the rx23ea_rssk_fw.mot that comes with the PC Tool. It sits in the same directory as the .exe

rx23ea_thermocouple.mot.zip

link to all posts

  • Sign in to reply
  • Jan Cumps
    Jan Cumps over 1 year ago

    A few captures while running the code:

    2 DACs read

    R_Config_DSAD0_Get_ValueResult( &dsad0_reg);
    R_Config_DSAD1_Get_ValueResult( &dsad1_reg);


    image

    From 2 complement to signed int
     /** Flag mask, Sign extension */
    dsad0_value = (int32_t) ((dsad0_reg & 0x00FFFFFFU) << 8) >> 8;
    /** Flag mask, Sign extension */
    dsad1_value = (int32_t) ((dsad1_reg & 0x00FFFFFFU) << 8) >> 8;

    image

    Convert ref junction to temp


    float R_RTD_DsadToTemp (float dsad)
    {
    float rrtd = (D_RTD_GAIN * dsad) + D_RTD_OFFSET; /** Convert DSAD Value to RTD resistance value [ohm] */
    uint16_t idx = R_CALC_BinarySearch(s_rtd_table, D_RTD_TABLE_SIZE, rrtd);

    /** Set a temperature range that includes the value of the argument */
    float x0 = s_rtd_table[idx]; /** x0:Temperature range lower limit resistance [ohm] */
    float x1 = s_rtd_table[idx + 1]; /** x1:Temperature range upper limit resistance [ohm] */

    /** convert idx to temperature */
    float y0 = (float) idx + D_RTD_TABLE_TOP_TEMPARATURE;

    /** convert idx + 1 to temperature */
    float y1 = (float) (idx + 1) + D_RTD_TABLE_TOP_TEMPARATURE;

    float f_temp = R_CALC_Lerp(x0, y0, x1, y1, rrtd); /** Calculated temperature [degree] */

    return f_temp;
    }

    image

    etc....

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • Jan Cumps
    Jan Cumps over 2 years ago in reply to shabaz

    It's via RX23 FINED (FINE interface) pin, using the SCI boot mode. Can be used in the field if the designer provides 1 jumper and 2 resistors on the board. 
    It's programming only, not a debug replacement.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
  • shabaz
    shabaz over 2 years ago

    Very interesting! The e2studio is also used for Renesas RA microcontrollers too, so it's good to see that the experience using it is transferrable.

    That Flash Programmer looks neat, it could be useful for in-the-field upgrades. Is that using the bootloader inside the RX chip, or is it some other chip on the development board?

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • More
    • Cancel
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube