Introducing a FSFWConfig.h file #203

Closed
opened 2020-09-21 20:23:22 +02:00 by muellerr · 0 comments
Owner

This file could be used by framework users to specify or manipulate preprocessor define or to tweak configurable settings.

Example:

#ifndef CONFIG_FSFWCONFIG_H_
#define CONFIG_FSFWCONFIG_H_

#include "version.h"

//! Used to determine whether C++ ostreams are used
//! Those can lead to code bloat.
#define FSFW_CPP_OSTREAM_ENABLED 	1

//! Reduced printout to further decrese code size
//! Be careful, this also turns off most diagnostic prinouts!
#define FSFW_REDUCED_PRINTOUT		0

//! If -DDEBUG is supplied in the build defines, there will be
//! additional output which requires the translation files translateObjects
//! and translateEvents (and their compiles source files)
#ifdef DEBUG
#define FSFW_DEBUG_OUTPUT 			1
//! Specify whether info events are printed too.
#define FSFW_DEBUG_INFO				1
#include <translateObjects.h>
#include <translateEvents.h>
#else
#define FSFW_DEBUG_OUTPUT			0
#endif

//! When using the newlib nano library, C99 support for stdio facilities
//! will not be provided. This define should be set to 1 if this is the case.
#define FSFW_NEWLIB_NANO_NO_C99_IO 	1


#endif /* CONFIG_FSFWCONFIG_H_ */

This could also be used to exclude specific folders of the FSFW which are not used from compilation to reduce compilation times, and have all these types of configuration parameters in one place. This file could also be used to include the systemObjectList.h and the the classIds.h header files.

This file could be used by framework users to specify or manipulate preprocessor define or to tweak configurable settings. Example: ```cpp #ifndef CONFIG_FSFWCONFIG_H_ #define CONFIG_FSFWCONFIG_H_ #include "version.h" //! Used to determine whether C++ ostreams are used //! Those can lead to code bloat. #define FSFW_CPP_OSTREAM_ENABLED 1 //! Reduced printout to further decrese code size //! Be careful, this also turns off most diagnostic prinouts! #define FSFW_REDUCED_PRINTOUT 0 //! If -DDEBUG is supplied in the build defines, there will be //! additional output which requires the translation files translateObjects //! and translateEvents (and their compiles source files) #ifdef DEBUG #define FSFW_DEBUG_OUTPUT 1 //! Specify whether info events are printed too. #define FSFW_DEBUG_INFO 1 #include <translateObjects.h> #include <translateEvents.h> #else #define FSFW_DEBUG_OUTPUT 0 #endif //! When using the newlib nano library, C99 support for stdio facilities //! will not be provided. This define should be set to 1 if this is the case. #define FSFW_NEWLIB_NANO_NO_C99_IO 1 #endif /* CONFIG_FSFWCONFIG_H_ */ ``` This could also be used to exclude specific folders of the FSFW which are not used from compilation to reduce compilation times, and have all these types of configuration parameters in one place. This file could also be used to include the systemObjectList.h and the the classIds.h header files.
muellerr added the
feature
label 2020-09-21 20:23:22 +02:00
Sign in to join this conversation.
No Milestone
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: fsfw/fsfw#203
No description provided.