Site Search

With the recent spread of advanced electronic control systems, the importance of functional safety is increasing in fields such as industrial equipment and robot development. From design to development and evaluation, ensuring compliance with safety standards is a major challenge for developers. Against this backdrop, there is a need for efficient system design that takes functional safety into consideration.

 

This article explains a configuration example when using the Functional Safety Platform Software (PL-SW) with the Renesas RX65 (RX651 series) microcontroller, using a torque sensor development example using Macnica 's semiconductor strain sensor STREAL. This is ideal for developers and designers who want to efficiently design functional safety-compliant software.

 

* Torque sensor: A sensor that detects the torque applied to the rotating shaft of a machine or device and converts that value into an electrical signal.

What is Renesas Functional Safety Platform Software (PL-SW)?

PL-SW is functional safety platform software that makes it easy to develop dual-redundant functional safety systems using microcontrollers.

It mainly has the following functions:

1. Microcomputer diagnosis through self-diagnosis and mutual monitoring
2. Scheduler controls execution of user software
3.​ ​Partitioning

Figure 1: Overview of self-and mutual-diagnostic functions in a dual-redundant configuration using PL-SW​ ​(Source: Renesas Electronics Corporation, "RX Functional Safety Solution Introduction.PDF")

App1: Abnormality monitoring,App2:Torque sensor management section, andApp3:Torque data processing section are user applications that are subject to functional safety.

Figure 2: Software block diagram for torque sensor development

Self-diagnosis and mutual diagnosis configuration

In developing the torque sensor, a double bank configuration is used to implement the firmware (FW) update function.

SCI12 is used for mutual monitoring.

 

*The configuration definition names in this article have been changed from the actual PL-SW.

ROM diagnostic start address

Because of the double bank configuration, the diagnostic size is set to half of the maximum resource of the RX651 (2MB).

Config definition name

set value

Diagnostic Size

USER_SETTING_ROM_DIAG_STADDR

0xFFFE 3000

1MB

Internal RAM diagnostic size

Because of the double bank configuration, the diagnostic size is set to half of the maximum resource of the RX651 (256KB).

Config definition name

set value

Diagnostic Size

USER_SETTING_INT_RAM_SIZE

0x0000 2200

128KB

 

SCI channel for mutual monitoring

Set the peripheral name of the SCI used for mutual monitoring.

 

Config definition name

set value

explanation

USER_SETTING_SCI_CHANNEL

SCI_CH12

Use SCI12

 

Mutual monitoring SCI communication baud rate

Set the maximum speed selectable for the RX651 (7.5Mbps).

 

Config definition name

set value

explanation

USER_SETTING_SCI_BAUDRATE

BAUDRATE_7500000

7.5Mbps

Scheduler configuration

If you want to start the application as follows:

Figure 3: Software execution sequence for torque sensor development

User Application Order

Set the user applications in the order you want them to start.

 

Config definition name

set value

USER_SETTING_USER_APP_SEQUENCE

APP2, APP2, APP1, APP2, APP2, APP2,APP3, APP2, APP2, APP2, APP3, PLSW

User Application Window Time

Set the execution time for each user application.

 

Config definition name

set value

explanation

USER_SETTING_APP1_WINDOW_TIME

XXX

Unit: us

USER_SETTING_APP2_WINDOW_TIME

YYY

Unit: us

USER_SETTING_APP3_WINDOW_TIME

ZZZ

Unit: us

USER_SETTING_APP4_WINDOW_TIME

0

Unit: us

Partitioning configuration

App2: Torque sensor management section

App2 has the function to communicate with external devices using SCI 5.

Therefore, in order to access the SCI5 related registers, the permission settings must be enabled.

Figure 4: Functional safety target applications in torque sensor development

MPU access permission area settings

Sets the address range for SCI5 related registers.

 

Config definition name

set value

explanation

USER_SETTING_APP2_AREA6_STADDR

0x0008A0A0ul

SCI5 register area

USER_SETTING_APP2_AREA6_ENDDDR

0x0008A0C0ul

USER_SETTING_APP2_AREA6_ACCESS_MODE

RAM_ACCESS

 

For those who want to know more

We have an on-demand video available that explains the contents of this article in more detail.

If you are interested, please click on the banner below to apply!