commit f3ac1c962f9e3d7ff7d55141220df97c2b343ada
Author: Thomas Schöpping <tschoepp@cit-ec.uni-bielefeld.de>
Date:   Mon Feb 4 18:08:00 2019 +0100

    Applied a file structure template to all source files.

diff --git a/core/inc/aos_confcheck.h b/core/inc/aos_confcheck.h
index 49d89bb..b2da583 100644
--- a/core/inc/aos_confcheck.h
+++ b/core/inc/aos_confcheck.h
@@ -29,9 +29,19 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <aosconf.h>
 
-/*
- * Kernel parameters and options
- */
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/* kernel parameters and options */
 
 #ifndef AMIROOS_CFG_DBG
   #error "AMIROOS_CFG_DBG not defined in aosconf.h"
@@ -49,9 +59,7 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
   #error "AMIROOS_CFG_MAIN_LOOP_TIMEOUT not defined in aosconf.h"
 #endif
 
-/*
- * SSSP parameters and options
- */
+/* SSSP parameters and options */
 
 #ifndef AMIROOS_CFG_SSSP_ENABLE
   #error "AMIROOS_CFG_SSSP_ENABLE not defined in aosconf.h"
@@ -88,9 +96,7 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #endif
 
-/*
- * System shell options
- */
+/* system shell options */
 
 #ifndef AMIROOS_CFG_SHELL_ENABLE
   #error "AMIROOS_CFG_SHELL_ENABLE not defined in aosconf.h"
@@ -122,6 +128,22 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #endif /* AMIROOS_CFG_SHELL_ENABLE */
 
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* AMIROOS_CONFCHECK_H */
 
 /** @} */
diff --git a/core/inc/aos_debug.h b/core/inc/aos_debug.h
index 9f0836a..c3d0751 100644
--- a/core/inc/aos_debug.h
+++ b/core/inc/aos_debug.h
@@ -30,10 +30,36 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #include <aosconf.h>
 #include <hal.h>
 #include <chprintf.h>
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
 
 #if (AMIROOS_CFG_DBG == true) || defined(__DOXYGEN__)
 
 /**
+ * @brief   Printf function for messages only printed in debug builds.
+ *
+ * @param[in] fmt   Formatted string to print.
+ */
+#define aosDbgPrintf(fmt, ...)        aosprintf(fmt, ##__VA_ARGS__)
+
+/**
  * @brief   Function parameters check.
  * @details If the condition check fails, the kernel panics and halts.
  *
@@ -63,15 +89,12 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
   chDbgAssert(c, r);                                      \
 }
 
-/**
- * @brief   Printf function for messages only printed in debug builds.
- *
- * @param[in] fmt   Formatted string to print.
- */
-#define aosDbgPrintf(fmt, ...)        chprintf((BaseSequentialStream*)&aos.iostream, fmt, ##__VA_ARGS__)
-
 #else /* (AMIROOS_CFG_DBG != true) */
 
+#define aosDbgPrintf(fmt, ...) {                          \
+  (void)(fmt);                                            \
+}
+
 #define aosDbgCheck(c) {                                  \
   (void)(c);                                              \
   }
@@ -85,11 +108,15 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
   (void)(r);                                              \
 }
 
-#define aosDbgPrintf(fmt, ...) {                          \
-  (void)(fmt);                                            \
-}
+#endif /* AMIROOS_CFG_DBG */
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
 
-#endif
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
 
 #endif /* AMIROOS_DEBUG_H */
 
diff --git a/core/inc/aos_iostream.h b/core/inc/aos_iostream.h
index e688db8..4bd6bc8 100644
--- a/core/inc/aos_iostream.h
+++ b/core/inc/aos_iostream.h
@@ -32,30 +32,41 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #include <stdarg.h>
 
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
 
 /**
  * @brief   Channel flag to indicate whether the channel is attached to a stream.
  */
-#define AOS_IOCHANNEL_ATTACHED                  (1 << 0)
+#define AOS_IOCHANNEL_ATTACHED                  ((aos_iochannelflag_t)(1 << 0))
 
 /**
  * @brief   Channel flag to indicate whether the channel is set as input.
  */
-#define AOS_IOCHANNEL_INPUT_ENABLE              (1 << 1)
+#define AOS_IOCHANNEL_INPUT_ENABLE              ((aos_iochannelflag_t)(1 << 1))
 
 /**
  * @brief   Channel flag to indicate whether the channel is set as output.
  */
-#define AOS_IOCHANNEL_OUTPUT_ENABLE             (1 << 2)
+#define AOS_IOCHANNEL_OUTPUT_ENABLE             ((aos_iochannelflag_t)(1 << 2))
 
-/*
- * forward definitions
- */
-typedef struct aos_iochannel AosIOChannel;
-typedef struct aos_ostream AosIOStream;
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
+typedef uint8_t aos_iochannelflag_t;
 
 /**
- * @brief   AosI=Channel specific methods.
+ * @brief   AosIOChannel specific methods.
  */
 #define _aos_iochannel_methods                                              \
   _base_asynchronous_channel_methods
@@ -67,9 +78,9 @@ typedef struct aos_ostream AosIOStream;
   /* pointer to a BaseAsynchronousChannel object */                         \
   BaseAsynchronousChannel* asyncchannel;                                    \
   /* pointer to the next channel in a AosIOStream */                        \
-  AosIOChannel* next;                                                       \
+  struct aos_iochannel* next;                                               \
   /* flags related to the channel */                                        \
-  uint8_t flags;
+  aos_iochannelflag_t flags;
 
 /**
  * @extends BaseAsynchronousChannelVMT
@@ -86,11 +97,11 @@ struct AosIOChannelVMT {
  * @brief   I/O Channel class.
  * @details This class implements an asynchronous I/O channel.
  */
-struct aos_iochannel {
+typedef struct aos_iochannel {
   /** @brief Virtual Methods Table. */
   const struct AosIOChannelVMT* vmt;
   _aos_iochannel_data
-};
+} AosIOChannel;
 
 /**
  * @brief   AosIOStream methods.
@@ -121,10 +132,18 @@ struct AosIOStreamVMT {
  * @details This class implements an base sequential stream.
  * @todo    So far only output but no input is supported.
  */
