]> rtime.felk.cvut.cz Git - arc.git/commitdiff
Updated EcuM with more functionality.
authorpete <devnull@localhost>
Mon, 18 Oct 2010 08:19:16 +0000 (10:19 +0200)
committerpete <devnull@localhost>
Mon, 18 Oct 2010 08:19:16 +0000 (10:19 +0200)
14 files changed:
boards/board_common.mk
boards/generic/EcuM_Callout_template.c [moved from system/EcuM/EcuM_Callout_template.c with 57% similarity]
boards/generic/EcuM_Cfg.c [new file with mode: 0644]
boards/generic/EcuM_Cfg.h [new file with mode: 0644]
boards/generic/EcuM_Generated_Types.h [new file with mode: 0644]
boards/mpc5567qrtech/build_config.mk
include/EcuM.h
system/EcuM/EcuM.c
system/EcuM/EcuM_Cfg.c [deleted file]
system/EcuM/EcuM_Cfg.h [deleted file]
system/EcuM/EcuM_Generated_Types.h [deleted file]
system/EcuM/EcuM_Internals.h
system/EcuM/EcuM_Main.c
system/EcuM/EcuM_PBcfg.h [deleted file]

index 233cf9b9391a0cb8a3615815d90ab701426ffdf6..3320bc771894afafac4d17251c96fef808440e79 100644 (file)
@@ -12,6 +12,7 @@ obj-$(CFG_STM32_CL) += startup_stm32f10x_cl.o
 #Ecu\r
 #obj-y += EcuM_$(BOARDDIR).o\r
 obj-y += EcuM.o\r
+obj-y += EcuM_Main.o\r
 obj-y += EcuM_Cfg.o\r
 obj-y += EcuM_Callout_template.o\r
 inc-y += $(ROOTDIR)/system/EcuM\r
similarity index 57%
rename from system/EcuM/EcuM_Callout_template.c
rename to boards/generic/EcuM_Callout_template.c
index 6f4d65d67c2a72d526e8aa65fed6e284e299f90f..743e4e8cfec8c5284d7831319ac1109df7aee9d0 100644 (file)
@@ -1,30 +1,20 @@
-/* -------------------------------- Arctic Core ------------------------------\r
- * Arctic Core - the open source AUTOSAR platform http://arccore.com\r
- *\r
- * Copyright (C) 2009  ArcCore AB <contact@arccore.com>\r
- *\r
- * This source code is free software; you can redistribute it and/or modify it\r
- * under the terms of the GNU General Public License version 2 as published by the\r
- * Free Software Foundation; See <http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt>.\r
- *\r
- * This program is distributed in the hope that it will be useful, but\r
- * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY\r
- * or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License\r
- * for more details.\r
- * -------------------------------- Arctic Core ------------------------------*/\r
-\r
-\r
-\r
-\r
-\r
-\r
-\r
-\r
-// This file is just examples of implementation for the stubs needed by\r
-// the EcuM. Every application should use an own version of this\r
-// file to implement the setup and tear down of the system.\r
-\r
-\r
+/* 
+* Configuration of module EcuM (EcuM_Callout_template.c)
+* 
+* Created by: 
+* Configured for (MCU): MPC5567
+* 
+* Module editor vendor:  ArcCore
+* Module editor version: 2.0.0
+* 
+* 
+* Generated by Arctic Studio (http://arccore.com)
+*           on Tue May 25 11:41:52 CEST 2010
+*/
+
+\r
+#warning "This default file may only be used as an example!"
+
 #include "EcuM.h"\r
 #include "Det.h"\r
 #if defined(USE_DEM)\r
 #endif\r
 #if defined(USE_IOHWAB)\r
 #include "IoHwAb.h"\r
-#endif\r
-#if defined(USE_COMM)\r
-#include "ComM.h"\r
-#endif\r
-#if defined(USE_NM)\r
-#include "Nm.h"\r
-#endif\r
-#if defined(USE_CANNM)\r
-#include "CanNm.h"\r
-#endif\r
-#if defined(USE_CANSM)\r
-#include "CanSM.h"\r
-#endif\r
-#if defined(USE_LINSM)\r
-#include "LinSM.h"\r
-#endif\r
-\r
-\r
+#endif
+#if defined(USE_FLS)
+#include "Fls.h"
+#endif
+#if defined(USE_EEP)
+#include "Eep.h"
+#endif
+#if defined(USE_FEE)
+#include "Fee.h"
+#endif\r
+#if defined(USE_EA)
+#include "Ea.h"
+#endif
+#if defined(USE_NVM)
+#include "NvM.h"
+#endif
 \r
 void EcuM_AL_DriverInitZero()\r
 {\r
@@ -155,12 +143,25 @@ void EcuM_AL_DriverInitTwo(const EcuM_ConfigType* ConfigPtr)
 \r
 #if defined(USE_FLS)\r
        // Setup Flash\r
-       FlashInit(ConfigPtr->FlashConfig);\r
-#endif\r
-\r
-       // Setup NVRAM Manaager\r
-       // TODO\r
-\r
+       Fls_Init(ConfigPtr->FlashConfig);\r
+#endif\r
+\r
+#if defined(USE_FEE)
+       // Setup FEE
+       Fee_Init();
+#endif
+
+#if defined(USE_EA)
+       // Setup EA
+       Ea_init();
+#endif
+
+#if defined(USE_NVM)
+       // Setup NVRAM Manager and start the read all job
+       NvM_Init();
+       NvM_ReadAll();
+#endif
+
        // Setup CAN tranceiver\r
        // TODO\r
 \r
@@ -177,11 +178,7 @@ void EcuM_AL_DriverInitTwo(const EcuM_ConfigType* ConfigPtr)
 #if defined(USE_CANTP)\r
        // Setup CAN TP\r
        CanTp_Init();\r
-#endif\r
-\r
-#if defined(USE_CANSM)\r
-       CanSM_Init(ConfigPtr->CanSMConfig);\r
-#endif\r
+#endif
 \r
        // Setup LIN\r
        // TODO\r
@@ -191,16 +188,6 @@ void EcuM_AL_DriverInitTwo(const EcuM_ConfigType* ConfigPtr)
        PduR_Init(ConfigPtr->PduRConfig);\r
 #endif\r
 \r
-#if defined(USE_CANNM)\r
-       // Setup Can Network Manager\r
-       CanNm_Init(ConfigPtr->CanNmConfig);\r
-#endif\r
-\r
-#if defined(USE_NM)\r
-       // Setup Network Management Interface\r
-       Nm_Init(ConfigPtr->NmConfig);\r
-#endif\r
-\r
 #if defined(USE_COM)\r
        // Setup COM layer\r
        Com_Init(ConfigPtr->ComConfig);\r
@@ -215,19 +202,59 @@ void EcuM_AL_DriverInitTwo(const EcuM_ConfigType* ConfigPtr)
        // Setup IO hardware abstraction layer\r
        IoHwAb_Init();\r
 #endif\r
+\r
 }\r
 \r
