]> rtime.felk.cvut.cz Git - arc.git/commitdiff
EcuM: more fixes
authormahi <devnull@localhost>
Mon, 10 Sep 2012 13:17:15 +0000 (15:17 +0200)
committermahi <devnull@localhost>
Mon, 10 Sep 2012 13:17:15 +0000 (15:17 +0200)
include/EcuM_Types.h
system/EcuM/EcuM.c
system/EcuM/EcuM_Main.c

index 4d6b1d6ca65d44652ba41152cb1af76fb94b7f4d..903c916ed5ec6244277408b50599c336d98c6e53 100644 (file)
@@ -45,6 +45,7 @@
 #if defined(USE_WDGM)\r
 typedef struct EcuM_WdgM\r
 {\r
+       WdgM_SupervisedEntityIdType EcuMSupervisedEntity;\r
        WdgM_ModeType EcuMWdgMWakeupMode;\r
        WdgM_ModeType EcuMWdgMStartupMode;\r
        WdgM_ModeType EcuMWdgMRunMode;\r
@@ -53,6 +54,14 @@ typedef struct EcuM_WdgM
 } EcuM_WdgMType;\r
 #endif\r
 \r
+typedef struct EcuM_WakeupSourceConfig {\r
+       EcuM_WakeupSourceType   EcuMWakeupSourceId;\r
+       uint32                                  EcuMValidationTimeout;\r
+       Mcu_ResetType                   EcuMResetReason;\r
+       boolean                                 EcuMWakeupSourcePolling;\r
+       uint8                                   EcuMComMChannel;\r
+} EcuM_WakeupSourceConfigType;\r
+\r
 typedef struct EcuM_SleepMode\r
 {\r
    uint8                                       EcuMSleepModeId;\r
index 04d1cf8fff0edb2d3d37a84e55c4c6c4a6c33f60..5f3cd5689abac1fda31700554d13737de03a6b0f 100644 (file)
@@ -401,7 +401,7 @@ void EcuM_SetWakeupEvent(EcuM_WakeupSourceType sources) {
        internal_data.wakeupEvents |= sources;\r
 \r
        /* @req 3.1.5/EcuM2707 @req 3.1.5/EcuM2709*/\r
-       internal_data.wakeupTimer = ECUM_VALIDATION_TIMEOUT;\r
+//     internal_data.wakeupTimer = ECUM_VALIDATION_TIMEOUT;\r
 \r
 }\r
 \r
index 3fbed82c590d47977d2167ab9e452b8f734ea94e..4cfdf2465898f850c3d696a94e5465ea1ac9f5c2 100644 (file)
@@ -104,7 +104,7 @@ void EcuM_enter_run_mode(void){
 \r
 #if defined(USE_WDGM)\r
        /* This seems strange, should be in FW instead */\r
-       WdgM_SetMode(TODO_MODE);\r
+       WdgM_SetMode(internal_data.config->EcuMWdgMConfig->EcuMWdgMRunMode);\r
 #endif\r
 \r
 #if defined(USE_COMM)\r
@@ -269,7 +269,7 @@ static inline void in_state_appRun(void){
                EcuM_OnExitRun();       /** @req EcuM2865 */\r
 \r
 #if defined(USE_WDGM)\r
-               WdgM_SetMode(FIXME_MODE);\r
+               // This is APPRUN not RUN.. so WdgM_SetMode() should not be called?\r
 #endif\r
 \r
 #if defined(USE_RTE) && defined(CFG_ECUM_USE_SERVICE_COMPONENT)\r
@@ -382,7 +382,7 @@ void EcuM_MainFunction(void){
                        Mcu_SetMode(MCU_MODE_NORMAL);\r
 \r
 #if defined(USE_WDGM)\r
-                       WdgM_SetMode(FIXME_MODE);\r
+                       WdgM_SetMode(internal_data.config->EcuMWdgMConfig->EcuMWdgMWakeupMode);\r
 #endif\r
 \r
                        wMask = EcuM_GetPendingWakeupEvents();\r