-struct aos_ostream {
+typedef struct aos_ostream {
   const struct AosIOStreamVMT* vmt;
   _aos_iostream_data
-};
+} AosIOStream;
+
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
 
 #ifdef __cplusplus
 extern "C" {
@@ -141,6 +160,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* AMIROOS_IOSTREAM_H */
 
 /** @} */
diff --git a/core/inc/aos_shell.h b/core/inc/aos_shell.h
index 6ba2f29..292870c 100644
--- a/core/inc/aos_shell.h
+++ b/core/inc/aos_shell.h
@@ -32,6 +32,9 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #include <hal.h>
 #include <aos_types.h>
 #include <aos_debug.h>
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
 
 /**
  * @brief   Shell event flag that is emitted when the thread starts.
@@ -98,11 +101,17 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
  */
 #define AOS_SHELLCHANNEL_OUTPUT_ENABLED           (1 << 2)
 
-/*
- * forward definitions
- */
-typedef struct aos_shellchannel AosShellChannel;
-typedef struct aos_shellstream AosShellStream;
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
 
 /**
  * @brief   AosShellChannel specific methods.
@@ -119,7 +128,7 @@ typedef struct aos_shellstream AosShellStream;
   /* event listener for the associated BaseAsynchronousChannel */           \
   event_listener_t listener;                                                \
   /* pointer to the next chennal in a AosShellStream */                     \
-  AosShellChannel* next;                                                    \
+  struct aos_shellchannel* next;                                            \
   /* flags related to the channel */                                        \
   uint8_t flags;
 
@@ -138,11 +147,11 @@ struct AosShellChannelVMT {
  * @brief   Shell channel class.
  * @details This class implements an asynchronous I/O channel.
  */
-struct aos_shellchannel {
+typedef struct aos_shellchannel {
   /** @brief Virtual Methods Table. */
   const struct AosShellChannelVMT* vmt;
   _aos_shell_channel_data
-};
+} AosShellChannel;
 
 /**
  * @brief   AosShellStream methods.
@@ -173,10 +182,10 @@ struct AosShellStreamVMT {
  * @details This class implements an base sequential stream.
  * @todo    So far only output but no input is supported.
  */
-struct aos_shellstream {
+typedef struct aos_shellstream {
   const struct AosShellStreamVMT* vmt;
   _aos_shellstream_data
-};
+} AosShellStream;
 
 /**
  * @brief   Shell command calback type.
@@ -351,6 +360,14 @@ typedef struct aos_shell {
   uint8_t config;
 } aos_shell_t;
 
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -371,6 +388,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* (AMIROOS_CFG_SHELL_ENABLE == true) || (AMIROOS_CFG_TESTS_ENABLE == true) */
 
 #endif /* AMIROOS_SHELL_H */
diff --git a/core/inc/aos_system.h b/core/inc/aos_system.h
index c571c03..b958c2a 100644
--- a/core/inc/aos_system.h
+++ b/core/inc/aos_system.h
@@ -34,6 +34,10 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #include <aos_time.h>
 #include <chprintf.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
 /**
  * @brief   Resolution of the system time measurement.
  */
@@ -64,18 +68,6 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
  */
 #define AOS_SYSTEM_EVENTFLAGS_RESTART           (AOS_SYSTEM_EVENTFLAGS_SHUTDOWN | (eventflags_t)(1 << 4))
 
-/**
- * @brief   Enumerator to identify shutdown types.
- */
-typedef enum aos_shutdown {
-  AOS_SHUTDOWN_NONE,            /**< Default value if no shutdown action was initiated */
-  AOS_SHUTDOWN_PASSIVE,         /**< Passive shutdown (initiated by another module). */
-  AOS_SHUTDOWN_HIBERNATE,       /**< Active shutdown to hibernate mode. */
-  AOS_SHUTDOWN_DEEPSLEEP,       /**< Active shutdown to deepsleep mode. */
-  AOS_SHUTDOWN_TRANSPORTATION,  /**< Active shutdown to transportation mode. */
-  AOS_SHUTDOWN_RESTART,         /**< Active saystem restart request. */
-} aos_shutdown_t;
-
 #if (AMIROOS_CFG_SSSP_ENABLE == true) || defined(__DOXYGEN__)
 
 /**
@@ -94,6 +86,34 @@ typedef enum aos_shutdown {
  */
 #define AOS_SYSTEM_SSSP_TIMEOUT                 (10 * AMIROOS_CFG_SSSP_SIGNALDELAY)
 
+#endif /* AMIROOS_CFG_SSSP_ENABLE == true */
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
+/**
+ * @brief   Enumerator to identify shutdown types.
+ */
+typedef enum aos_shutdown {
+  AOS_SHUTDOWN_NONE,            /**< Default value if no shutdown action was initiated */
+  AOS_SHUTDOWN_PASSIVE,         /**< Passive shutdown (initiated by another module). */
+  AOS_SHUTDOWN_HIBERNATE,       /**< Active shutdown to hibernate mode. */
+  AOS_SHUTDOWN_DEEPSLEEP,       /**< Active shutdown to deepsleep mode. */
+  AOS_SHUTDOWN_TRANSPORTATION,  /**< Active shutdown to transportation mode. */
+  AOS_SHUTDOWN_RESTART,         /**< Active saystem restart request. */
+} aos_shutdown_t;
+
+#if (AMIROOS_CFG_SSSP_ENABLE == true) || defined(__DOXYGEN__)
+
 /**
  * @brief   Enumerator of the several stages of SSSP.
  */
@@ -176,10 +196,9 @@ typedef struct aos_system {
 
 } aos_system_t;
 
-/**
- * @brief   Global system object.
- */
-extern aos_system_t aos;
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
 
 /**
  * @brief   Printf function that uses the default system I/O stream.
@@ -188,6 +207,15 @@ extern aos_system_t aos;
  */
 #define aosprintf(fmt, ...)                     chprintf((BaseSequentialStream*)&aos.iostream, fmt, ##__VA_ARGS__)
 
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
+/**
+ * @brief   Global system object.
+ */
+extern aos_system_t aos;
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -211,6 +239,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 /**
  * @brief   Retrieves the system uptime.
  *
diff --git a/core/inc/aos_thread.h b/core/inc/aos_thread.h
index ff1f651..8047808 100644
--- a/core/inc/aos_thread.h
+++ b/core/inc/aos_thread.h
@@ -29,6 +29,9 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <aos_time.h>
 #include <aos_system.h>
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
 
 /**
  * @brief   Minimum thread priority.
@@ -95,6 +98,26 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
  */
 #define AOS_THD_MAX_SLEEP_US          (chTimeI2US(AOS_THD_MAX_SLEEP_ST) - 1)
 
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -106,6 +129,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 /**
  * @brief   Lets the calling thread sleep the specified amount of microseconds.
  *
diff --git a/core/inc/aos_time.h b/core/inc/aos_time.h
index f5493ac..642285d 100644
--- a/core/inc/aos_time.h
+++ b/core/inc/aos_time.h
@@ -29,23 +29,9 @@ along with this program.  If not, see <http://www.gnu.org/licenses/.
 
 #include <stdint.h>
 
-/**
- * @brief   Generic time to represent long time frames at high precision.
- * @note    By definition the temporal resolution is 1us.
- */
-typedef uint64_t aos_timestamp_t;
-
-/**
- * @brief   generic time to represent medium length time frames at high precision.
- * @note    By definition the temporal resolution is 1us.
- */
-typedef uint32_t aos_interval_t;
-
-/**
- * @brief   Generic time to represent long time frames at high precision.
- * @note    By definition the temporal resolution is 1us.
- */
-typedef aos_timestamp_t aos_longinterval_t;
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
 
 #define MICROSECONDS_PER_MICROSECOND  ((uint8_t)  (1))
 #define MILLISECONDS_PER_MILLISECOND  ((uint8_t)  (1))
@@ -212,6 +198,44 @@ typedef aos_timestamp_t aos_longinterval_t;
 #define MILLENIUMS_PER_DECADE         ((float)MILLENIUMS_PER_MILLENIUM / (float)DECADES_PER_MILLENIUM)
 #define MILLENIUMS_PER_CENTURY        ((float)MILLENIUMS_PER_MILLENIUM / (float)CENTURIES_PER_MILLENIUM)
 
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
+/**
+ * @brief   Generic time to represent long time frames at high precision.
+ * @note    By definition the temporal resolution is 1us.
+ */
+typedef uint64_t aos_timestamp_t;
+
+/**
+ * @brief   generic time to represent medium length time frames at high precision.
+ * @note    By definition the temporal resolution is 1us.
+ */
+typedef uint32_t aos_interval_t;
+
+/**
+ * @brief   Generic time to represent long time frames at high precision.
+ * @note    By definition the temporal resolution is 1us.
+ */
+typedef aos_timestamp_t aos_longinterval_t;
+
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -220,6 +244,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* AMIROOS_TIME_H */
 
 /** @} */
diff --git a/core/inc/aos_timer.h b/core/inc/aos_timer.h
index c9d19d3..a0cb2fe 100644
--- a/core/inc/aos_timer.h
+++ b/core/inc/aos_timer.h
@@ -29,6 +29,9 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <ch.h>
 #include <aos_time.h>
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
 
 /**
  * @brief   Maximum timer interval that can be set in system ticks.
@@ -50,6 +53,18 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
  */
 #define AOS_TIMER_MAX_INTERVAL_US     (chTimeI2US(AOS_TIMER_MAX_INTERVAL_ST) - 1)
 
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
 /**
  * @brief   Timer stucture.
  */
@@ -100,6 +115,14 @@ typedef struct aos_periodictimer {
   void* cbparam;
 } aos_periodictimer_t;
 
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -114,6 +137,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 /**
  * @brief   Set timer to fire at an absolute system time.
  *
diff --git a/core/inc/aos_types.h b/core/inc/aos_types.h
index dec5678..9d9d906 100644
--- a/core/inc/aos_types.h
+++ b/core/inc/aos_types.h
@@ -29,10 +29,21 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <ch.h>
 
-/**
- * @brief   Converts a GPIO pad number to a unique event flag.
- */
-#define AOS_IOEVENT_FLAG(pad)                   ((eventflags_t)1 << pad)
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
 
 /**
  * @brief   Error codes used in AMiRo-OS.
@@ -47,5 +58,23 @@ typedef enum {
 } aos_status_t;
 
 
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/**
+ * @brief   Converts a GPIO pad number to a unique event flag.
+ */
+#define AOS_IOEVENT_FLAG(pad)                   ((eventflags_t)1 << pad)
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* AMIROOS_TYPES_H */
+
 /** @} */
diff --git a/core/inc/aos_unittest.h b/core/inc/aos_unittest.h
index a149f29..b1b5617 100644
--- a/core/inc/aos_unittest.h
+++ b/core/inc/aos_unittest.h
@@ -31,12 +31,27 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #if (AMIROOS_CFG_TESTS_ENABLE == true) || defined(__DOXYGEN__)
 #include <hal.h>
 #include <aos_shell.h>
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
 
 /*
- * Forward declarations.
+ * forward declarations
  */
-typedef struct aos_unittest aos_unittest_t;
 typedef struct aos_utresult aos_utresult_t;
+typedef struct aos_unittest aos_unittest_t;
 
 /**
  * @brief   Unit test interface function definition.
@@ -46,7 +61,7 @@ typedef struct aos_utresult aos_utresult_t;
  *
  * @return    A result containing the number of passed and failed tests.
  */
-typedef aos_utresult_t (*aos_utfunction_t)(BaseSequentialStream* stream, aos_unittest_t* ut);
+typedef aos_utresult_t (*aos_utfunction_t)(BaseSequentialStream*, aos_unittest_t*);
 
 /**
  * @brief   Unit test result struct.
@@ -93,6 +108,15 @@ struct aos_unittest {
   void* data;
 };
 
+
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -110,6 +134,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* AMIROOS_CFG_TESTS_ENABLE == true */
 
 #endif /* AMIROOS_UNITTEST_H */
diff --git a/core/src/aos_iostream.c b/core/src/aos_iostream.c
index 75df0a1..318cb6b 100644
--- a/core/src/aos_iostream.c
+++ b/core/src/aos_iostream.c
@@ -27,8 +27,69 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <aos_iostream.h>
 
-#include <aos_debug.h>
-#include <chprintf.h>
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/*
+ * forward declarations
+ */
+static size_t _channelwrite(void *instance, const uint8_t *bp, size_t n);
+static size_t _channelread(void *instance, uint8_t *bp, size_t n);
+static msg_t _channelput(void *instance, uint8_t b);
+static msg_t _channelget(void *instance);
+static msg_t _channelputt(void *instance, uint8_t b, sysinterval_t time);
+static msg_t _channelgett(void *instance, sysinterval_t time);
+static size_t _channelwritet(void *instance, const uint8_t *bp, size_t n, sysinterval_t time);
+static size_t _channelreadt(void *instance, uint8_t *bp, size_t n, sysinterval_t time);
+static msg_t _channelctl(void *instance, unsigned int operation, void *arg);
+static size_t _streamwrite(void *instance, const uint8_t *bp, size_t n);
+static size_t _stremread(void *instance, uint8_t *bp, size_t n);
+static msg_t _streamput(void *instance, uint8_t b);
+static msg_t _streamget(void *instance);
+
+/**
+ * @brief   Virtual methods table for all AosIOChannel objects.
+ */
+static const struct AosIOChannelVMT _channelvmt = {
+  (size_t) 0,
+  _channelwrite,
+  _channelread,
+  _channelput,
+  _channelget,
+  _channelputt,
+  _channelgett,
+  _channelwritet,
+  _channelreadt,
+  _channelctl,
+};
+
+/**
+ * @brief   Virtual methods table for all AosIOStream objects.
+ */
+static const struct AosIOStreamVMT _streamvmt = {
+  (size_t) 0,
+  _streamwrite,
+  _stremread,
+  _streamput,
+  _streamget,
+};
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
 
 /**
  * @brief   Implementation of the BaseAsynchronousChannel write() method (inherited from BaseSequentialStream).
@@ -139,22 +200,6 @@ static msg_t _channelctl(void *instance, unsigned int operation, void *arg)
 }
 
 /**
- * @brief   Virtual methods table for all AosIOChannel objects.
- */
-static const struct AosIOChannelVMT _channelvmt = {
-  (size_t) 0,
-  _channelwrite,
-  _channelread,
-  _channelput,
-  _channelget,
-  _channelputt,
-  _channelgett,
-  _channelwritet,
-  _channelreadt,
-  _channelctl,
-};
-
-/**
  * @brief   Implementation of the BaseSequentialStream write() method.
  */
 static size_t _streamwrite(void *instance, const uint8_t *bp, size_t n)
@@ -219,16 +264,9 @@ static msg_t _streamget(void *instance)
   return 0;
 }
 
-/**
- * @brief   Virtual methods table for all AosIOStream objects.
- */
-static const struct AosIOStreamVMT _streamvmt = {
-  (size_t) 0,
-  _streamwrite,
-  _stremread,
-  _streamput,
-  _streamget,
-};
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
 
 /**
  * @brief   Initializes an aos_iostream_t object.
diff --git a/core/src/aos_main.cpp b/core/src/aos_main.cpp
index dda45e1..baa3d5d 100644
--- a/core/src/aos_main.cpp
+++ b/core/src/aos_main.cpp
@@ -36,6 +36,10 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #include AMIROOS_CFG_MAIN_EXTRA_INCLUDE_HEADER
 #endif
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
 /**
  * @brief   Event mask to identify I/O events.
  */
@@ -92,6 +96,18 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
  */
 #define CALENDERSYNC_CANMSGID                   0x004
 
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
 /**
  * @brief   Listener object for I/O events.
  */
@@ -123,6 +139,10 @@ static AosShellChannel _stdshellchannel;
 AMIROOS_CFG_MAIN_EXTRA_STATIC_VARIABLES
 #endif
 
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
 /**
  * @brief   Prints an error message about an unexpected event.
  *
@@ -1334,4 +1354,8 @@ int main(void)
   return -1;
 }
 
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
+
 /** @} */
diff --git a/core/src/aos_shell.c b/core/src/aos_shell.c
index 25b1a1f..fbbfa6b 100644
--- a/core/src/aos_shell.c
+++ b/core/src/aos_shell.c
@@ -32,6 +32,9 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #include <aos_time.h>
 #include <aos_system.h>
 #include <string.h>
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
 
 /**
  * @brief   Event mask to be set on OS related events.
@@ -43,6 +46,90 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
  */
 #define AOS_SHELL_EVENTMASK_INPUT               EVENT_MASK(1)
 
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/*
+ * forward declarations
+ */
+static size_t _channelwrite(void *instance, const uint8_t *bp, size_t n);
+static size_t _channelread(void *instance, uint8_t *bp, size_t n);
+static msg_t _channelput(void *instance, uint8_t b);
+static msg_t _channelget(void *instance);
+static msg_t _channelputt(void *instance, uint8_t b, sysinterval_t time);
+static msg_t _channelgett(void *instance, sysinterval_t time);
+static size_t _channelwritet(void *instance, const uint8_t *bp, size_t n, sysinterval_t time);
+static size_t _channelreadt(void *instance, uint8_t *bp, size_t n, sysinterval_t time);
+static msg_t _channelctl(void *instance, unsigned int operation, void *arg);
+static size_t _streamwrite(void *instance, const uint8_t *bp, size_t n);
+static size_t _stremread(void *instance, uint8_t *bp, size_t n);
+static msg_t _streamput(void *instance, uint8_t b);
+static msg_t _streamget(void *instance);
+
+static const struct AosShellChannelVMT _channelvmt = {
+  (size_t) 0,
+  _channelwrite,
+  _channelread,
+  _channelput,
+  _channelget,
+  _channelputt,
+  _channelgett,
+  _channelwritet,
+  _channelreadt,
+  _channelctl,
+};
+
+static const struct AosShellStreamVMT _streamvmt = {
+  (size_t) 0,
+  _streamwrite,
+  _stremread,
+  _streamput,
+  _streamget,
+};
+
+/**
+ * @brief   Enumerator of special keyboard keys.
+ */
+typedef enum special_key {
+  KEY_UNKNOWN,      /**< any/unknow key */
+  KEY_AMBIGUOUS,    /**< key is ambiguous */
+  KEY_TAB,          /**< tabulator key */
+  KEY_ESCAPE,       /**< escape key */
+  KEY_BACKSPACE,    /**< backspace key */
+  KEY_INSERT,       /**< insert key */
+  KEY_DELETE,       /**< delete key */
+  KEY_HOME,         /**< home key */
+  KEY_END,          /**< end key */
+  KEY_PAGE_UP,      /**< page up key */
+  KEY_PAGE_DOWN,    /**< page down key */
+  KEY_ARROW_UP,     /**< arrow up key */
+  KEY_ARROW_DOWN,   /**< arrow down key */
+  KEY_ARROW_LEFT,   /**< arrow left key */
+  KEY_ARROW_RIGHT,  /**< arrow right key */
+} special_key_t;
+
+/**
+ * @brief   Enumerator for case (in)sensitive character matching.
+ */
+typedef enum charmatch {
+  CHAR_MATCH_NOT    = 0,  /**< Characters do not match at all. */
+  CHAR_MATCH_NCASE  = 1,  /**< Characters would match case insensitive. */
+  CHAR_MATCH_CASE   = 2,  /**< Characters do match with case. */
+} charmatch_t;
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
 /**
  * @brief   Implementation of the BaseAsynchronous write() method (inherited from BaseSequentialStream).
  */
@@ -142,7 +229,8 @@ static size_t _channelreadt(void *instance, uint8_t *bp, size_t n, sysinterval_t
 /**
  * @brief   Implementation of the BaseAsynchronousChannel ctl() method.
  */
-static msg_t _channelctl(void *instance, unsigned int operation, void *arg) {
+static msg_t _channelctl(void *instance, unsigned int operation, void *arg)
+{
   (void) instance;
 
   switch (operation) {
@@ -158,19 +246,6 @@ static msg_t _channelctl(void *instance, unsigned int operation, void *arg) {
   return MSG_OK;
 }
 
-static const struct AosShellChannelVMT _channelvmt = {
-  (size_t) 0,
-  _channelwrite,
-  _channelread,
-  _channelput,
-  _channelget,
-  _channelputt,
-  _channelgett,
-  _channelwritet,
-  _channelreadt,
-  _channelctl,
-};
-
 static size_t _streamwrite(void *instance, const uint8_t *bp, size_t n)
 {
   aosDbgCheck(instance != NULL);
@@ -224,44 +299,6 @@ static msg_t _streamget(void *instance)
   return 0;
 }
 
-static const struct AosShellStreamVMT _streamvmt = {
-  (size_t) 0,
-  _streamwrite,
-  _stremread,
-  _streamput,
-  _streamget,
-};
-
-/**
- * @brief   Enumerator of special keyboard keys.
- */
-typedef enum special_key {
-  KEY_UNKNOWN,      /**< any/unknow key */
-  KEY_AMBIGUOUS,    /**< key is ambiguous */
-  KEY_TAB,          /**< tabulator key */
-  KEY_ESCAPE,       /**< escape key */
-  KEY_BACKSPACE,    /**< backspace key */
-  KEY_INSERT,       /**< insert key */
-  KEY_DELETE,       /**< delete key */
-  KEY_HOME,         /**< home key */
-  KEY_END,          /**< end key */
-  KEY_PAGE_UP,      /**< page up key */
-  KEY_PAGE_DOWN,    /**< page down key */
-  KEY_ARROW_UP,     /**< arrow up key */
-  KEY_ARROW_DOWN,   /**< arrow down key */
-  KEY_ARROW_LEFT,   /**< arrow left key */
-  KEY_ARROW_RIGHT,  /**< arrow right key */
-} special_key_t;
-
-/**
- * @brief   Enumerator for case (in)sensitive character matching.
- */
-typedef enum charmatch {
-  CHAR_MATCH_NOT    = 0,  /**< Characters do not match at all. */
-  CHAR_MATCH_NCASE  = 1,  /**< Characters would match case insensitive. */
-  CHAR_MATCH_CASE   = 2,  /**< Characters do match with case. */
-} charmatch_t;
-
 /**
  * @brief   Print the shell prompt
  * @details Depending on the configuration flags, the system uptime is printed before the prompt string.
@@ -1095,6 +1132,10 @@ static size_t _parseArguments(aos_shell_t* shell)
   return arg;
 }
 
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
+
 /**
  * @brief   Initializes a shell object with the specified parameters.
  *
diff --git a/core/src/aos_system.c b/core/src/aos_system.c
index e02c87d..28c3c2a 100644
--- a/core/src/aos_system.c
+++ b/core/src/aos_system.c
@@ -37,6 +37,10 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #include <rt_test_root.h>
 #endif
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
 /**
  * @brief   Period of the system timer.
  */
@@ -52,13 +56,40 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
  */
 #define SYSTEM_INFO_NAMEWIDTH         14
 
-/* forward declarations */
-static void _printSystemInfo(BaseSequentialStream* stream);
-#if (AMIROOS_CFG_SHELL_ENABLE == true) || (AMIROOS_CFG_TESTS_ENABLE == true)
+#if ((AMIROOS_CFG_SSSP_ENABLE == true) && (AMIROOS_CFG_SSSP_MASTER != true) && (AMIROOS_CFG_PROFILE == true)) || defined(__DOXYGEN__)
+
+/**
+ * @brief   Weighting factor for the low-pass filter used for calculating the @p _syssyncskew value.
+ */
+#define SYSTEM_SYSSYNCSKEW_LPFACTOR   (0.1f / AOS_SYSTEM_TIME_RESOLUTION)
+
+#endif /* (AMIROOS_CFG_SSSP_ENABLE == true) && (AMIROOS_CFG_SSSP_MASTER != true) && (AMIROOS_CFG_PROFILE == true) */
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/**
+ * @brief   Global system object.
+ */
+aos_system_t aos;
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/*
+ * forward declarations
+ */
+#if (AMIROOS_CFG_SHELL_ENABLE == true) || (AMIROOS_CFG_TESTS_ENABLE == true) || defined(__DOXYGEN__)
 static int _shellcmd_configcb(BaseSequentialStream* stream, int argc, char* argv[]);
 static int _shellcmd_infocb(BaseSequentialStream* stream, int argc, char* argv[]);
 static int _shellcmd_shutdowncb(BaseSequentialStream* stream, int argc, char* argv[]);
-#if (AMIROOS_CFG_TESTS_ENABLE == true)
+#if (AMIROOS_CFG_TESTS_ENABLE == true) || defined(__DOXYGEN__)
 static int _shellcmd_kerneltestcb(BaseSequentialStream* stream, int argc, char* argv[]);
 #endif /* AMIROOS_CFG_TESTS_ENABLE == true */
 #endif /* (AMIROOS_CFG_SHELL_ENABLE == true) || (AMIROOS_CFG_TESTS_ENABLE == true) */
@@ -88,7 +119,7 @@ static virtual_timer_t _syssynctimer;
  * @brief   Last uptime of system wide time synchronization.
  */
 static aos_timestamp_t _syssynctime;
-#endif
+#endif /* (AMIROOS_CFG_SSSP_ENABLE == true) && (AMIROOS_CFG_SSSP_MASTER == true) */
 
 #if ((AMIROOS_CFG_SSSP_ENABLE == true) && (AMIROOS_CFG_SSSP_MASTER != true) && (AMIROOS_CFG_PROFILE == true)) || defined(__DOXYGEN__)
 /**
@@ -96,10 +127,6 @@ static aos_timestamp_t _syssynctime;
  */
 static float _syssyncskew;
 
-/**
- * @brief   Weighting factor for the low-pass filter used for calculating the @p _syssyncskew value.
- */
-#define SYSTEM_SYSSYNCSKEW_LPFACTOR   (0.1f / AOS_SYSTEM_TIME_RESOLUTION)
 #endif /* (AMIROOS_CFG_SSSP_ENABLE == true) && (AMIROOS_CFG_SSSP_MASTER != true) && (AMIROOS_CFG_PROFILE == true) */
 
 #if (AMIROOS_CFG_SHELL_ENABLE == true) || (AMIROOS_CFG_TESTS_ENABLE == true) || defined(__DOXYGEN__)
@@ -161,10 +188,9 @@ static aos_shellcommand_t _shellcmd_kerneltest = {
 #endif /* AMIROOS_CFG_TESTS_ENABLE == true */
 #endif /* (AMIROOS_CFG_SHELL_ENABLE == true) || (AMIROOS_CFG_TESTS_ENABLE == true) */
 
-/**
- * @brief   Global system object.
- */
-aos_system_t aos;
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
 
 /**
  * @brief   Print a separator line.
@@ -751,6 +777,10 @@ static void _sysSyncTimerCallback(void* par)
 }
 #endif /* (AMIROOS_CFG_SSSP_ENABLE == true) && (AMIROOS_CFG_SSSP_MASTER == true) */
 
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
+
 /**
  * @brief   AMiRo-OS system initialization.
  * @note    Must be called from the system control thread (usually main thread).
diff --git a/core/src/aos_thread.c b/core/src/aos_thread.c
index ecd3e58..29fc2c7 100644
--- a/core/src/aos_thread.c
+++ b/core/src/aos_thread.c
@@ -25,6 +25,29 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
  */
 
 #include <aos_thread.h>
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
 
 /**
  * @brief   Lets the calling thread sleep until the specifide system uptime.
diff --git a/core/src/aos_time.c b/core/src/aos_time.c
index 677733c..abecf4f 100644
--- a/core/src/aos_time.c
+++ b/core/src/aos_time.c
@@ -26,6 +26,29 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <aos_time.h>
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
 #include <aos_debug.h>
 #include <aos_system.h>
 
diff --git a/core/src/aos_timer.c b/core/src/aos_timer.c
index d29e9bf..ca9b4fe 100644
--- a/core/src/aos_timer.c
+++ b/core/src/aos_timer.c
@@ -27,15 +27,32 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <aos_timer.h>
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
 #include <aos_system.h>
 
 /*
- * Forward declarations.
+ * forward declarations
  */
-static inline void _setupTimer(aos_timer_t* timer);
-static inline void _setupPeriodicTimer(aos_periodictimer_t* ptimer);
 static void _intermediateCb(void* timer);
-static void _fireCb(void* timer);
+static void _fireCb(void *timer);
 static void _periodicCb(void* ptimer);
 
 /**
@@ -134,6 +151,10 @@ static void _periodicCb(void* ptimer)
   _setupPeriodicTimer((aos_periodictimer_t*)ptimer);
 }
 
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
+
 /**
  * @brief   Initialize a aos_timer_t object.
  *
diff --git a/core/src/aos_unittest.c b/core/src/aos_unittest.c
index d436894..8f966d9 100644
--- a/core/src/aos_unittest.c
+++ b/core/src/aos_unittest.c
@@ -32,6 +32,29 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #include <aos_debug.h>
 #include <chprintf.h>
 #include <string.h>
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
 
 /**
  * @brief   Retrieve the total number of tests (passed and failed).
diff --git a/unittests/lld/inc/ut_lld_adc.h b/unittests/lld/inc/ut_lld_adc.h
index f78e620..bcec2eb 100644
--- a/unittests/lld/inc/ut_lld_adc.h
+++ b/unittests/lld/inc/ut_lld_adc.h
@@ -23,6 +23,22 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && (HAL_USE_ADC == TRUE))|| defined(__DOXYGEN__)
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
 /**
  * @brief   Custom data structure for the unit test.
  */
@@ -38,6 +54,14 @@ typedef struct {
   ADCConversionGroup* convgroup;
 } ut_adcdata_t;
 
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -46,6 +70,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && (HAL_USE_ADC == TRUE) */
 
 #endif /* AMIROOS_UT_LLD_ADC_H */
diff --git a/unittests/lld/src/ut_lld_adc.c b/unittests/lld/src/ut_lld_adc.c
index cb09a71..b5733de 100644
--- a/unittests/lld/src/ut_lld_adc.c
+++ b/unittests/lld/src/ut_lld_adc.c
@@ -20,6 +20,9 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && (HAL_USE_ADC == TRUE))|| defined(__DOXYGEN__)
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
 #include <aos_debug.h>
 #include <aos_thread.h>
 #include <chprintf.h>
@@ -34,11 +37,27 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
  */
 #define _adcWdgThreshold                        (uint16_t)(9.0f / 5.0f / 3.3f * ((1 << 12) - 1) + 0.5f)
 
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
 /**
  * @brief   Pointer to the thread listening for an ADC analog watchdog event.
  */
 static thread_t* _listener;
 
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
 /**
  * @brief   Helper function to convert ADC sample value to volts.
  *
@@ -72,6 +91,10 @@ static void _adcAwdCb(ADCDriver* adcp, adcerror_t err)
   return;
 }
 
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
+
 /**
  * @brief   ADC unit test function.
  *
diff --git a/unittests/periphery-lld/inc/ut_alld_a3906.h b/unittests/periphery-lld/inc/ut_alld_a3906.h
index 668c08f..8272a40 100644
--- a/unittests/periphery-lld/inc/ut_alld_a3906.h
+++ b/unittests/periphery-lld/inc/ut_alld_a3906.h
@@ -26,6 +26,22 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <alld_a3906.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
 /**
  * @brief   Custom data structure for the unit test.
  */
@@ -111,6 +127,14 @@ typedef struct {
   apalTime_t timeout;
 } ut_a3906data_t;
 
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -119,6 +143,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_A3906) */
 
 #endif /* AMIROOS_UT_ALLD_A3906_H */
diff --git a/unittests/periphery-lld/inc/ut_alld_at24c01bn-sh-b.h b/unittests/periphery-lld/inc/ut_alld_at24c01bn-sh-b.h
index 31d129f..12205e9 100644
--- a/unittests/periphery-lld/inc/ut_alld_at24c01bn-sh-b.h
+++ b/unittests/periphery-lld/inc/ut_alld_at24c01bn-sh-b.h
@@ -26,6 +26,22 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <alld_at24c01bn-sh-b.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
 /**
  * @brief   Custom data structure for the unit test.
  */
@@ -41,6 +57,18 @@ typedef struct {
   apalTime_t timeout;
 } ut_at24c01bndata_t;
 
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
diff --git a/unittests/periphery-lld/inc/ut_alld_at42qt1050.h b/unittests/periphery-lld/inc/ut_alld_at42qt1050.h
index c144abb..cad17a3 100644
--- a/unittests/periphery-lld/inc/ut_alld_at42qt1050.h
+++ b/unittests/periphery-lld/inc/ut_alld_at42qt1050.h
@@ -26,6 +26,22 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <alld_at42qt1050.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
 /**
  * @brief   Custom data structure for the unit test.
  */
@@ -51,6 +67,14 @@ typedef struct {
   eventflags_t evtflags;
 } ut_at42qt1050data_t;
 
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -59,6 +83,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_AT42QT1050) */
 
 #endif /* AMIROOS_UT_ALLD_AT42QT1050_H */
diff --git a/unittests/periphery-lld/inc/ut_alld_bq24103a.h b/unittests/periphery-lld/inc/ut_alld_bq24103a.h
index 120d994..0daf5ed 100644
--- a/unittests/periphery-lld/inc/ut_alld_bq24103a.h
+++ b/unittests/periphery-lld/inc/ut_alld_bq24103a.h
@@ -26,6 +26,30 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <alld_bq24103a.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -34,6 +58,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_BQ24103A) */
 
 #endif /* AMIROOS_UT_ALLD_BQ24103A_H */
diff --git a/unittests/periphery-lld/inc/ut_alld_bq27500.h b/unittests/periphery-lld/inc/ut_alld_bq27500.h
index 050dd48..72c1c2f 100644
--- a/unittests/periphery-lld/inc/ut_alld_bq27500.h
+++ b/unittests/periphery-lld/inc/ut_alld_bq27500.h
@@ -26,6 +26,22 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <alld_bq27500.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
 /**
  * @brief   Custom data structure for the unit test.
  */
@@ -41,6 +57,14 @@ typedef struct {
   apalTime_t timeout;
 } ut_bq27500data_t;
 
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -49,7 +73,10 @@ extern "C" {
 }
 #endif
 
-#endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_BQ27500) */
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
 
+#endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_BQ27500) */
 
 #endif /* AMIROOS_UT_ALLD_BQ27500_H */
diff --git a/unittests/periphery-lld/inc/ut_alld_bq27500_bq24103a.h b/unittests/periphery-lld/inc/ut_alld_bq27500_bq24103a.h
index b9c3f04..462531f 100644
--- a/unittests/periphery-lld/inc/ut_alld_bq27500_bq24103a.h
+++ b/unittests/periphery-lld/inc/ut_alld_bq27500_bq24103a.h
@@ -27,6 +27,22 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #include <alld_bq27500.h>
 #include <alld_bq24103a.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
 /**
  * @brief   Custom data structure for the unit test.
  */
@@ -47,6 +63,14 @@ typedef struct {
   apalTime_t timeout;
 } ut_bq27500bq24103adata_t;
 
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -55,6 +79,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_BQ27500) && defined(AMIROLLD_CFG_USE_BQ24103A) */
 
 #endif /* AMIROOS_UT_ALLD_BQ27500_BQ24193A_H */
diff --git a/unittests/periphery-lld/inc/ut_alld_dw1000.h b/unittests/periphery-lld/inc/ut_alld_dw1000.h
index ed59b07..8a869f8 100755
--- a/unittests/periphery-lld/inc/ut_alld_dw1000.h
+++ b/unittests/periphery-lld/inc/ut_alld_dw1000.h
@@ -27,6 +27,30 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #include <alld_dw1000.h>
 //#include <deca_instance.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -35,6 +59,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_DW1000) */
 
 #endif /* AMIROOS_UT_DW1000_LLD_H */
diff --git a/unittests/periphery-lld/inc/ut_alld_hmc5883l.h b/unittests/periphery-lld/inc/ut_alld_hmc5883l.h
index d2efa8d..2983ecb 100644
--- a/unittests/periphery-lld/inc/ut_alld_hmc5883l.h
+++ b/unittests/periphery-lld/inc/ut_alld_hmc5883l.h
@@ -26,6 +26,22 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <alld_hmc5883l.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
 /**
  * @brief   Constum data structure for this unit test.
  */
@@ -51,6 +67,14 @@ typedef struct {
   apalTime_t timeout;
 } ut_hmc5883ldata_t;
 
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -59,7 +83,10 @@ extern "C" {
 }
 #endif
 
-#endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_HMC5883L) */
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
 
+#endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_HMC5883L) */
 
 #endif /* AMIROOS_UT_HMC5883L_LLD_H */
diff --git a/unittests/periphery-lld/inc/ut_alld_ina219.h b/unittests/periphery-lld/inc/ut_alld_ina219.h
index bc39dea..43bab57 100644
--- a/unittests/periphery-lld/inc/ut_alld_ina219.h
+++ b/unittests/periphery-lld/inc/ut_alld_ina219.h
@@ -26,6 +26,22 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <alld_ina219.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
 /**
  * @brief   Custom data structure for the unit test.
  */
@@ -51,6 +67,14 @@ typedef struct {
   apalTime_t timeout;
 } ut_ina219data_t;
 
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -59,6 +83,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_INA219) */
 
 #endif /* AMIROOS_UT_INA219_LLD_H */