-void EcuM_AL_DriverInitThree(const EcuM_ConfigType* ConfigPtr)\r
+void EcuM_AL_DriverInitThree(const EcuM_ConfigType ConfigPtr)\r
 {\r
 #if defined(USE_DEM)\r
        // Setup DEM\r
        Dem_Init();\r
 #endif\r
 \r
-       // Setup FIM\r
-\r
-#if defined(USE_COMM)\r
-       // Setup Communication Manager\r
-       ComM_Init(ConfigPtr->ComMConfig);\r
+#if defined(USE_CANIF)\r
+       // Startup the CAN interafce; due to the missing COM manager\r
+       //CanIf_InitController(CAN_CTRL_A, 0);\r
+       //CanIf_SetControllerMode(CAN_CTRL_A, CANIF_CS_STARTED);\r
 #endif\r
 }\r
+
+void EcuM_OnEnterRUN(void)
+{
+
+}
+
+void EcuM_OnExitRun(void)
+{
+
+}
+
+void EcuM_OnExitPostRun(void)
+{
+
+}
+
+void EcuM_OnPrepShutdown(void)
+{
+
+}
+
+void EcuM_OnGoSleep(void)
+{
+
+}
+
+void EcuM_OnGoOffOne(void)
+{
+
+}
+
+void EcuM_OnGoOffTwo(void)
+{
+
+}
+
+void EcuM_AL_SwitchOff(void)
+{
+
+}
diff --git a/boards/generic/EcuM_Cfg.c b/boards/generic/EcuM_Cfg.c
new file mode 100644 (file)
index 0000000..271ffea
--- /dev/null
@@ -0,0 +1,64 @@
+/* 
+* Configuration of module EcuM (EcuM_Cfg.c)
+* 
+* Created by: 
+* Configured for (MCU): MPC5567
+* 
+* Module editor vendor:  ArcCore
+* Module editor version: 2.0.0
+* 
+* 
+* Generated by Arctic Studio (http://arccore.com)
+*           on Tue May 25 11:41:52 CEST 2010
+*/
+
+\r
+\r
+#warning "This default file may only be used as an example!"
+
+#include "EcuM.h"\r
+\r
+EcuM_ConfigType EcuMConfig =\r
+{\r
+       .EcuMDefaultShutdownTarget = ECUM_STATE_RESET,\r
+       .EcuMDefaultShutdownMode = 0, // Don't care\r
+       .EcuMDefaultAppMode = OSDEFAULTAPPMODE,\r
+       .EcuMNvramReadAllTimeout = 10000,
+       .EcuMNvramWriteAllTimeout = 10000,
+       .EcuMRunSelfRequestPeriod = 10000,
+\r
+#if defined(USE_MCU)\r
+       .McuConfig = McuConfigData,\r
+#endif\r
+#if defined(USE_PORT)\r
+       .PortConfig = &PortConfigData,\r
+#endif\r
+#if defined(USE_CAN)\r
+       .CanConfig = &CanConfigData,\r
+#endif\r
+#if defined(USE_CANIF)\r
+       .CanIfConfig = &CanIf_Config,\r
+#endif\r
+#if defined(USE_COM)\r
+       .ComConfig = &ComConfiguration,\r
+#endif\r
+#if defined(USE_PDUR)\r
+       .PduRConfig = &PduR_Config,\r
+#endif\r
+#if defined(USE_DMA)\r
+       .DmaConfig = DmaConfig,\r
+#endif\r
+#if defined(USE_ADC)\r
+       .AdcConfig = AdcConfig,\r
+#endif\r
+#if defined(USE_PWM)\r
+       .PwmConfig = &PwmConfig,\r
+#endif\r
+#if defined(USE_GPT)\r
+    .GptConfig = GptConfigData,\r
+#endif\r
+#if defined(USE_FLS)
+       .FlashConfig = FlsConfigSet,
+#endif
+
+};\r
diff --git a/boards/generic/EcuM_Cfg.h b/boards/generic/EcuM_Cfg.h
new file mode 100644 (file)
index 0000000..59464b8
--- /dev/null
@@ -0,0 +1,42 @@
+/*\r
+ * Configuration of module EcuM (EcuM_Cfg.h)\r
+ *\r
+ * Created by: \r
+ * Configured for (MCU): MPC5567\r
+ *\r
+ * Module vendor: ArcCore\r
+ * Module version: 2.0.0\r
+ *\r
+ * \r
+ * Generated by Arctic Studio (http://arccore.com) \r
+ *           on Thu Oct 14 15:29:52 CEST 2010\r
+ */\r
+\r
+
+#warning "This default file may only be used as an example!"\r
+\r
+#if (ECUM_SW_MAJOR_VERSION != 1) 
+#error "EcuM: Configuration file version differs from BSW version."
+#endif
+
+\r
+\r
+#ifndef ECUM_CFG_H_\r
+#define ECUM_CFG_H_\r
+\r
+#define ECUM_VERSION_INFO_API  STD_ON\r
+#define ECUM_INCLUDE_NVRAM_MGR STD_ON\r
+#define ECUM_DEV_ERROR_DETECT  STD_ON\r
+\r
+#include "EcuM_Generated_Types.h"\r
+\r
+#define ECUM_MAIN_FUNCTION_PERIOD      200\r
+\r
+// EcuM_UserType definitions\r
+typedef enum {\r
+       ECUM_USER_ENDMARK       // Must be the last in list!\r
+} EcuM_UserList;\r
+\r
+extern EcuM_ConfigType EcuMConfig;\r
+\r
+#endif /*ECUM_CFG_H_*/\r
diff --git a/boards/generic/EcuM_Generated_Types.h b/boards/generic/EcuM_Generated_Types.h
new file mode 100644 (file)
index 0000000..e1064d7
--- /dev/null
@@ -0,0 +1,105 @@
+/* 
+* Configuration of module EcuM (EcuM_Generated_Types.h)
+* 
+* Created by: 
+* Configured for (MCU): MPC5567
+* 
+* Module editor vendor:  ArcCore
+* Module editor version: 2.0.0
+* 
+* 
+* Generated by Arctic Studio (http://arccore.com)
+*           on Tue May 25 11:41:52 CEST 2010
+*/
+
+
+#warning "This default file may only be used as an example!"
+
+#if (ECUM_SW_MAJOR_VERSION != 1) 
+#error "EcuM: Configuration file version differs from BSW version."
+#endif
+
+\r
+#ifndef _ECUM_GENERATED_TYPES_H_\r
+#define _ECUM_GENERATED_TYPES_H_\r
+\r
+#if defined(USE_MCU)\r
+#include "Mcu.h"\r
+#endif\r
+#if defined(USE_PORT)\r
+#include "Port.h"\r
+#endif\r
+#if defined(USE_CAN)\r
+#include "Can.h"\r
+#endif\r
+#if defined(USE_CANIF)\r
+#include "CanIf.h"\r
+#endif\r
+#if defined(USE_PWM)\r
+#include "Pwm.h"\r
+#endif\r
+#if defined(USE_COM)\r
+#include "Com.h"\r
+#endif\r
+#if defined(USE_PDUR)\r
+#include "PduR.h"\r
+#endif\r
+#if defined(USE_DMA)\r
+#include "Dma.h"\r
+#endif\r
+#if defined(USE_ADC)\r
+#include "Adc.h"\r
+#endif\r
+#if defined(USE_GPT)\r
+#include "Gpt.h"\r
+#endif\r
+#if defined(USE_FLS)
+#include "Fls.h"
+#endif
+\r
+\r
+typedef struct\r
+{\r
+       EcuM_StateType EcuMDefaultShutdownTarget;\r
+       uint8 EcuMDefaultShutdownMode;\r
+       AppModeType EcuMDefaultAppMode;\r
+       uint32 EcuMRunSelfRequestPeriod;
+       uint32 EcuMNvramReadAllTimeout;
+       uint32 EcuMNvramWriteAllTimeout;
+\r
+#if defined(USE_MCU)\r
+       const Mcu_ConfigType* McuConfig;\r
+#endif\r
+#if defined(USE_PORT)\r
+       const Port_ConfigType* PortConfig;\r
+#endif\r
+#if defined(USE_CAN)\r
+       const Can_ConfigType* CanConfig;\r
+#endif\r
+#if defined(USE_CANIF)\r
+       const CanIf_ConfigType* CanIfConfig;\r
+#endif\r
+#if defined(USE_COM)\r
+       const Com_ConfigType* ComConfig;\r
+#endif\r
+#if defined(USE_PDUR)\r
+       const PduR_PBConfigType* PduRConfig;\r
+#endif\r
+#if defined(USE_PWM)\r
+       const Pwm_ConfigType* PwmConfig;\r
+#endif\r
+#if defined(USE_DMA)\r
+       const Dma_ConfigType* DmaConfig;\r
+#endif\r
+#if defined(USE_ADC)\r
+    const Adc_ConfigType* AdcConfig;\r
+#endif\r
+#if defined(USE_GPT)\r
+    const Gpt_ConfigType* GptConfig;\r
+#endif\r
+#if defined(USE_FLS)
+       const Fls_ConfigType* FlashConfig;
+#endif
+} EcuM_ConfigType;\r
+\r
+#endif /*_ECUM_GENERATED_TYPES_H_*/\r
index ea3e56ae6860e4a57a29af0c259f97ac8c64ab88..c81bcbf739e8658507053340b018263f8e674d44 100644 (file)
@@ -9,7 +9,7 @@ CFG=PPC BOOKE E200Z6 MPC55XX MPC5567 BRD_MPC5567QRTECH SPE
 \r
 # What buildable modules does this board have, \r
 # default or private\r
