Filter löschen
Filter löschen

Initialize value for compatible Data Store Block

1 Ansicht (letzte 30 Tage)
xian zhao
xian zhao am 21 Okt. 2018
According to ecoder_autosar manual, I generate a model to model the BSW service call. In the model there is a data store block named "A", and the initial value is 2. After code generation, I found the block "A" is declare however the initialize is implemented during the SWC initialize. I wonder if there is any problem in case there is a logic change the value stored in ROM during operation or by calibration, the initialize procedure will change the value located in RAM which is loaded from ROM since the initial valued build in code is still unchanged.
19 /* Exported block states */
20 uint8_T A; /* '<Root>/Data Store Memory' */
81 /* Model initialize function */
82 void Runnable_Initialize(void)
83 {
84 /* Start for DataStoreMemory: '<Root>/Data Store Memory' */
85 A = 2U;
86
87 /* SystemInitialize for Atomic SubSystem: '<Root>/Runnable_Initialize' */
88 /* StateWriter: '<S1>/State Writer' incorporates:
89 * Constant: '<S1>/Constant'
90 */
91 rtDW.Integrator_DSTATE = 1.0;
92
93 /* End of SystemInitialize for SubSystem: '<Root>/Runnable_Initialize' */
94 }

Antworten (0)

Kategorien

Mehr zu AUTOSAR Blockset finden Sie in Help Center und File Exchange

Produkte


Version

R2018a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by