diff --git a/unittests/periphery-lld/inc/ut_alld_l3g4200d.h b/unittests/periphery-lld/inc/ut_alld_l3g4200d.h
index f6801de..855c44d 100644
--- a/unittests/periphery-lld/inc/ut_alld_l3g4200d.h
+++ b/unittests/periphery-lld/inc/ut_alld_l3g4200d.h
@@ -26,6 +26,22 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <alld_l3g4200d.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
 /**
  * @brief   Custom data structure for the unit test.
  */
@@ -51,6 +67,14 @@ typedef struct {
   eventflags_t evtflags;
 } ut_l3g4200ddata_t;
 
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -59,7 +83,10 @@ extern "C" {
 }
 #endif
 
-#endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_L3G4200D) */
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
 
+#endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_L3G4200D) */
 
 #endif /* AMIROOS_UT_L3G4200D_LLD_H */
diff --git a/unittests/periphery-lld/inc/ut_alld_led.h b/unittests/periphery-lld/inc/ut_alld_led.h
index ae9792d..a616f91 100644
--- a/unittests/periphery-lld/inc/ut_alld_led.h
+++ b/unittests/periphery-lld/inc/ut_alld_led.h
@@ -26,6 +26,30 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <alld_led.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -34,6 +58,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_LED) */
 
 #endif /* AMIROOS_UT_ALLD_LED_H */