-MOD_AVAIL=KERNEL MCU WDG WDGM PORT DIO WDG WDGM PWM CAN CANIF COM ADC DMA DEM DCM CANTP PDUR IOHWAB COMM NM CANNM CANSM RTE NVM MEMIF FEE\r
+MOD_AVAIL=KERNEL MCU WDG WDGM PORT DIO WDG WDGM PWM CAN CANIF COM ADC DMA DEM DCM CANTP PDUR IOHWAB COMM NM CANNM CANSM RTE NVM MEMIF FEE FLS\r
 \r
 # Needed by us\r
 MOD_USE=KERNEL MCU\r
index bfa88400e8ed63778bf4e02d6ddf4fbcdd6e2162..7888595f8ff28ed6268ad003188564418d40d229 100644 (file)
 \r
 /** @name Service id's */\r
 //@{\r
+#define ECUM_REQUESTRUN_ID (0x03)\r
+#define ECUM_RELEASERUN_ID (0x04)\r
+#define ECUM_SELECTSHUTDOWNTARGET_ID (0x06)\r
 #define ECUM_GETSTATE_ID (0x07)\r
+#define ECUM_GETSHUTDOWNTARGET_ID (0x09)\r
+#define ECUM_COMM_REQUESTRUN_ID (0x0e)\r
+#define ECUM_REQUESTPOSTRUN_ID (0x0a)\r
+#define ECUM_RELEASEPOSTRUN_ID (0x0b)\r
 #define ECUM_SELECTAPPMODE_ID (0x0f)\r
+#define ECUM_COMM_RELEASERUN_ID (0x10)\r
 #define ECUM_GETAPPMODE_ID (0x11)\r
 #define ECUM_SELECT_BOOTARGET_ID (0x12)\r
 #define ECUM_GET_BOOTARGET_ID (0x13)\r
 #define ECUM_MAINFUNCTION_ID (0x18)\r
