# HG changeset patch # User Jeandet Alexis # Date 2017-01-02 22:53:23 # Node ID 04c5ed6433df54ffb6e609a204903e18651cb495 # Parent 606a2093de441a5cfc6ee1929da73624f501f7fa added prefix to FSW and timegen options diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -27,51 +27,56 @@ set(SOURCES wf_handler.c ) -option(verbose "Enable verbose LFR" ON) -option(boot_messages "Enable LFR boot messages" ON) -option(debug_messages "Enable LFR debug messages" ON) -option(cpu_usage_report "Enable LFR cpu usage report" OFF) -option(stack_report "Enable LFR stack report" OFF) -option(vhdl_dev "?" OFF) -option(lpp_dpu_destid "Set to debug at LPP" ON) -option(debug_watchdog "Enable debug watchdog" OFF) -option(debug_tch "?" OFF) +option(FSW_verbose "Enable verbose LFR" ON) +option(FSW_boot_messages "Enable LFR boot messages" ON) +option(FSW_debug_messages "Enable LFR debug messages" ON) +option(FSW_cpu_usage_report "Enable LFR cpu usage report" OFF) +option(FSW_stack_report "Enable LFR stack report" OFF) +option(FSW_vhdl_dev "?" OFF) +option(FSW_lpp_dpu_destid "Set to debug at LPP" ON) +option(FSW_debug_watchdog "Enable debug watchdog" OFF) +option(FSW_debug_tch "?" OFF) + +set(SW_VERSION_N1 "3" CACHE STRING "Choose N1 FSW Version." FORCE) +set(SW_VERSION_N2 "1" CACHE STRING "Choose N2 FSW Version." FORCE) +set(SW_VERSION_N3 "0" CACHE STRING "Choose N3 FSW Version." FORCE) +set(SW_VERSION_N4 "4" CACHE STRING "Choose N4 FSW Version." FORCE) -if (verbose) +if(FSW_verbose) add_definitions(-DPRINT_MESSAGES_ON_CONSOLE) endif() -if (boot_messages) +if(FSW_boot_messages) add_definitions(-DBOOT_MESSAGES) endif() -if (debug_messages) +if(FSW_debug_messages) add_definitions(-DDEBUG_MESSAGES) endif() -if (cpu_usage_report) +if(FSW_cpu_usage_report) add_definitions(-DPRINT_TASK_STATISTICS) endif() -if (stack_report) +if(FSW_stack_report) add_definitions(-DPRINT_STACK_REPORT) endif() -if (vhdl_dev) +if(FSW_vhdl_dev) add_definitions(-DVHDL_DEV) endif() -if (lpp_dpu_destid) +if(FSW_lpp_dpu_destid) add_definitions(-DLPP_DPU_DESTID) endif() -if (debug_watchdog) +if(FSW_debug_watchdog) add_definitions(-DDEBUG_WATCHDOG) endif() -if (debug_tch) +if(FSW_debug_tch) add_definitions(-DDEBUG_TCH) endif() add_definitions(-DMSB_FIRST_TCH) add_definitions(-DSWVERSION=-1-0) -add_definitions(-DSW_VERSION_N1=3) -add_definitions(-DSW_VERSION_N2=1) -add_definitions(-DSW_VERSION_N3=0) -add_definitions(-DSW_VERSION_N4=4) +add_definitions(-DSW_VERSION_N1=${SW_VERSION_N1}) +add_definitions(-DSW_VERSION_N2=${SW_VERSION_N2}) +add_definitions(-DSW_VERSION_N3=${SW_VERSION_N3}) +add_definitions(-DSW_VERSION_N4=${SW_VERSION_N4}) add_executable(FSW ${SOURCES}) diff --git a/timegen/CMakeLists.txt b/timegen/CMakeLists.txt --- a/timegen/CMakeLists.txt +++ b/timegen/CMakeLists.txt @@ -17,51 +17,56 @@ set(SOURCES src/tc_handler.c ../LFR_basic-parameters/basic_parameters.c) -option(verbose "Enable verbose LFR" ON) -option(boot_messages "Enable LFR boot messages" ON) -option(debug_messages "Enable LFR debug messages" ON) -option(cpu_usage_report "Enable LFR cpu usage report" OFF) -option(stack_report "Enable LFR stack report" OFF) -option(vhdl_dev "?" OFF) -option(lpp_dpu_destid "Set to debug at LPP" ON) -option(debug_watchdog "Enable debug watchdog" OFF) -option(debug_tch "?" OFF) +option(timegen_verbose "Enable verbose Timegen" ON) +option(timegen_boot_messages "Enable Timegen boot messages" ON) +option(timegen_debug_messages "Enable Timegen debug messages" ON) +option(timegen_cpu_usage_report "Enable Timegen cpu usage report" OFF) +option(timegen_stack_report "Enable Timegen stack report" OFF) +option(timegen_vhdl_dev "?" OFF) +option(timegen_lpp_dpu_destid "Set to debug at LPP" ON) +option(timegen_debug_watchdog "Enable debug watchdog" OFF) +option(timegen_debug_tch "?" OFF) + +set(TIMEGEN_SW_VERSION_N1 "3" CACHE STRING "Choose N1 FSW Version." FORCE) +set(TIMEGEN_SW_VERSION_N2 "1" CACHE STRING "Choose N2 FSW Version." FORCE) +set(TIMEGEN_SW_VERSION_N3 "0" CACHE STRING "Choose N3 FSW Version." FORCE) +set(TIMEGEN_SW_VERSION_N4 "4" CACHE STRING "Choose N4 FSW Version." FORCE) -if (verbose) +if (timegen_verbose) add_definitions(-DPRINT_MESSAGES_ON_CONSOLE) endif() -if (boot_messages) +if (timegen_boot_messages) add_definitions(-DBOOT_MESSAGES) endif() -if (debug_messages) +if (timegen_debug_messages) add_definitions(-DDEBUG_MESSAGES) endif() -if (cpu_usage_report) +if (timegen_cpu_usage_report) add_definitions(-DPRINT_TASK_STATISTICS) endif() -if (stack_report) +if (timegen_stack_report) add_definitions(-DPRINT_STACK_REPORT) endif() -if (vhdl_dev) +if (timegen_vhdl_dev) add_definitions(-DVHDL_DEV) endif() -if (lpp_dpu_destid) +if (timegen_lpp_dpu_destid) add_definitions(-DLPP_DPU_DESTID) endif() -if (debug_watchdog) +if (timegen_debug_watchdog) add_definitions(-DDEBUG_WATCHDOG) endif() -if (debug_tch) +if (timegen_debug_tch) add_definitions(-DDEBUG_TCH) endif() add_definitions(-DMSB_FIRST_TCH) add_definitions(-DSWVERSION=-1-0) -add_definitions(-DSW_VERSION_N1=3) -add_definitions(-DSW_VERSION_N2=1) -add_definitions(-DSW_VERSION_N3=0) -add_definitions(-DSW_VERSION_N4=4) +add_definitions(-DSW_VERSION_N1=${TIMEGEN_SW_VERSION_N1}) +add_definitions(-DSW_VERSION_N2=${TIMEGEN_SW_VERSION_N2}) +add_definitions(-DSW_VERSION_N3=${TIMEGEN_SW_VERSION_N3}) +add_definitions(-DSW_VERSION_N4=${TIMEGEN_SW_VERSION_N4}) add_executable(timegen ${SOURCES})