diff --git a/unittests/periphery-lld/inc/ut_alld_lis331dlh.h b/unittests/periphery-lld/inc/ut_alld_lis331dlh.h
index df6d6bd..ab3bdd7 100644
--- a/unittests/periphery-lld/inc/ut_alld_lis331dlh.h
+++ b/unittests/periphery-lld/inc/ut_alld_lis331dlh.h
@@ -26,6 +26,22 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <alld_lis331dlh.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
 /**
  * @brief   Custom data structure for the unit test.
  */
@@ -51,6 +67,14 @@ typedef struct {
   eventflags_t evtflags;
 } ut_lis331dlhdata_t;
 
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -59,7 +83,10 @@ extern "C" {
 }
 #endif
 
-#endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_LIS331DLH) */
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
 
+#endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_LIS331DLH) */
 
 #endif /* AMIROOS_UT_LIS331DLH_LLD_H */
diff --git a/unittests/periphery-lld/inc/ut_alld_ltc4412.h b/unittests/periphery-lld/inc/ut_alld_ltc4412.h
index 333c46b..15dabd8 100644
--- a/unittests/periphery-lld/inc/ut_alld_ltc4412.h
+++ b/unittests/periphery-lld/inc/ut_alld_ltc4412.h
@@ -26,6 +26,30 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <alld_ltc4412.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -34,6 +58,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_LTC4412) */
 
 #endif /* AMIROOS_UT_ALLD_LTC4412_H */