+#define ECUM_COMM_HASREQUESTEDRUN_ID (0x1b)\r
 \r
 /** Possible states */\r
 typedef enum {\r
index 77a32b1e907b1acc39a1e61e56d61a206d623c11..f1bc1624039e87e665c69390b11a1f80dc339047 100644 (file)
@@ -29,6 +29,9 @@
 #include "Mcu.h"\r
 #include "Det.h"\r
 #include "irq.h"\r
+#if    (ECUM_INCLUDE_NVRAM_MGR == STD_ON)\r
+#include "Nvm.h"\r
+#endif\r
 \r
 EcuM_GobalType internal_data;\r
 \r
@@ -64,6 +67,11 @@ void EcuM_Init( void )
 \r
        // Set default application mode\r
        internal_data.app_mode = internal_data.config->EcuMDefaultAppMode;\r
+#if defined(USE_COMM)\r
+       internal_data.run_comm_requests = 0;\r
+#endif\r
+       internal_data.run_requests = 0;\r
+       internal_data.postrun_requests = 0;\r
 \r
        internal_data.initiated = TRUE;\r
 \r
@@ -75,6 +83,7 @@ void EcuM_StartupTwo()
 {\r
 #if    (ECUM_INCLUDE_NVRAM_MGR == STD_ON)\r
        uint32 timer;\r
+       static NvM_RequestResultType readAllResult;\r
 #endif\r
 \r
        internal_data.current_state = ECUM_STATE_STARTUP_TWO;\r
@@ -97,11 +106,10 @@ void EcuM_StartupTwo()
 #endif\r
 \r
 #if    (ECUM_INCLUDE_NVRAM_MGR == STD_ON)\r
-       // Wait for the NVM job to terminate\r
-       while(Os_SysTickGetTimeElapsed()-timer < internal_data.config.EcuMNvramReadAllTimeout)\r
-       {\r
-               //TODO\r
-       }\r
+       // Wait for the NVM job (NvmReadAll) to terminate\r
+       do {\r
+               NvM_GetErrorStatus(0, &readAllResult);  // Read the multiblock status\r
+       } while( (readAllResult == NVM_REQ_PENDING) && !(Os_SysTickGetTimeElapsed() - timer < internal_data.config->EcuMNvramReadAllTimeout) );\r
 #endif\r
 \r
        // Initialize drivers that need NVRAM data\r
@@ -135,13 +143,7 @@ void EcuM_Shutdown()
 \r
 Std_ReturnType EcuM_GetState(EcuM_StateType* state)\r
 {\r
-#if (ECUM_DEV_ERROR_DETECT == STD_ON)\r
-       if (state == NULL)\r
-       {\r
-               Det_ReportError(MODULE_ID_ECUM, 1, ECUM_GETSTATE_ID, ECUM_E_NULL_POINTER);\r
-               return E_NOT_OK;\r
-       }\r
-#endif\r
+       VALIDATE_RV(state != NULL, ECUM_GETSTATE_ID, ECUM_E_NULL_POINTER, E_NOT_OK);\r
 \r
        *state = internal_data.current_state;\r
 \r
@@ -150,13 +152,7 @@ Std_ReturnType EcuM_GetState(EcuM_StateType* state)
 \r
 Std_ReturnType EcuM_SelectApplicationMode(AppModeType appMode)\r
 {\r
-#if (ECUM_DEV_ERROR_DETECT == STD_ON)\r
-       if (!internal_data.initiated)\r
-       {\r
-               Det_ReportError(MODULE_ID_ECUM, 1, ECUM_SELECTAPPMODE_ID, ECUM_E_NOT_INITIATED);\r
-               return E_NOT_OK;\r
-       }\r
-#endif\r
+       VALIDATE_RV(internal_data.initiated, ECUM_SELECTAPPMODE_ID, ECUM_E_NOT_INITIATED, E_NOT_OK);\r
 \r
        // TODO Save this application mode for next startup\r
 \r
@@ -165,19 +161,8 @@ Std_ReturnType EcuM_SelectApplicationMode(AppModeType appMode)
 \r
 Std_ReturnType EcuM_GetApplicationMode(AppModeType* appMode)\r
 {\r
-#if (ECUM_DEV_ERROR_DETECT == STD_ON)\r
-       if (!internal_data.initiated)\r
-       {\r
-               Det_ReportError(MODULE_ID_ECUM, 1, ECUM_GETAPPMODE_ID, ECUM_E_NOT_INITIATED);\r
-               return E_NOT_OK;\r
-       }\r
-\r
-       if (appMode == NULL)\r
-       {\r
-               Det_ReportError(MODULE_ID_ECUM, 1, ECUM_GETAPPMODE_ID, ECUM_E_NULL_POINTER);\r
-               return E_NOT_OK;\r
-       }\r
-#endif\r
+       VALIDATE_RV(internal_data.initiated, ECUM_GETAPPMODE_ID, ECUM_E_NOT_INITIATED, E_NOT_OK);\r
+       VALIDATE_RV(appMode != NULL, ECUM_GETAPPMODE_ID, ECUM_E_NULL_POINTER, E_NOT_OK);\r
 \r
        *appMode = internal_data.app_mode;\r
 \r
@@ -186,13 +171,7 @@ Std_ReturnType EcuM_GetApplicationMode(AppModeType* appMode)
 \r
 Std_ReturnType EcuM_SelectBootTarget(EcuM_BootTargetType target)\r
 {\r
-#if (ECUM_DEV_ERROR_DETECT == STD_ON)\r
-       if (!internal_data.initiated)\r
-       {\r
-               Det_ReportError(MODULE_ID_ECUM, 1, ECUM_SELECT_BOOTARGET_ID, ECUM_E_NOT_INITIATED);\r
-               return E_NOT_OK;\r
-       }\r
-#endif\r
+       VALIDATE_RV(internal_data.initiated, ECUM_SELECT_BOOTARGET_ID, ECUM_E_NOT_INITIATED, E_NOT_OK);\r
 \r
        // TODO Do something great here\r
 \r
@@ -201,21 +180,105 @@ Std_ReturnType EcuM_SelectBootTarget(EcuM_BootTargetType target)
 \r
 Std_ReturnType EcuM_GetBootTarget(EcuM_BootTargetType* target)\r
 {\r
-#if (ECUM_DEV_ERROR_DETECT == STD_ON)\r
-       if (!internal_data.initiated)\r
-       {\r
-               Det_ReportError(MODULE_ID_ECUM, 1, ECUM_GET_BOOTARGET_ID, ECUM_E_NOT_INITIATED);\r
-               return E_NOT_OK;\r
-       }\r
-\r
-       if (target == NULL)\r
-       {\r
-               Det_ReportError(MODULE_ID_ECUM, 1, ECUM_GET_BOOTARGET_ID, ECUM_E_NULL_POINTER);\r
-               return E_NOT_OK;\r
-       }\r
-#endif\r
+       VALIDATE_RV(internal_data.initiated, ECUM_GET_BOOTARGET_ID, ECUM_E_NOT_INITIATED, E_NOT_OK);\r
+       VALIDATE_RV(target != NULL, ECUM_GET_BOOTARGET_ID, ECUM_E_NULL_POINTER, E_NOT_OK);\r
 \r
        // TODO Return selected boot target here\r
 \r
        return E_NOT_OK;\r
 }\r
+\r
+\r
+Std_ReturnType EcuM_SelectShutdownTarget(EcuM_StateType target, uint8 mode)\r
+{\r
+       VALIDATE_RV(internal_data.initiated, ECUM_SELECTSHUTDOWNTARGET_ID, ECUM_E_NOT_INITIATED, E_NOT_OK);\r
+       VALIDATE_RV((target == ECUM_STATE_OFF) || (target == ECUM_STATE_RESET) || (target == ECUM_STATE_SLEEP), ECUM_SELECTSHUTDOWNTARGET_ID, ECUM_E_INVALID_PAR, E_NOT_OK);\r
+\r
+       internal_data.shutdown_target = target;\r
+       internal_data.shutdown_mode = mode;\r
+\r
+       return E_OK;\r
+}\r
+\r
+\r
+Std_ReturnType EcuM_GetShutdownTarget(EcuM_StateType *shutdownTarget, uint8 *sleepMode)\r
+{\r
+       VALIDATE_RV(internal_data.initiated, ECUM_GETSHUTDOWNTARGET_ID, ECUM_E_NOT_INITIATED, E_NOT_OK);\r
+\r
+       *shutdownTarget = internal_data.shutdown_target;\r
+       *sleepMode = internal_data.shutdown_mode;\r
+\r
+       return E_OK;\r
+}\r
+\r
+\r
+Std_ReturnType EcuM_RequestRUN(EcuM_UserType user)\r
+{\r
+       VALIDATE_RV(internal_data.initiated, ECUM_REQUESTRUN_ID, ECUM_E_NOT_INITIATED, E_NOT_OK);\r
+       VALIDATE_RV(user < ECUM_USER_ENDMARK, ECUM_REQUESTRUN_ID, ECUM_E_INVALID_PAR, E_NOT_OK);\r
+\r
+       internal_data.run_requests |= (uint32)1 << user;\r
+\r
+       return E_OK;\r
+}\r
+\r
+Std_ReturnType EcuM_ReleaseRUN(EcuM_UserType user)\r
+{\r
+       VALIDATE_RV(internal_data.initiated, ECUM_RELEASERUN_ID, ECUM_E_NOT_INITIATED, E_NOT_OK);\r
+       VALIDATE_RV(user < ECUM_USER_ENDMARK, ECUM_RELEASERUN_ID, ECUM_E_INVALID_PAR, E_NOT_OK);\r
+\r
+       internal_data.run_requests &= ~((uint32)1 << user);\r
+\r
+       return E_OK;\r
+}\r
+\r
+#if defined(USE_COMM)\r
+Std_ReturnType EcuM_ComM_RequestRUN(NetworkHandleType user)\r
+{\r
+       VALIDATE_RV(internal_data.initiated, ECUM_COMM_REQUESTRUN_ID, ECUM_E_NOT_INITIATED, E_NOT_OK);\r
+       VALIDATE_RV(user < 32, ECUM_COMM_REQUESTRUN_ID, ECUM_E_INVALID_PAR, E_NOT_OK);\r
+\r
+       internal_data.run_comm_requests |= (uint32)1 << user;\r
+\r
+       return E_OK;\r
+}\r
+\r
+Std_ReturnType EcuM_ComM_ReleaseRUN(NetworkHandleType user)\r
+{\r
+       VALIDATE_RV(internal_data.initiated, ECUM_COMM_RELEASERUN_ID, ECUM_E_NOT_INITIATED, E_NOT_OK);\r
+       VALIDATE_RV(user < 32, ECUM_COMM_RELEASERUN_ID, ECUM_E_INVALID_PAR, E_NOT_OK);\r
+\r
+       internal_data.run_comm_requests &= ~((uint32)1 << user);\r
+\r
+       return E_OK;\r
+}\r
+\r
+boolean EcuM_ComM_HasRequestedRUN(NetworkHandleType user)\r
+{\r
+       VALIDATE_RV(internal_data.initiated, ECUM_COMM_HASREQUESTEDRUN_ID, ECUM_E_NOT_INITIATED, E_NOT_OK);\r
+       VALIDATE_RV(user < 32, ECUM_COMM_HASREQUESTEDRUN_ID, ECUM_E_INVALID_PAR, E_NOT_OK);\r
+\r
+       return (internal_data.run_comm_requests &((uint32)1 << user)) != 0;\r
+}\r
+#endif\r
+\r
+Std_ReturnType EcuM_RequestPOST_RUN(EcuM_UserType user)\r
+{\r
+       VALIDATE_RV(internal_data.initiated, ECUM_REQUESTPOSTRUN_ID, ECUM_E_NOT_INITIATED, E_NOT_OK);\r
+       VALIDATE_RV(user < ECUM_USER_ENDMARK, ECUM_REQUESTPOSTRUN_ID, ECUM_E_INVALID_PAR, E_NOT_OK);\r
+\r
+       internal_data.postrun_requests |= (uint32)1 << user;\r
+\r
+       return E_OK;\r
+}\r
+\r
+Std_ReturnType EcuM_ReleasePOST_RUN(EcuM_UserType user)\r
+{\r
+       VALIDATE_RV(internal_data.initiated, ECUM_RELEASEPOSTRUN_ID, ECUM_E_NOT_INITIATED, E_NOT_OK);\r
+       VALIDATE_RV(user < ECUM_USER_ENDMARK, ECUM_RELEASEPOSTRUN_ID, ECUM_E_INVALID_PAR, E_NOT_OK);\r
+\r
+       internal_data.postrun_requests &= ~((uint32)1 << user);\r
+\r
+       return E_OK;\r
+}\r
+\r
diff --git a/system/EcuM/EcuM_Cfg.c b/system/EcuM/EcuM_Cfg.c
deleted file mode 100644 (file)
index 4f42098..0000000
+++ /dev/null
@@ -1,94 +0,0 @@
-/* -------------------------------- Arctic Core ------------------------------\r
- * Arctic Core - the open source AUTOSAR platform http://arccore.com\r
- *\r
- * Copyright (C) 2009  ArcCore AB <contact@arccore.com>\r
- *\r
- * This source code is free software; you can redistribute it and/or modify it\r
- * under the terms of the GNU General Public License version 2 as published by the\r
- * Free Software Foundation; See <http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt>.\r
- *\r
- * This program is distributed in the hope that it will be useful, but\r
- * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY\r
- * or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License\r
- * for more details.\r
- * -------------------------------- Arctic Core ------------------------------*/\r
-\r
-\r
-\r
-\r
-\r
-\r
-\r
-\r
-#include "EcuM.h"\r
-\r
-#if defined(USE_CANSM)\r
-extern const CanSM_ConfigType CanSM_Config;\r
-#endif\r
-#if defined(USE_COMM)\r
-extern const ComM_ConfigType ComM_Config;\r
-#endif\r
-#if defined(USE_NM)\r
-extern const Nm_ConfigType Nm_Config;\r
-#endif\r
-#if defined(USE_CANNM)\r
-extern const CanNm_ConfigType CanNm_Config;\r
-#endif\r
-\r
-EcuM_ConfigType EcuMConfig =\r
-{\r
-       .EcuMDefaultShutdownTarget = ECUM_STATE_RESET,\r
-       .EcuMDefaultShutdownMode = 0, // Don't care\r
-       .EcuMDefaultAppMode = OSDEFAULTAPPMODE,\r
-\r
-#if defined(USE_MCU)\r
-       .McuConfig = McuConfigData,\r
-#endif\r
-#if defined(USE_PORT)\r
-       .PortConfig = &PortConfigData,\r
-#endif\r
-#if defined(USE_CAN)\r
-       .CanConfig = &CanConfigData,\r
-#endif\r
-#if defined(USE_CANIF)\r
-       .CanIfConfig = &CanIf_Config,\r
-#endif\r
-#if defined(USE_CANSM)\r
-       .CanSMConfig = &CanSM_Config,\r
-#endif\r
-#if defined(USE_CANNM)\r
-       .CanNmConfig = &CanNm_Config,\r
-#endif\r
-#if defined(USE_COM)\r
-       .ComConfig = &ComConfiguration,\r
-#endif\r
-#if defined(USE_COMM)\r
-       .ComMConfig = &ComM_Config,\r
-#endif\r
-#if defined(USE_NM)\r
-       .NmConfig = &Nm_Config,\r
-#endif\r
-#if defined(USE_PDUR)\r
-       .PduRConfig = &PduR_Config,\r
-#endif\r
-#if defined(USE_DMA)\r
-       .DmaConfig = DmaConfig,\r
-#endif\r
-#if defined(USE_ADC)\r
-       .AdcConfig = AdcConfig,\r
-#endif\r
-#if defined(USE_PWM)\r
-       .PwmConfig = &PwmConfig,\r
-#endif\r
-#if defined(USE_GPT)\r
-       .GptConfig = GptConfigData,\r
-#endif\r
-};\r
-\r
-void EcuM_OnGoOffTwo( void ) {\r
-\r
-}\r
-\r
-void EcuM_AL_SwitchOff( void ) {\r
-\r
-}\r
diff --git a/system/EcuM/EcuM_Cfg.h b/system/EcuM/EcuM_Cfg.h
deleted file mode 100644 (file)
index 66b4224..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-/* -------------------------------- Arctic Core ------------------------------\r
- * Arctic Core - the open source AUTOSAR platform http://arccore.com\r
- *\r
- * Copyright (C) 2009  ArcCore AB <contact@arccore.com>\r
- *\r
- * This source code is free software; you can redistribute it and/or modify it\r
- * under the terms of the GNU General Public License version 2 as published by the\r
- * Free Software Foundation; See <http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt>.\r
- *\r
- * This program is distributed in the hope that it will be useful, but\r
- * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY\r
- * or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License\r
- * for more details.\r
- * -------------------------------- Arctic Core ------------------------------*/\r
-\r
-\r
-\r
-\r
-\r
-\r
-\r
-\r
-#ifndef ECUM_CFG_H_\r
-#define ECUM_CFG_H_\r
-\r
-#define ECUM_VERSION_INFO_API STD_ON\r
-#define ECUM_INCLUDE_NVRAM_MGR STD_OFF\r
-#define ECUM_DEV_ERROR_DETECT STD_ON\r
-\r
-#include "EcuM_Generated_Types.h"\r
-\r
-extern EcuM_ConfigType EcuMConfig;\r
-\r
-\r
-#endif /*ECUM_CFG_H_*/\r
diff --git a/system/EcuM/EcuM_Generated_Types.h b/system/EcuM/EcuM_Generated_Types.h
deleted file mode 100644 (file)
index b754f86..0000000
+++ /dev/null
@@ -1,118 +0,0 @@
-/* -------------------------------- Arctic Core ------------------------------\r
- * Arctic Core - the open source AUTOSAR platform http://arccore.com\r
- *\r
- * Copyright (C) 2009  ArcCore AB <contact@arccore.com>\r
- *\r
- * This source code is free software; you can redistribute it and/or modify it\r
- * under the terms of the GNU General Public License version 2 as published by the\r
- * Free Software Foundation; See <http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt>.\r
- *\r
- * This program is distributed in the hope that it will be useful, but\r
- * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY\r
- * or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License\r
- * for more details.\r
- * -------------------------------- Arctic Core ------------------------------*/\r
-\r
-\r
-\r
-\r
-#ifndef _ECUM_GENERATED_TYPES_H_\r
-#define _ECUM_GENERATED_TYPES_H_\r
-\r
-#if defined(USE_MCU)\r
-#include "Mcu.h"\r
-#endif\r
-#if defined(USE_PORT)\r
-#include "Port.h"\r
-#endif\r
-#if defined(USE_CAN)\r
-#include "Can.h"\r
-#endif\r
-#if defined(USE_CANIF)\r
-#include "CanIf.h"\r
-#endif\r
-#if defined(USE_PWM)\r
-#include "Pwm.h"\r
-#endif\r
-#if defined(USE_COM)\r
-#include "Com.h"\r
-#endif\r
-#if defined(USE_PDUR)\r
-#include "PduR.h"\r
-#endif\r
-#if defined(USE_DMA)\r
-#include "Dma.h"\r
-#endif\r
-#if defined(USE_ADC)\r
-#include "Adc.h"\r
-#endif\r
-#if defined(USE_GPT)\r
-#include "Gpt.h"\r
-#endif\r
-#if defined(USE_COMM)\r
-#include "ComM.h"\r
-#endif\r
-#if defined(USE_NM)\r
-#include "Nm.h"\r
-#endif\r
-#if defined(USE_CANNM)\r
-#include "CanNm.h"\r
-#endif\r
-#if defined(USE_CANSM)\r
-#include "CanSM.h"\r
-#endif\r
-#if defined(USE_LINSM)\r
-#include "LinSM.h"\r
-#endif\r
-\r
-typedef struct\r
-{\r
-       EcuM_StateType EcuMDefaultShutdownTarget;\r
-       uint8 EcuMDefaultShutdownMode;\r
-       AppModeType EcuMDefaultAppMode;\r
-\r
-#if defined(USE_MCU)\r
-       const Mcu_ConfigType* McuConfig;\r
-#endif\r
-#if defined(USE_PORT)\r
-       const Port_ConfigType* PortConfig;\r
-#endif\r
-#if defined(USE_CAN)\r
-       const Can_ConfigType* CanConfig;\r
-#endif\r
-#if defined(USE_CANIF)\r
-       const CanIf_ConfigType* CanIfConfig;\r
-#endif\r
-#if defined(USE_CANSM)\r
-       const CanSM_ConfigType* CanSMConfig;\r
-#endif\r
-#if defined(USE_NM)\r
-       const Nm_ConfigType* NmConfig;\r
-#endif\r
-#if defined(USE_CANNM)\r
-       const CanNm_ConfigType* CanNmConfig;\r
-#endif\r
-#if defined(USE_COMM)\r
-       const ComM_ConfigType* ComMConfig;\r
-#endif\r
-#if defined(USE_COM)\r
-       const Com_ConfigType* ComConfig;\r
-#endif\r
-#if defined(USE_PDUR)\r
-       const PduR_PBConfigType* PduRConfig;\r
-#endif\r
-#if defined(USE_PWM)\r
-       const Pwm_ConfigType* PwmConfig;\r
-#endif\r
-#if defined(USE_DMA)\r
-       const Dma_ConfigType* DmaConfig;\r
-#endif\r
-#if defined(USE_ADC)\r
-    const Adc_ConfigType* AdcConfig;\r
-#endif\r
-#if defined(USE_GPT)\r
-    const Gpt_ConfigType* GptConfig;\r
-#endif\r
-} EcuM_ConfigType;\r
-\r
-#endif /*_ECUM_GENERATED_TYPES_H_*/\r
index dd76306af51814fcaecb12266cbe70fe34e2276e..18448da59b6f49fd8713470c547c6a3d225149f2 100644 (file)
 #ifndef _ECUM_INTERNALS_H_\r
 #define _ECUM_INTERNALS_H_\r
 \r
+#if  ( ECUM_DEV_ERROR_DETECT == STD_ON )\r
+#include "Det.h"\r
+#define VALIDATE(_exp,_api,_err ) \\r
+        if( !(_exp) ) { \\r
+          Det_ReportError(MODULE_ID_ECUM, 0, _api, _err); \\r
+        }\r
+\r
+#define VALIDATE_RV(_exp,_api,_err,_rv ) \\r
+        if( !(_exp) ) { \\r
+          Det_ReportError(MODULE_ID_ECUM, 0, _api, _err); \\r
+          return _rv; \\r
+        }\r
+\r
+#define VALIDATE_NO_RV(_exp,_api,_err ) \\r
+  if( !(_exp) ) { \\r
+          Det_ReportError(MODULE_ID_ECUM, 0, _api, _err); \\r
+          return; \\r
+        }\r
+#define DET_REPORTERROR(_module,_instance,_api,_err) Det_ReportError(_module,_instance,_api,_err)\r
+\r
+#else\r
+#define VALIDATE(_exp,_api,_err )\r
+#define VALIDATE_RV(_exp,_api,_err,_rv )\r
+#define VALIDATE_NO_RV(_exp,_api,_err )\r
+#define DET_REPORTERROR(_module,_instance,_api,_err)\r
+#endif\r
+\r
+\r
+\r
 typedef struct\r
 {\r
        boolean initiated;\r
@@ -33,6 +62,11 @@ typedef struct
        uint8 shutdown_mode;\r
        AppModeType app_mode;\r
        EcuM_StateType current_state;\r
+#if defined(USE_COMM)\r
+       uint32 run_comm_requests;\r
+#endif\r
+       uint32 run_requests;\r
+       uint32 postrun_requests;\r
 } EcuM_GobalType;\r
 \r
 extern EcuM_GobalType internal_data;\r
index bc8adb46732c2c28a28cc1303da74c542203252e..db164e4ef9d246fef05f6dac980378dad72afc97 100644 (file)
 \r
 \r
 #include "EcuM.h"\r
+#include "EcuM_Cbk.h"\r
 #include "EcuM_Internals.h"\r
+#if defined(USE_DEM)\r
+#include "Dem.h"\r
+#endif\r
+#if    (ECUM_INCLUDE_NVRAM_MGR == STD_ON)\r
+#include "Nvm.h"\r
+#endif\r
+\r
+static uint32 internal_data_run_state_timeout = 0;\r
+#if    (ECUM_INCLUDE_NVRAM_MGR == STD_ON)\r
+static uint32 internal_data_go_off_one_state_timeout = 0;\r
+#endif\r
+\r
+\r
+\r
+static inline void enter_run_mode(void)\r
+{\r
+       internal_data.current_state = ECUM_STATE_APP_RUN;\r
+       EcuM_OnEnterRUN();\r
+       internal_data_run_state_timeout = internal_data.config->EcuMRunSelfRequestPeriod / ECUM_MAIN_FUNCTION_PERIOD;\r
+}\r
+\r
+static inline void enter_post_run_mode(void)\r
+{\r
+       internal_data.current_state = ECUM_STATE_APP_POST_RUN;\r
+}\r
+\r
+static inline void enter_prep_shutdown_mode(void)\r
+{\r
+       internal_data.current_state = ECUM_STATE_PREP_SHUTDOWN;\r
+       EcuM_OnPrepShutdown();\r
+}\r
+\r
+static inline void enter_go_sleep_mode(void)\r
+{\r
+       internal_data.current_state = ECUM_STATE_GO_SLEEP;\r
+       void EcuM_OnGoSleep();\r
+}\r
+\r
+static inline void enter_go_off_one_mode(void)\r
+{\r
+       internal_data.current_state = ECUM_STATE_GO_OFF_ONE;\r
+       EcuM_OnGoOffOne();\r
+\r
+#if defined(USE_COMM)\r
+       ComM_DeInit();\r
+#endif\r
+\r
+#if    (ECUM_INCLUDE_NVRAM_MGR == STD_ON)\r
+\r
+       // Start NvM_WriteAll and timeout timer\r
+       NvM_WriteAll();\r
+\r
+       internal_data_go_off_one_state_timeout = internal_data.config->EcuMNvramWriteAllTimeout / ECUM_MAIN_FUNCTION_PERIOD;\r
+#endif\r
+}\r
+\r
+static inline boolean hasRunRequests(void)\r
+{\r
+       boolean result = internal_data.run_requests;\r
+\r
+#if defined(USE_COMM)\r
+       result |= internal_data.run_comm_requests;\r
+#endif\r
+\r
+       return (result != 0);\r
+}\r
+\r
+static inline boolean hasPostRunRequests(void)\r
+{\r
+       return (internal_data.postrun_requests != 0);\r
+}\r
 \r
 void EcuM_MainFunction(void)\r
 {\r
-#if (ECUM_DEV_ERROR_DETECT == STD_ON)\r
-       if (!internal_data->initiated)\r
-       {\r
-               Det_ReportError(MODULE_ID_ECUM, 1, ECUM_MAINFUNCTION_ID, ECUM_E_NOT_INITIATED);\r
-               return;\r
-       }\r
+#if    (ECUM_INCLUDE_NVRAM_MGR == STD_ON)\r
+static NvM_RequestResultType writeAllResult;\r
 #endif\r
 \r
+VALIDATE_NO_RV(internal_data.initiated, ECUM_MAINFUNCTION_ID, ECUM_E_NOT_INITIATED);\r
+\r
        // If coming from startup sequence, enter Run mode\r
-       if (internal_data->current_state == ECUM_STATE_STARTUP_TWO)\r
+       if (internal_data.current_state == ECUM_STATE_STARTUP_TWO)\r
                enter_run_mode();\r
 \r
-       if (internal_data->current_state == ECUM_STATE_APP_RUN)\r
+       if (internal_data.current_state == ECUM_STATE_APP_RUN)\r
        {\r
+               if (internal_data_run_state_timeout)\r
+                       internal_data_run_state_timeout--;\r
+\r
                if (!hasRunRequests() && (internal_data_run_state_timeout == 0))\r
                {\r
+                       EcuM_OnExitRun();       // ECUM_2865\r
                        enter_post_run_mode();\r
                        return;\r
                }\r
        }\r
 \r
-       if (internal_data->current_state == ECUM_STATE_APP_POST_RUN)\r
+       if (internal_data.current_state == ECUM_STATE_APP_POST_RUN)\r
        {\r
                if (hasRunRequests())\r
                {\r
@@ -61,4 +135,44 @@ void EcuM_MainFunction(void)
                        return;\r
                }\r
        }\r
+\r
+       if (internal_data.current_state == ECUM_STATE_PREP_SHUTDOWN)\r
+       {\r
+#if defined(USE_DEM)\r
+               // DEM shutdown\r
+               Dem_Shutdown();\r
+#endif\r
+\r
+               // Switch shutdown mode\r
+               if ((internal_data.shutdown_target == ECUM_STATE_OFF) || (internal_data.shutdown_target == ECUM_STATE_RESET)) {\r
+                       enter_go_off_one_mode();\r
+               }\r
+\r
+               if (internal_data.shutdown_target == ECUM_STATE_SLEEP) {\r
+                       enter_go_sleep_mode();\r
+               }\r
+       }\r
+\r
+       if (internal_data.current_state == ECUM_STATE_GO_OFF_ONE)\r
+       {\r
+#if    (ECUM_INCLUDE_NVRAM_MGR == STD_ON)\r
+               if (internal_data_go_off_one_state_timeout)\r
+                       internal_data_go_off_one_state_timeout--;\r
+\r
+               // Wait for the NVM job (NvmWriteAll) to terminate\r
+               NvM_GetErrorStatus(0, &writeAllResult);\r
+               if ((writeAllResult != NVM_REQ_PENDING) || (internal_data_go_off_one_state_timeout == 0))\r
+               {\r
+                       ShutdownOS(E_OK);\r
+               }\r
+#else\r
+               ShutdownOS(E_OK);\r
+#endif\r
+       }\r
+\r
+       if (internal_data.current_state == ECUM_STATE_GO_SLEEP)\r
+       {\r
+               // TODO: Fill out\r
+       }\r
+\r
 }\r
diff --git a/system/EcuM/EcuM_PBcfg.h b/system/EcuM/EcuM_PBcfg.h
deleted file mode 100644 (file)
index 7bbef8d..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-/* -------------------------------- Arctic Core ------------------------------\r
- * Arctic Core - the open source AUTOSAR platform http://arccore.com\r
- *\r
- * Copyright (C) 2009  ArcCore AB <contact@arccore.com>\r
- *\r
- * This source code is free software; you can redistribute it and/or modify it\r
- * under the terms of the GNU General Public License version 2 as published by the\r
- * Free Software Foundation; See <http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt>.\r
- *\r
- * This program is distributed in the hope that it will be useful, but\r
- * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY\r
- * or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License\r
- * for more details.\r
- * -------------------------------- Arctic Core ------------------------------*/\r
-\r
-\r
-\r
-\r
-\r
-\r
-\r
-\r
-\r
-/* Post Build time configuration */\r
-\r
-unsigned char ECUM_DEFAULT_APP_MODE = 0;       \r
-unsigned char ECUM_DEFAULT_SHUTDOWN_TARGET = 0;\r
-unsigned char ECUM_RUN_SELF_REQUEST_PERIOD = 0;\r