Azzera filtri
Azzera filtri

Initialize value for compatible Data Store Block

1 visualizzazione (ultimi 30 giorni)
xian zhao
xian zhao il 21 Ott 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 }

Risposte (0)

Categorie

Scopri di più su AUTOSAR Blockset in Help Center e File Exchange

Prodotti


Release

R2018a

Community Treasure Hunt

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

Start Hunting!

Translated by