diff --git a/unittests/periphery-lld/inc/ut_alld_mpr121.h b/unittests/periphery-lld/inc/ut_alld_mpr121.h
index db7d9ff..41214f7 100644
--- a/unittests/periphery-lld/inc/ut_alld_mpr121.h
+++ b/unittests/periphery-lld/inc/ut_alld_mpr121.h
@@ -26,6 +26,22 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <alld_mpr121.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
 /**
  * @brief   Custom data structure for the unit test.
  */
@@ -51,6 +67,14 @@ typedef struct {
   eventflags_t evtflags;
 } ut_mpr121data_t;
 
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -59,6 +83,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_MPR121) */
 
 #endif /* AMIROOS_UT_ALLD_MPR121_H */
diff --git a/unittests/periphery-lld/inc/ut_alld_mpu6050.h b/unittests/periphery-lld/inc/ut_alld_mpu6050.h
index a137f05..cfa5f6d 100644
--- a/unittests/periphery-lld/inc/ut_alld_mpu6050.h
+++ b/unittests/periphery-lld/inc/ut_alld_mpu6050.h
@@ -26,6 +26,22 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <alld_mpu6050.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
 /**
  * @brief   Custom data structure for the unit test.
  */
@@ -41,6 +57,14 @@ typedef struct {
   apalTime_t timeout;
 } ut_mpu6050data_t;
 
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -49,6 +73,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_MPU6050) */
 
 #endif /* AMIROOS_UT_MPU6050_LLD_HPP */
diff --git a/unittests/periphery-lld/inc/ut_alld_pca9544a.h b/unittests/periphery-lld/inc/ut_alld_pca9544a.h
index 4003863..8a079c0 100644
--- a/unittests/periphery-lld/inc/ut_alld_pca9544a.h
+++ b/unittests/periphery-lld/inc/ut_alld_pca9544a.h
@@ -26,6 +26,22 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <alld_pca9544a.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
 /**
  * @brief   Custom data structure for the unit test.
  */
@@ -41,6 +57,14 @@ typedef struct {
   apalTime_t timeout;
 } ut_pca9544adata_t;
 
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -49,8 +73,10 @@ extern "C" {
 }
 #endif
 
-#endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_PCA9544A) */
-
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
 
+#endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_PCA9544A) */
 
 #endif /* AMIROOS_UT_ALLD_PCA9544A_H */
diff --git a/unittests/periphery-lld/inc/ut_alld_pcal6524.h b/unittests/periphery-lld/inc/ut_alld_pcal6524.h
index 218cd37..d110ad2 100644
--- a/unittests/periphery-lld/inc/ut_alld_pcal6524.h
+++ b/unittests/periphery-lld/inc/ut_alld_pcal6524.h
@@ -26,6 +26,22 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <alld_pcal6524.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
 /**
  * @brief   Custom data structure for the unit test.
  */
@@ -41,6 +57,14 @@ typedef struct {
   apalTime_t timeout;
 } ut_pcal6524data_t;
 
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -49,6 +73,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_PCAL6524) */
 
 #endif /* AMIROOS_UT_PCAL6524_LLD_H */
diff --git a/unittests/periphery-lld/inc/ut_alld_pklcs1212e4001.h b/unittests/periphery-lld/inc/ut_alld_pklcs1212e4001.h
index 43c8673..f821eeb 100644
--- a/unittests/periphery-lld/inc/ut_alld_pklcs1212e4001.h
+++ b/unittests/periphery-lld/inc/ut_alld_pklcs1212e4001.h
@@ -26,6 +26,22 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <alld_pklcs1212e4001.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
 /**
  * @brief   Custom data structure for the unit test.
  */
@@ -41,6 +57,14 @@ typedef struct {
   apalPWMchannel_t channel;
 } ut_pklcs1212e4001_t;
 
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -49,6 +73,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_PKLCS1212E4001) */
 
 #endif /* AMIROOS_UT_ALLD_PKLCS1212E4001_H */
diff --git a/unittests/periphery-lld/inc/ut_alld_tlc5947.h b/unittests/periphery-lld/inc/ut_alld_tlc5947.h
index f8bf8dc..9073afe 100644
--- a/unittests/periphery-lld/inc/ut_alld_tlc5947.h
+++ b/unittests/periphery-lld/inc/ut_alld_tlc5947.h
@@ -26,6 +26,30 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <alld_tlc5947.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -34,6 +58,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_TLC5947) */
 
 #endif /* AMIROOS_UT_ALLD_TLC5947_H */
diff --git a/unittests/periphery-lld/inc/ut_alld_tps2051bdbv.h b/unittests/periphery-lld/inc/ut_alld_tps2051bdbv.h
index 6eb0968..03e54fd 100644
--- a/unittests/periphery-lld/inc/ut_alld_tps2051bdbv.h
+++ b/unittests/periphery-lld/inc/ut_alld_tps2051bdbv.h
@@ -26,6 +26,30 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <alld_tps2051bdbv.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -34,6 +58,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_TPS2051BDBV) */
 
 #endif /* AMIROOS_UT_ALLD_TPS2051BDBV_H */
diff --git a/unittests/periphery-lld/inc/ut_alld_tps62113.h b/unittests/periphery-lld/inc/ut_alld_tps62113.h
index f186cc1..83c0ead 100644
--- a/unittests/periphery-lld/inc/ut_alld_tps62113.h
+++ b/unittests/periphery-lld/inc/ut_alld_tps62113.h
@@ -26,6 +26,30 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <alld_tps62113.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -34,7 +58,10 @@ extern "C" {
 }
 #endif
 
-#endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_TPS62113) */
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
 
+#endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_TPS62113) */
 
 #endif /* AMIROOS_UT_ALLD_TPS62113_H */
diff --git a/unittests/periphery-lld/inc/ut_alld_tps62113_ina219.h b/unittests/periphery-lld/inc/ut_alld_tps62113_ina219.h
index 08f9aa0..35f0f45 100644
--- a/unittests/periphery-lld/inc/ut_alld_tps62113_ina219.h
+++ b/unittests/periphery-lld/inc/ut_alld_tps62113_ina219.h
@@ -27,6 +27,22 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #include <alld_tps62113.h>
 #include <alld_ina219.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
 /**
  * @brief   Custom data structure for the unit test.
  */
@@ -47,6 +63,14 @@ typedef struct {
   apalTime_t timeout;
 } ut_tps62113ina219data_t;
 
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -55,6 +79,10 @@ extern "C" {
 }
 #endif
 
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
+
 #endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_TPS62113) && defined(AMIROLLD_CFG_USE_INA219) */
 
 #endif /* AMIROOS_UT_ALLD_TPS62113_INA219_H */
diff --git a/unittests/periphery-lld/inc/ut_alld_vcnl4020.h b/unittests/periphery-lld/inc/ut_alld_vcnl4020.h
index 195c9a4..8d899b4 100644
--- a/unittests/periphery-lld/inc/ut_alld_vcnl4020.h
+++ b/unittests/periphery-lld/inc/ut_alld_vcnl4020.h
@@ -26,6 +26,22 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #include <alld_vcnl4020.h>
 
+/******************************************************************************/
+/* CONSTANTS                                                                  */
+/******************************************************************************/
+
+/******************************************************************************/
+/* SETTINGS                                                                   */
+/******************************************************************************/
+
+/******************************************************************************/
+/* CHECKS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* DATA STRUCTURES AND TYPES                                                  */
+/******************************************************************************/
+
 /**
  * @brief   Custom data structure for the unit test.
  */
@@ -51,6 +67,14 @@ typedef struct {
   eventflags_t evtflags;
 } ut_vcnl4020data_t;
 
+/******************************************************************************/
+/* MACROS                                                                     */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXTERN DECLARATIONS                                                        */
+/******************************************************************************/
+
 #ifdef __cplusplus
 extern "C" {
 #endif
@@ -59,8 +83,10 @@ extern "C" {
 }
 #endif
 
-#endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_VCNL4020) */
-
+/******************************************************************************/
+/* INLINE FUNCTIONS                                                           */
+/******************************************************************************/
 
+#endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_VCNL4020) */
 
 #endif /* AMIROOS_UT_VCNL4020_LLD_H */
diff --git a/unittests/periphery-lld/src/ut_alld_a3906.c b/unittests/periphery-lld/src/ut_alld_a3906.c
index e61f742..8af1cd8 100644
--- a/unittests/periphery-lld/src/ut_alld_a3906.c
+++ b/unittests/periphery-lld/src/ut_alld_a3906.c
@@ -27,6 +27,10 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #include <stdlib.h>
 #include <math.h>
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
 /**
  * @brief   Interval to poll QEI in certain tests.
  */
@@ -40,6 +44,14 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
  */
 #define QEI_DIFF_THRESHOLD            (apalQEICount_t)(7000 * 0.02f)
 
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
 /**
  * @brief   Enumerator to distinguish between left and right wheel.
  */
@@ -56,6 +68,14 @@ typedef enum {
   DIRECTION_BACKWARD  = 1,  /**< backward direction identifier */
 } direction_t;
 
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
 /**
  * @brief   helper function to test each wheel and direction separately.
  *
@@ -175,6 +195,10 @@ void _wheelSpeedTest(BaseSequentialStream* stream, ut_a3906data_t* data, wheel_t
   }
 }
 
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
+
 /**
  * @brief   A3905 unit test function.
  *
diff --git a/unittests/periphery-lld/src/ut_alld_at24c01bn-sh-b.c b/unittests/periphery-lld/src/ut_alld_at24c01bn-sh-b.c
index d483867..1317f50 100644
--- a/unittests/periphery-lld/src/ut_alld_at24c01bn-sh-b.c
+++ b/unittests/periphery-lld/src/ut_alld_at24c01bn-sh-b.c
@@ -20,6 +20,9 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_AT24C01BN)) || defined(__DOXYGEN__)
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
 #include <aos_debug.h>
 #include <chprintf.h>
 
@@ -48,6 +51,26 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
  */
 #define _bytedata                     0xA5
 
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
+
 /**
  * @brief   AT24C01BN-SH-B unit test function.
  *
diff --git a/unittests/periphery-lld/src/ut_alld_at42qt1050.c b/unittests/periphery-lld/src/ut_alld_at42qt1050.c
index 23ebfd6..ab6a2b7 100644
--- a/unittests/periphery-lld/src/ut_alld_at42qt1050.c
+++ b/unittests/periphery-lld/src/ut_alld_at42qt1050.c
@@ -20,6 +20,9 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_AT42QT1050)) || defined(__DOXYGEN__)
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
 #include <aos_debug.h>
 #include <chprintf.h>
 #include <aos_thread.h>
@@ -27,6 +30,26 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #define INTERRUPT_EVENT_ID            1
 
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
+
 aos_utresult_t utAlldAt42qt1050Func(BaseSequentialStream* stream, aos_unittest_t* ut)
 {
   aosDbgCheck(ut->data != NULL && ((ut_at42qt1050data_t*)ut->data)->at42qt1050d != NULL);
diff --git a/unittests/periphery-lld/src/ut_alld_bq24103a.c b/unittests/periphery-lld/src/ut_alld_bq24103a.c
index e5d8708..466f2a7 100644
--- a/unittests/periphery-lld/src/ut_alld_bq24103a.c
+++ b/unittests/periphery-lld/src/ut_alld_bq24103a.c
@@ -20,6 +20,30 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_BQ24103A)) || defined(__DOXYGEN__)
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
+
 #include <aos_debug.h>
 #include <chprintf.h>
 #include <aos_thread.h>
diff --git a/unittests/periphery-lld/src/ut_alld_bq27500.c b/unittests/periphery-lld/src/ut_alld_bq27500.c
index 1d40c68..f796660 100644
--- a/unittests/periphery-lld/src/ut_alld_bq27500.c
+++ b/unittests/periphery-lld/src/ut_alld_bq27500.c
@@ -21,6 +21,10 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_BQ27500)) || defined(__DOXYGEN__)
 
 #include <string.h>
+
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
 #include <aos_debug.h>
 #include <chprintf.h>
 #include <aos_thread.h>
@@ -41,6 +45,22 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #endif
 
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
 bq27500_lld_control_status_t _try_unseal(BQ27500Driver* driver, uint16_t key0, uint16_t key1, apalTime_t timeout) {
   uint16_t dst;
   bq27500_lld_control_status_t ctrl;
@@ -254,6 +274,10 @@ void _bruteforce_sealed_key(BaseSequentialStream* stream, BQ27500Driver* driver,
   chprintf(stream, "\t\tfailed, no keys could be found");
 }
 
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
+
 aos_utresult_t utAlldBq27500Func(BaseSequentialStream* stream, aos_unittest_t* ut)
 {
   aosDbgCheck(ut->data != NULL && ((ut_bq27500data_t*)(ut->data))->driver != NULL);
diff --git a/unittests/periphery-lld/src/ut_alld_bq27500_bq24103a.c b/unittests/periphery-lld/src/ut_alld_bq27500_bq24103a.c
index f304c49..78e5589 100644
--- a/unittests/periphery-lld/src/ut_alld_bq27500_bq24103a.c
+++ b/unittests/periphery-lld/src/ut_alld_bq27500_bq24103a.c
@@ -20,6 +20,30 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_BQ27500) && defined(AMIROLLD_CFG_USE_BQ24103A)) || defined(__DOXYGEN__)
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
+
 #include <aos_debug.h>
 #include <chprintf.h>
 #include <aos_thread.h>
diff --git a/unittests/periphery-lld/src/ut_alld_dw1000.c b/unittests/periphery-lld/src/ut_alld_dw1000.c
index a0c977b..d1d100a 100755
--- a/unittests/periphery-lld/src/ut_alld_dw1000.c
+++ b/unittests/periphery-lld/src/ut_alld_dw1000.c
@@ -20,6 +20,9 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_DW1000)) || defined(__DOXYGEN__)
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
 #include <aos_debug.h>
 #include <chprintf.h>
 #include <aos_thread.h>
@@ -29,6 +32,25 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #include <alld_dw1000_regs.h>
 #include <math.h>
 
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
 
 aos_utresult_t utAlldDw1000Func(BaseSequentialStream* stream, aos_unittest_t* ut) {
 
diff --git a/unittests/periphery-lld/src/ut_alld_hmc5883l.c b/unittests/periphery-lld/src/ut_alld_hmc5883l.c
index f3e1332..e34d07f 100644
--- a/unittests/periphery-lld/src/ut_alld_hmc5883l.c
+++ b/unittests/periphery-lld/src/ut_alld_hmc5883l.c
@@ -20,6 +20,29 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_HMC5883L)) || defined(__DOXYGEN__)
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
 #include <aos_debug.h>
 #include <chprintf.h>
 #include <alld_hmc5883l.h>
diff --git a/unittests/periphery-lld/src/ut_alld_ina219.c b/unittests/periphery-lld/src/ut_alld_ina219.c
index 0d12e86..a21f857 100644
--- a/unittests/periphery-lld/src/ut_alld_ina219.c
+++ b/unittests/periphery-lld/src/ut_alld_ina219.c
@@ -26,6 +26,30 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #include <alld_ina219.h>
 #include <math.h>
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
+
 aos_utresult_t utAlldIna219Func(BaseSequentialStream* stream, aos_unittest_t* ut)
 {
   aosDbgCheck(ut->data != NULL && ((ut_ina219data_t*)(ut->data))->inad != NULL);
diff --git a/unittests/periphery-lld/src/ut_alld_l3g4200d.c b/unittests/periphery-lld/src/ut_alld_l3g4200d.c
index 9fcef91..c45e894 100644
--- a/unittests/periphery-lld/src/ut_alld_l3g4200d.c
+++ b/unittests/periphery-lld/src/ut_alld_l3g4200d.c
@@ -20,6 +20,29 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_L3G4200D)) || defined(__DOXYGEN__)
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
 #include <aos_debug.h>
 #include <chprintf.h>
 #include <aos_thread.h>
diff --git a/unittests/periphery-lld/src/ut_alld_led.c b/unittests/periphery-lld/src/ut_alld_led.c
index 2b71eee..a1ab545 100644
--- a/unittests/periphery-lld/src/ut_alld_led.c
+++ b/unittests/periphery-lld/src/ut_alld_led.c
@@ -20,6 +20,29 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_LED)) || defined(__DOXYGEN__)
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
 #include <aos_debug.h>
 #include <chprintf.h>
 #include <alld_led.h>
diff --git a/unittests/periphery-lld/src/ut_alld_lis331dlh.c b/unittests/periphery-lld/src/ut_alld_lis331dlh.c
index 9d159f7..2391681 100644
--- a/unittests/periphery-lld/src/ut_alld_lis331dlh.c
+++ b/unittests/periphery-lld/src/ut_alld_lis331dlh.c
@@ -20,6 +20,29 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_LIS331DLH)) || defined(__DOXYGEN__)
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
 #include <aos_debug.h>
 #include <chprintf.h>
 #include <aos_thread.h>
diff --git a/unittests/periphery-lld/src/ut_alld_ltc4412.c b/unittests/periphery-lld/src/ut_alld_ltc4412.c
index be48f56..f7b2ed1 100644
--- a/unittests/periphery-lld/src/ut_alld_ltc4412.c
+++ b/unittests/periphery-lld/src/ut_alld_ltc4412.c
@@ -20,6 +20,29 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_LTC4412)) || defined(__DOXYGEN__)
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
 #include <aos_debug.h>
 #include <chprintf.h>
 #include <aos_thread.h>
diff --git a/unittests/periphery-lld/src/ut_alld_mpr121.c b/unittests/periphery-lld/src/ut_alld_mpr121.c
index 895b413..863b940 100644
--- a/unittests/periphery-lld/src/ut_alld_mpr121.c
+++ b/unittests/periphery-lld/src/ut_alld_mpr121.c
@@ -20,6 +20,9 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_MPR121)) || defined(__DOXYGEN__)
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
 #include <aos_debug.h>
 #include <chprintf.h>
 #include <aos_thread.h>
@@ -27,6 +30,26 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #define INTERRUPT_EVENT_ID            1
 
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
+
 aos_utresult_t utAlldMpr121Func(BaseSequentialStream* stream, aos_unittest_t* ut)
 {
   aosDbgCheck(ut->data != NULL && ((ut_mpr121data_t*)ut->data)->mprd != NULL);
diff --git a/unittests/periphery-lld/src/ut_alld_mpu6050.c b/unittests/periphery-lld/src/ut_alld_mpu6050.c
index 4400fb4..14da4d7 100644
--- a/unittests/periphery-lld/src/ut_alld_mpu6050.c
+++ b/unittests/periphery-lld/src/ut_alld_mpu6050.c
@@ -20,6 +20,29 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_MPU6050)) || defined(__DOXYGEN__)
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
 #include <aos_debug.h>
 #include <chprintf.h>
 #include <aos_thread.h>
diff --git a/unittests/periphery-lld/src/ut_alld_pca9544a.c b/unittests/periphery-lld/src/ut_alld_pca9544a.c
index ecadcb5..587d8f6 100644
--- a/unittests/periphery-lld/src/ut_alld_pca9544a.c
+++ b/unittests/periphery-lld/src/ut_alld_pca9544a.c
@@ -20,6 +20,29 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_PCA9544A)) || defined(__DOXYGEN__)
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
 #include <aos_debug.h>
 #include <chprintf.h>
 #include <aos_thread.h>
diff --git a/unittests/periphery-lld/src/ut_alld_pcal6524.c b/unittests/periphery-lld/src/ut_alld_pcal6524.c
index f55af93..9628770 100644
--- a/unittests/periphery-lld/src/ut_alld_pcal6524.c
+++ b/unittests/periphery-lld/src/ut_alld_pcal6524.c
@@ -23,6 +23,30 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #include <chprintf.h>
 #include <string.h>
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
+
 aos_utresult_t utAlldPcal6524Func(BaseSequentialStream* stream, aos_unittest_t *ut)
 {
   aosDbgCheck((ut->data != NULL) &&
diff --git a/unittests/periphery-lld/src/ut_alld_pklcs1212e4001.c b/unittests/periphery-lld/src/ut_alld_pklcs1212e4001.c
index 09f6c0c..77d564b 100644
--- a/unittests/periphery-lld/src/ut_alld_pklcs1212e4001.c
+++ b/unittests/periphery-lld/src/ut_alld_pklcs1212e4001.c
@@ -20,6 +20,29 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_PKLCS1212E4001)) || defined(__DOXYGEN__)
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
 #include <aos_debug.h>
 #include <chprintf.h>
 #include <aos_thread.h>
diff --git a/unittests/periphery-lld/src/ut_alld_tlc5947.c b/unittests/periphery-lld/src/ut_alld_tlc5947.c
index 7ba3104..06668d7 100644
--- a/unittests/periphery-lld/src/ut_alld_tlc5947.c
+++ b/unittests/periphery-lld/src/ut_alld_tlc5947.c
@@ -25,6 +25,29 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 #include <alld_tlc5947.h>
 #include <string.h>
 #include <aos_thread.h>
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
 
 /**
  * @brief   TLC9547 unit test function
diff --git a/unittests/periphery-lld/src/ut_alld_tps2051bdbv.c b/unittests/periphery-lld/src/ut_alld_tps2051bdbv.c
index b101cff..429c15c 100644
--- a/unittests/periphery-lld/src/ut_alld_tps2051bdbv.c
+++ b/unittests/periphery-lld/src/ut_alld_tps2051bdbv.c
@@ -20,6 +20,29 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_TPS2051BDBV)) || defined(__DOXYGEN__)
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
 #include <aos_debug.h>
 #include <chprintf.h>
 
diff --git a/unittests/periphery-lld/src/ut_alld_tps62113.c b/unittests/periphery-lld/src/ut_alld_tps62113.c
index 78c33f3..e419cd6 100644
--- a/unittests/periphery-lld/src/ut_alld_tps62113.c
+++ b/unittests/periphery-lld/src/ut_alld_tps62113.c
@@ -20,6 +20,29 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_TPS62113)) || defined(__DOXYGEN__)
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
 #include <aos_debug.h>
 #include <chprintf.h>
 #include <aos_thread.h>
diff --git a/unittests/periphery-lld/src/ut_alld_tps62113_ina219.c b/unittests/periphery-lld/src/ut_alld_tps62113_ina219.c
index 87eab35..6b0a334 100644
--- a/unittests/periphery-lld/src/ut_alld_tps62113_ina219.c
+++ b/unittests/periphery-lld/src/ut_alld_tps62113_ina219.c
@@ -20,6 +20,29 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_TPS62113) && defined(AMIROLLD_CFG_USE_INA219)) || defined(__DOXYGEN__)
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
 #include <aos_debug.h>
 #include <chprintf.h>
 #include <aos_thread.h>
diff --git a/unittests/periphery-lld/src/ut_alld_vcnl4020.c b/unittests/periphery-lld/src/ut_alld_vcnl4020.c
index 68bba29..a476fa7 100644
--- a/unittests/periphery-lld/src/ut_alld_vcnl4020.c
+++ b/unittests/periphery-lld/src/ut_alld_vcnl4020.c
@@ -20,6 +20,9 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #if ((AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_VCNL4020)) || defined(__DOXYGEN__)
 
+/******************************************************************************/
+/* LOCAL DEFINITIONS                                                          */
+/******************************************************************************/
 #include <aos_debug.h>
 #include <chprintf.h>
 #include <aos_thread.h>
@@ -30,6 +33,26 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 #define INTERRUPT_THRESHOLD           0x2000
 
+/******************************************************************************/
+/* EXPORTED VARIABLES                                                         */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL TYPES                                                                */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL VARIABLES                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* LOCAL FUNCTIONS                                                            */
+/******************************************************************************/
+
+/******************************************************************************/
+/* EXPORTED FUNCTIONS                                                         */
+/******************************************************************************/
+
 aos_utresult_t utAlldVcnl4020Func(BaseSequentialStream* stream, aos_unittest_t* ut)
 {
   aosDbgCheck((ut->data != NULL) &&
@@ -222,5 +245,3 @@ aos_utresult_t utAlldVcnl4020Func(BaseSequentialStream* stream, aos_unittest_t*
 }
 
 #endif /* (AMIROOS_CFG_TESTS_ENABLE == true) && defined(AMIROLLD_CFG_USE_VCNL4020) */
-
-
