]> rtime.felk.cvut.cz Git - pes-rpp/rpp-test-sw.git/blobdiff - rpp-test-sw/commands/cmd_fr_basic_test.c
Update library
[pes-rpp/rpp-test-sw.git] / rpp-test-sw / commands / cmd_fr_basic_test.c
index ff009bfb84353a3d02f63405927fcff72e3d974d..9c9fccca9b879c4d34eb5fbcdfa79e4c6edc7f47 100644 (file)
@@ -6,18 +6,10 @@
  * Authors:
  *     - Michal Horn
  *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program.  If not, see <http://www.gnu.org/licenses/>.
+ * This document contains proprietary information belonging to Czech
+ * Technical University in Prague. Passing on and copying of this
+ * document, and communication of its contents is not permitted
+ * without prior written authorization.
  *
  * File : cmd_fr_basic_test.c
  *
@@ -36,9 +28,7 @@
 
 #include <string.h>
 #include "cmdproc_utils.h"
-#include "drv/drv.h"
 #include "rpp/rpp.h"
-#include "hal/hal.h"
 #include "stdio.h"
 
 #define printf rpp_sci_printf
@@ -62,7 +52,7 @@ static boolean_t fr_initialized = FALSE;
 static Fr_TMS570LS_ClusterConfigType Fr_cluster_config = {
        .gColdStartAttempts = 0x2,
        .gListenNoise = 0xF,
-       .gMacroPerCycle = 0x15E0,       // (cycle period, 5.6us)
+       .gMacroPerCycle = 0x15E0,   // (cycle period, 5.6us)
        .gMaxWithoutClockCorrectionFatal = 0xF,
        .gMaxWithoutClockCorrectionPassive = 0xF,
        .gNetworkManagementVectorLength = 12,
@@ -77,7 +67,7 @@ static Fr_TMS570LS_ClusterConfigType Fr_cluster_config = {
        .gdMinislot = 0x4,
        .gdMinislotActionPointOffset = 0x2,
        .gdNIT = 0xAE3,
-       .gdSampleClockPeriod = 0,               // 10mbit/sec
+       .gdSampleClockPeriod = 0,       // 10mbit/sec
        .gdStaticSlot = 0x56,
        .gdTSSTransmitter = 0xA,
        .gdWakeupSymbolRxIdle = 18,
@@ -112,7 +102,7 @@ static Fr_TMS570LS_NodeConfigType Fr_node_A_config = {
        .pMicroPerCycle = 0x36B00,
        .pRateCorrectionOut = 0xCD,
        .pOffsetCorrectionOut = 0x151,
-       .pSamplesPerMicrotick = 0,              // 10 mbit/sec
+       .pSamplesPerMicrotick = 0,      // 10 mbit/sec
        .pSingleSlotEnabled = TRUE,
        .pWakeupChannel = FR_CHANNEL_A,
        .pWakeupPattern = 2,
@@ -129,32 +119,32 @@ static Fr_TMS570LS_NodeConfigType Fr_node_A_config = {
  * buffer configuration differs.
  */
 static Fr_TMS570LS_NodeConfigType Fr_node_B_config = {
-               .pAllowHaltDueToClock = 0,
-               .pAllowPassiveToActive = 0xF,
-               .pChannels = FR_CHANNEL_AB,
-               .pClusterDriftDamping = 0x1,
-               .pDelayCompensationA = 0x3,
-               .pDelayCompensationB = 0x3,
-               .pExternOffsetCorrection = 0,
-               .pExternRateCorrection = 0,
-               .pKeySlotUsedForStartup = TRUE,
-               .pKeySlotUsedForSync = TRUE,
-               .pLatestTx = 0x10D,
-               .pMacroInitialOffsetA = 0x6,
-               .pMacroInitialOffsetB = 0x6,
-               .pMicroInitialOffsetA = 0x18,
-               .pMicroInitialOffsetB = 0x18,
-               .pMicroPerCycle = 0x36B00,
-               .pRateCorrectionOut = 0xCD,
-               .pOffsetCorrectionOut = 0x151,
-               .pSamplesPerMicrotick = 0,              // 10 mbit/sec
-               .pSingleSlotEnabled = TRUE,
-               .pWakeupChannel = FR_CHANNEL_A,
-               .pWakeupPattern = 2,
-               .pdAcceptedStartupRange = 0x81,
-               .pdListenTimeout = 0x36DA2,
-               .pdMaxDrift = 0x151,
-               .pDecodingCorrection = 0x33
+       .pAllowHaltDueToClock = 0,
+       .pAllowPassiveToActive = 0xF,
+       .pChannels = FR_CHANNEL_AB,
+       .pClusterDriftDamping = 0x1,
+       .pDelayCompensationA = 0x3,
+       .pDelayCompensationB = 0x3,
+       .pExternOffsetCorrection = 0,
+       .pExternRateCorrection = 0,
+       .pKeySlotUsedForStartup = TRUE,
+       .pKeySlotUsedForSync = TRUE,
+       .pLatestTx = 0x10D,
+       .pMacroInitialOffsetA = 0x6,
+       .pMacroInitialOffsetB = 0x6,
+       .pMicroInitialOffsetA = 0x18,
+       .pMicroInitialOffsetB = 0x18,
+       .pMicroPerCycle = 0x36B00,
+       .pRateCorrectionOut = 0xCD,
+       .pOffsetCorrectionOut = 0x151,
+       .pSamplesPerMicrotick = 0,          // 10 mbit/sec
+       .pSingleSlotEnabled = TRUE,
+       .pWakeupChannel = FR_CHANNEL_A,
+       .pWakeupPattern = 2,
+       .pdAcceptedStartupRange = 0x81,
+       .pdListenTimeout = 0x36DA2,
+       .pdMaxDrift = 0x151,
+       .pDecodingCorrection = 0x33
 };
 
 static Fr_TMS570LS_MsgRAMConfig Fr_node_A_msgRAM_config = {
@@ -475,7 +465,7 @@ static Fr_TMS570LS_BufferConfigType Fr_node_B_fifo_buffers_config[] = {
                .rejectNullFrames = TRUE,
                .rejectStaticSegment = FALSE,
                .singleTransmit = FALSE,
-               .slotId = 0     // No Frame is rejected
+               .slotId = 0 // No Frame is rejected
        },
        {
                .channel = FR_CHANNEL_AB,
@@ -488,7 +478,7 @@ static Fr_TMS570LS_BufferConfigType Fr_node_B_fifo_buffers_config[] = {
                .rejectNullFrames = TRUE,
                .rejectStaticSegment = FALSE,
                .singleTransmit = FALSE,
-               .slotId = 0     // No Frame is rejected
+               .slotId = 0 // No Frame is rejected
        },
        {
                .channel = FR_CHANNEL_AB,
@@ -501,7 +491,7 @@ static Fr_TMS570LS_BufferConfigType Fr_node_B_fifo_buffers_config[] = {
                .rejectNullFrames = TRUE,
                .rejectStaticSegment = FALSE,
                .singleTransmit = FALSE,
-               .slotId = 0     // No Frame is rejected
+               .slotId = 0 // No Frame is rejected
        },
        {
                .channel = FR_CHANNEL_AB,
@@ -514,7 +504,7 @@ static Fr_TMS570LS_BufferConfigType Fr_node_B_fifo_buffers_config[] = {
                .rejectNullFrames = TRUE,
                .rejectStaticSegment = FALSE,
                .singleTransmit = FALSE,
-               .slotId = 0     // No Frame is rejected
+               .slotId = 0 // No Frame is rejected
        },
        {
                .channel = FR_CHANNEL_AB,
@@ -527,7 +517,7 @@ static Fr_TMS570LS_BufferConfigType Fr_node_B_fifo_buffers_config[] = {
                .rejectNullFrames = TRUE,
                .rejectStaticSegment = FALSE,
                .singleTransmit = FALSE,
-               .slotId = 0     // No Frame is rejected
+               .slotId = 0 // No Frame is rejected
        }
 };
 
@@ -535,7 +525,7 @@ static Fr_TMS570LS_BufferConfigType Fr_node_B_fifo_buffers_config[] = {
  * This is an unifying configuration structure for the node A.
  * It joins all the configuration structure together.
  */
-static Fr_ConfigType Fr_config_node_A= {
+static Fr_ConfigType Fr_config_node_A = {
        .clusterConfiguration = &Fr_cluster_config,
        .dynamicBufferConfigs = Fr_node_A_dynamic_buffers_config,
        .fifoBufferConfigs = Fr_node_A_fifo_buffers_config,
@@ -548,7 +538,7 @@ static Fr_ConfigType Fr_config_node_A= {
  * This is an unifying configuration structure for the node A.
  * It joins all the configuration structure together.
  */
-static Fr_ConfigType Fr_config_node_B= {
+static Fr_ConfigType Fr_config_node_B = {
        .clusterConfiguration = &Fr_cluster_config,
        .dynamicBufferConfigs = Fr_node_B_dynamic_buffers_config,
        .fifoBufferConfigs = Fr_node_B_fifo_buffers_config,
@@ -572,11 +562,12 @@ static Fr_ConfigType user_configuration = {
        .staticBufferConfigs = user_static_buffer_config,
        .dynamicBufferConfigs = user_dynamic_buffer_config,
        .fifoBufferConfigs = user_fifo_buffer_config,
-};;
+};
+;
 
-#define USER_CONFIG_NOT_DONE           0x0
-#define USER_CONFIG_CLUSTER                    0x1
-#define USER_CONFIG_NODE                       0x2
+#define USER_CONFIG_NOT_DONE        0x0
+#define USER_CONFIG_CLUSTER         0x1
+#define USER_CONFIG_NODE            0x2
 
 static uint8_t user_configuration_state = USER_CONFIG_NOT_DONE;
 static uint8_t user_static_buffer_configured = 0;
@@ -598,36 +589,33 @@ static uint8_t user_fifo_buffer_depth = 0;
  * @return SUCCESS when all parameters were converted to the array of numbers,
  *         FAILURE when the string was too short, too long or some other error occurred.
  */
-static int8_t cmd_fr_parse_params(const char* params, uint32_t params_cnt, uint32_t* tmp_params) {
+static int8_t cmd_fr_parse_params(const char *params, uint32_t params_cnt, uint32_t *tmp_params)
+{
        char cpy_params[256];
-       chartoken;
+       char *token;
        int i;
 
-       if (params == NULL || tmp_params == NULL) {
+       if (params == NULL || tmp_params == NULL)
                return FAILURE;
-       }
        strncpy(cpy_params, params, 256);
        token = strtok(cpy_params, " ");
-       if (token == NULL) {
+       if (token == NULL)
                return FAILURE;
-       }
        for (i = 0; i < params_cnt; i++) {
-               if (sscanf(token, "%i", &tmp_params[i]) == EOF) {       // No number found
+               if (sscanf(token, "%i", &tmp_params[i]) == EOF)     // No number found
                        return FAILURE;
-               }
-               if ((token = strtok(NULL, " ")) == NULL && i < params_cnt-1) {  // Not enough parameters in the string
+               if ((token = strtok(NULL, " ")) == NULL && i < params_cnt-1)    // Not enough parameters in the string
                        return FAILURE;
-               }
        }
        return SUCCESS;
 }
 
-int8_t cmd_fr_config_cluster_params(const char* params) {
+int8_t cmd_fr_config_cluster_params(const char *params)
+{
        uint32_t tmp_params[FR_CLUSTER_PARAMS_CNT];
 
-       if (cmd_fr_parse_params(params, FR_CLUSTER_PARAMS_CNT, tmp_params) == FAILURE) {
+       if (cmd_fr_parse_params(params, FR_CLUSTER_PARAMS_CNT, tmp_params) == FAILURE)
                return FAILURE;
-       }
 
        user_cluster_config.gColdStartAttempts = tmp_params[0];
        user_cluster_config.gListenNoise = tmp_params[1];
@@ -659,14 +647,14 @@ int8_t cmd_fr_config_cluster_params(const char* params) {
        return SUCCESS;
 }
 
-int8_t cmd_fr_config_node_params(const char* params) {
-       uint32_t tmp_params[FR_NODE_PARAMS_CNT+2];      // +2 because two more parameters from message RAM structure are expected in the string.
+int8_t cmd_fr_config_node_params(const char *params)
+{
+       uint32_t tmp_params[FR_NODE_PARAMS_CNT+2];  // +2 because two more parameters from message RAM structure are expected in the string.
        Fr_ChannelType channels[3] = {FR_CHANNEL_A, FR_CHANNEL_B, FR_CHANNEL_AB};
        Fr_TMS570LS_SecureBuffersType secure[4] = {FR_SB_RECONFIG_ENABLED, FR_SB_STAT_REC_DISABLED_STAT_TR_DISABLED, FR_SB_ALL_REC_DISABLED, FR_SB_ALL_REC_DISABLED_STAT_TR_DISABLED};
 
-       if (cmd_fr_parse_params(params, FR_NODE_PARAMS_CNT+2, tmp_params) == FAILURE) {
+       if (cmd_fr_parse_params(params, FR_NODE_PARAMS_CNT+2, tmp_params) == FAILURE)
                return FAILURE;
-       }
 
        user_node_config.pAllowHaltDueToClock = tmp_params[0];
        user_node_config.pAllowPassiveToActive = tmp_params[1];
@@ -704,8 +692,9 @@ int8_t cmd_fr_config_node_params(const char* params) {
        return SUCCESS;
 }
 
-int cmd_do_fr_config_fifo(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
-       Fr_TMS570LS_BufferConfigType* fifo_buffer_ptr = &user_fifo_buffer_config[0];
+int cmd_do_fr_config_fifo(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
+       Fr_TMS570LS_BufferConfigType *fifo_buffer_ptr = &user_fifo_buffer_config[0];
        int ret, i;
        char channel[3], rej_static_frames[8], rej_null_frames[8];
        unsigned depth, slot, cycleset, maxpayload, mask;
@@ -717,15 +706,15 @@ int cmd_do_fr_config_fifo(cmd_io_t *cmd_io, const struct cmd_des *des, char *par
        }
 
        ret = sscanf(param[2], "rejslot%i slotmask%i depth%i %2s cyc%i max%i %10s %10s",
-                    &slot,
-                    &mask,
-                    &depth,
-                    channel,
-                    &cycleset,
-                    &maxpayload,
-                    rej_null_frames,
-                    rej_static_frames
-                    );
+                                &slot,
+                                &mask,
+                                &depth,
+                                channel,
+                                &cycleset,
+                                &maxpayload,
+                                rej_null_frames,
+                                rej_static_frames
+                                );
        if (ret != 8) {
                printf("Error parsing parameter %d\n", ret+1);
                return -CMDERR_BADPAR;
@@ -745,7 +734,7 @@ int cmd_do_fr_config_fifo(cmd_io_t *cmd_io, const struct cmd_des *des, char *par
        else if (strcmp(channel, "B") == 0) tmp_buffer.channel = FR_CHANNEL_B;
        else if (strcmp(channel, "AB") == 0) tmp_buffer.channel = FR_CHANNEL_AB;
        else return badpar("Channel parsing error\n");
-       
+
        if (cycleset >= 0x80)
                return badpar("Cycle set must be less than 0x80.\n");
        tmp_buffer.cycleCounterFiltering = cycleset;
@@ -753,7 +742,7 @@ int cmd_do_fr_config_fifo(cmd_io_t *cmd_io, const struct cmd_des *des, char *par
        if (maxpayload >= 128)
                return badpar("Maximum payload in half-words must be less than 128\n");
        tmp_buffer.maxPayload = maxpayload;
-       
+
        if (strcmp(rej_null_frames, "rejnull") == 0) tmp_buffer.rejectNullFrames = true;
        else if (strcmp(rej_null_frames, "accnull") == 0) tmp_buffer.rejectNullFrames = false;
        else return badpar("Reject/accept NULL frames parsing error\n");
@@ -765,10 +754,10 @@ int cmd_do_fr_config_fifo(cmd_io_t *cmd_io, const struct cmd_des *des, char *par
        else return badpar("Invalid reject/accept static frame parameter");
 
        for (i = 0; i < user_fifo_buffer_depth; i++) {
-               fifo_buffer_ptr[i].slotId = tmp_buffer.slotId;  
+               fifo_buffer_ptr[i].slotId = tmp_buffer.slotId;
                fifo_buffer_ptr[i].fidMask = tmp_buffer.fidMask;
                fifo_buffer_ptr[i].maxPayload = tmp_buffer.maxPayload;
-               fifo_buffer_ptr[i].channel= tmp_buffer.channel;
+               fifo_buffer_ptr[i].channel = tmp_buffer.channel;
                fifo_buffer_ptr[i].cycleCounterFiltering = tmp_buffer.cycleCounterFiltering;
                fifo_buffer_ptr[i].isTx = FALSE;
                fifo_buffer_ptr[i].singleTransmit = FALSE;
@@ -779,16 +768,16 @@ int cmd_do_fr_config_fifo(cmd_io_t *cmd_io, const struct cmd_des *des, char *par
        }
 
        printf("frbtcfgfifo rejslot%i slotmask%i depth%i %2s cyc%i max%i %10s %10s\n",
-                    slot,
-                    mask,
-                    depth,
-                    channel,
-                    cycleset,
-                    maxpayload,
-                    rej_null_frames,
-                    rej_static_frames
-               );
-       
+                  slot,
+                  mask,
+                  depth,
+                  channel,
+                  cycleset,
+                  maxpayload,
+                  rej_null_frames,
+                  rej_static_frames
+                  );
+
        return SUCCESS;
 }
 
@@ -799,30 +788,30 @@ int cmd_do_fr_config_bufer(cmd_io_t *cmd_io, const struct cmd_des *des, char *pa
        int ret;
        char buf_type, channel[3],rxtx[3], single_continuous[11];
        unsigned buffer, slot, cycleset, maxpayload, intr, preamb;
-       
+
        if (fr_initialized) {
                rpp_sci_printf("FlexRay configuration can not be modified after frbtinit was called.\n");
                return -CMDERR_BADCFG;
        }
 
        ret = sscanf(param[1], "%c%i slot%i %2s cyc%i %2s max%i %10s ppi%i int%i",
-                    &buf_type,
-                    &buffer,
-                    &slot,
-                    channel,
-                    &cycleset,
-                    rxtx,
-                    &maxpayload,
-                    single_continuous,
-                    &preamb,
-                    &intr
-                    );
+                                &buf_type,
+                                &buffer,
+                                &slot,
+                                channel,
+                                &cycleset,
+                                rxtx,
+                                &maxpayload,
+                                single_continuous,
+                                &preamb,
+                                &intr
+                                );
        if (ret != 10) {
                printf("Error parsing parameter %d\n", ret+1);
                return -CMDERR_BADPAR;
-       
+
        }
-       
+
        switch (buf_type) {
        case 'S':
                if (buffer >= RPP_FR_MAX_STATIC_BUF_CNT)
@@ -862,10 +851,10 @@ int cmd_do_fr_config_bufer(cmd_io_t *cmd_io, const struct cmd_des *des, char *pa
        cfg->maxPayload = maxpayload;
 
        if (0 == strcmp(single_continuous, "single") ||
-           0 == strcmp(single_continuous, "s"))
+               0 == strcmp(single_continuous, "s"))
                cfg->singleTransmit = true;
        else if (0 == strcmp(single_continuous, "continuous") ||
-           0 == strcmp(single_continuous, "c"))
+                        0 == strcmp(single_continuous, "c"))
                cfg->singleTransmit = false;
        else return badpar("Invalid single/continuous parameter");
 
@@ -889,17 +878,17 @@ int cmd_do_fr_config_bufer(cmd_io_t *cmd_io, const struct cmd_des *des, char *pa
        }
 
        printf("frbtcfgbuf%c%i slot%i %2s cyc%i %2s max%i %10s ppi%i int%i\n",
-                    buf_type,
-                    buffer,
-                    slot,
-                    channel,
-                    cycleset,
-                    rxtx,
-                    maxpayload,
-                    single_continuous,
-                    preamb,
-                    intr
-               );
+                  buf_type,
+                  buffer,
+                  slot,
+                  channel,
+                  cycleset,
+                  rxtx,
+                  maxpayload,
+                  single_continuous,
+                  preamb,
+                  intr
+                  );
 
        return 0;
 }
@@ -907,15 +896,16 @@ int cmd_do_fr_config_bufer(cmd_io_t *cmd_io, const struct cmd_des *des, char *pa
 
 
 /**
- *     @brief  Do the user configuration of the FlexRay cluster parameters
+ *  @brief     Do the user configuration of the FlexRay cluster parameters
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_user_config(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
-       char* token;
+int cmd_do_fr_user_config(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
+       char *token;
 
        if (fr_initialized) {
                rpp_sci_printf("FlexRay configuration can not be modified after frbtinit was called.\n");
@@ -937,41 +927,38 @@ int cmd_do_fr_user_config(cmd_io_t *cmd_io, const struct cmd_des *des, char *par
                }
                rpp_sci_printf("FlexRay node configuration accepted.\n");
        }
-       else {
+       else
                return -CMDERR_BADPAR;
-       }
 
        return 0;
 }
 
 /**
- *     @brief  Initialize the device as FlexRay node.
+ *  @brief     Initialize the device as FlexRay node.
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_init(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
-       const Fr_ConfigType* Fr_ConfigPtr = NULL;
+int cmd_do_fr_init(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
+       const Fr_ConfigType *Fr_ConfigPtr = NULL;
        int8_t retVal = SUCCESS;
        uint32_t error = ERR_PARAM_NO_ERROR;
 
-       if (*param[1] == 'A') {
+       if (*param[1] == 'A')
                Fr_ConfigPtr = &Fr_config_node_A;
-       }
-       else if (*param[1] == 'B') {
+       else if (*param[1] == 'B')
                Fr_ConfigPtr = &Fr_config_node_B;
-       }
-       else if (*param[1] == 'U') {    // Select the user configuration  -  call config commands first
+       else if (*param[1] == 'U') {    // Select the user configuration  -  call config commands first
                user_msg_ram_config.statSegmentBufferCount = user_static_buffer_configured;
                user_msg_ram_config.dynSegmentBufferCount = user_dynamic_buffer_configured;
-               user_msg_ram_config.fifoBufferCount= user_fifo_buffer_depth;
+               user_msg_ram_config.fifoBufferCount = user_fifo_buffer_depth;
                Fr_ConfigPtr = &user_configuration;
        }
-       else {
+       else
                return -CMDERR_BADPAR;
-       }
 
        retVal = rpp_fr_init_driver(Fr_ConfigPtr, &error);
        if (retVal == SUCCESS) {
@@ -991,84 +978,73 @@ int cmd_do_fr_init(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
        }
 
        retVal = rpp_fr_init_controller(0, &error);
-       if (retVal == SUCCESS) {
+       if (retVal == SUCCESS)
                rpp_sci_printf("FlexRay controller initialized.\r\n");
-       }
        else {
-               if (error & FR_INIT_ERR_CLUSTER_CONFIG) {
+               if (error & FR_INIT_ERR_CLUSTER_CONFIG)
                        rpp_sci_printf("Cluster configuration data error: %x\r\n", (retVal & 0x3FFFFFE) >> 1 );
-               }
-               else if (error & FR_INIT_ERR_NODE_CONFIG) {
+               else if (error & FR_INIT_ERR_NODE_CONFIG)
                        rpp_sci_printf("Node configuration data error: %x\r\n", (retVal & 0x3FFFFFE) >> 1 );
-               }
-               else if (error & FR_INIT_ERR_MSGRAM_CONFIG) {
+               else if (error & FR_INIT_ERR_MSGRAM_CONFIG)
                        rpp_sci_printf("Message RAM configuration data error: %x\r\n", (retVal & 0x3FFFFFE) >> 1 );
-               }
-               else if (error & FR_INIT_ERR_BUFFPARAM_CONFIG) {
+               else if (error & FR_INIT_ERR_BUFFPARAM_CONFIG)
                        rpp_sci_printf("Buffer configuration data error: %x\r\n", (retVal & 0x3FFFFFE) >> 1 );
-               }
-               else if (error & (uint32_t)FR_INIT_ERR_BUFF_CONFIG) {
+               else if (error & (uint32_t)FR_INIT_ERR_BUFF_CONFIG)
                        rpp_sci_printf("Buffer configuration error: %x\r\n", (retVal & 0x3FFFFFE) >> 1 );
-               }
-               else {
+               else
                        rpp_sci_printf("POC state switching error.\r\n");
-               }
                return -CMDERR_BADCFG;
        }
        return 0;
 }
 
 /**
- *     @brief  Starts FlexRay communication
+ *  @brief     Starts FlexRay communication
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_start(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_start(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = SUCCESS;
        uint32_t error = ERR_PARAM_NO_ERROR;
 
        retVal = rpp_fr_start_communication(0, &error);
-       if (retVal == SUCCESS) {
+       if (retVal == SUCCESS)
                rpp_sci_printf("FlexRay communication is running.\r\n");
-       }
        else {
-               if (error & FR_STARTUP_ERR_SW_STUP_FOLLOW) {
+               if (error & FR_STARTUP_ERR_SW_STUP_FOLLOW)
                        rpp_sci_printf("Can not switch POC to RUN state.\r\n");
-               }
-               else if (error & FR_STARTUP_ERR_CSINH_DIS) {
+               else if (error & FR_STARTUP_ERR_CSINH_DIS)
                        rpp_sci_printf("Cold start inhibit disabled error.\r\n");
-               }
-               else if (error & FR_STARTUP_ERR_SW_STUP_READY) {
+               else if (error & FR_STARTUP_ERR_SW_STUP_READY)
                        rpp_sci_printf("Can not switch back to READY from STARTUP.\r\n");
-               }
-               else if (error & FR_STARTUP_ERR_SW_STUP_AS_NCOLD) {
+               else if (error & FR_STARTUP_ERR_SW_STUP_AS_NCOLD)
                        rpp_sci_printf("Can not switch to STARTUP as non-coldstarter.\r\n");
-               }
-               else {
+               else
                        rpp_sci_printf("General error.\r\n");
-               }
                return -CMDERR_BADCFG;
        }
        return 0;
 }
 
 /**
- *     @brief  Invokes POC command ALL_SLOTS
+ *  @brief     Invokes POC command ALL_SLOTS
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_allslots(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_allslots(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
+
        retVal = rpp_fr_all_slots(0);
-       if (retVal == SUCCESS) {
+       if (retVal == SUCCESS)
                rpp_sci_printf("FlexRay node started communication in all slots.\r\n");
-       }
        else {
                rpp_sci_printf("General error.\r\n");
                return -CMDERR_BADCFG;
@@ -1077,19 +1053,20 @@ int cmd_do_fr_allslots(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[
 }
 
 /**
- *     @brief  Halt FlexRay communication
+ *  @brief     Halt FlexRay communication
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_halt(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_halt(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
+
        retVal = rpp_fr_halt_communication(0);
-       if (retVal == SUCCESS) {
+       if (retVal == SUCCESS)
                rpp_sci_printf("FlexRay node communication halted.\r\n");
-       }
        else {
                rpp_sci_printf("General error.\r\n");
                return -CMDERR_BADCFG;
@@ -1098,19 +1075,20 @@ int cmd_do_fr_halt(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
 }
 
 /**
- *     @brief  Abort FlexRay communication
+ *  @brief     Abort FlexRay communication
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_abort(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_abort(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
+
        retVal = rpp_fr_abort_communication(0);
-       if (retVal == SUCCESS) {
+       if (retVal == SUCCESS)
                rpp_sci_printf("FlexRay node communication aborted.\r\n");
-       }
        else {
                rpp_sci_printf("General error.\r\n");
                return -CMDERR_BADCFG;
@@ -1119,19 +1097,20 @@ int cmd_do_fr_abort(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
 }
 
 /**
- *     @brief  Send wake up pattern
+ *  @brief     Send wake up pattern
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_sendwup(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_sendwup(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
+
        retVal = rpp_fr_send_wup(0);
-       if (retVal == SUCCESS) {
+       if (retVal == SUCCESS)
                rpp_sci_printf("Wake up pattern has been sent.\r\n");
-       }
        else {
                rpp_sci_printf("General error.\r\n");
                return -CMDERR_BADCFG;
@@ -1140,30 +1119,27 @@ int cmd_do_fr_sendwup(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]
 }
 
 /**
- *     @brief  Set channel for wake up pattern sending.
+ *  @brief     Set channel for wake up pattern sending.
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_setwuchannel(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_setwuchannel(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
        Fr_ChannelType channel = FR_CHANNEL_A;
 
-       if (*param[1] == 'A') {
+       if (*param[1] == 'A')
                channel = FR_CHANNEL_A;
-       }
-       else if (*param[1] == 'B') {
+       else if (*param[1] == 'B')
                channel = FR_CHANNEL_B;
-       }
-       else {
+       else
                return -CMDERR_BADPAR;
-       }
        retVal = rpp_fr_set_wu_channel(0, channel);
-       if (retVal == SUCCESS) {
+       if (retVal == SUCCESS)
                rpp_sci_printf("Wake up channel has been set.\r\n");
-       }
        else {
                rpp_sci_printf("General error.\r\n");
                return -CMDERR_BADCFG;
@@ -1172,32 +1148,33 @@ int cmd_do_fr_setwuchannel(cmd_io_t *cmd_io, const struct cmd_des *des, char *pa
 }
 
 /**
- *     @brief  Get and print POC status of the FlexRay controller.
+ *  @brief     Get and print POC status of the FlexRay controller.
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_getpocstatus(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_getpocstatus(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
        Fr_POCStatusType status;
-       charErrorModeStrings[] = {"ACTIVE", "HALT", "PASSIVE"};
-       charSlotModeStrings[]  = {"KEYSLOT", "ALL_PENDING", "ALL"};
-       charStartupStateStrings[]  = {
-                       "UNDEFINED", "COLDSTART_LISTEN", "COLDSTART_CHECK", "COLDSTART_JOIN",
-                       "COLDSTART_CONSISTENCY_CHECK", "INTEGRATION_LISTEN", "INITIALIZE_SCHEDULE", "INTEGRATION_CONSISTENCY_CHECK",
-                       "COLDSTART_GAP", "EXTERNAL_STARTUP", "ABORT", "COLDSTART_COLLISION_RESOLUTION",
-                       "PREPARE"
+       char *ErrorModeStrings[] = {"ACTIVE", "HALT", "PASSIVE"};
+       char *SlotModeStrings[]  = {"KEYSLOT", "ALL_PENDING", "ALL"};
+       char *StartupStateStrings[]  = {
+               "UNDEFINED", "COLDSTART_LISTEN", "COLDSTART_CHECK", "COLDSTART_JOIN",
+               "COLDSTART_CONSISTENCY_CHECK", "INTEGRATION_LISTEN", "INITIALIZE_SCHEDULE", "INTEGRATION_CONSISTENCY_CHECK",
+               "COLDSTART_GAP", "EXTERNAL_STARTUP", "ABORT", "COLDSTART_COLLISION_RESOLUTION",
+               "PREPARE"
        };
-       charStateStrings[]  = {
-                       "CONFIG", "DEFAULT_CONFIG", "HALT", "NORMAL_ACTIVE",
-                       "NORMAL_PASSIVE", "READY", "STARTUP", "LOOPBACK",
-                       "MONITOR", "WAKEUP"
+       char *StateStrings[]  = {
+               "CONFIG", "DEFAULT_CONFIG", "HALT", "NORMAL_ACTIVE",
+               "NORMAL_PASSIVE", "READY", "STARTUP", "LOOPBACK",
+               "MONITOR", "WAKEUP"
        };
-       charWakeupStatusStrings[]  = {
-                       "UNDEFINED", "RECEIVED_HEADER", "RECEIVED_WUP", "COLLISION_HEADER",
-                       "COLLISION_WUP", "COLLISION_UNKNOWN", "TRANSMITTED"
+       char *WakeupStatusStrings[]  = {
+               "UNDEFINED", "RECEIVED_HEADER", "RECEIVED_WUP", "COLLISION_HEADER",
+               "COLLISION_WUP", "COLLISION_UNKNOWN", "TRANSMITTED"
        };
 
        retVal = rpp_fr_get_poc_status(0, &status);
@@ -1221,44 +1198,41 @@ int cmd_do_fr_getpocstatus(cmd_io_t *cmd_io, const struct cmd_des *des, char *pa
 }
 
 /**
- *     @brief  Send given data through the FlexRay in selected slot.
+ *  @brief     Send given data through the FlexRay in selected slot.
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_transmittxlpdu(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_transmittxlpdu(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
-       uint32_t slotID;
+       uint32_t bufferID;
        uint8_t dataLength;
        int values[MAX_PARAM_VALUES_NUM];
        uint8_t data[MAX_PARAM_VALUES_NUM];
-       chartoken = NULL;
+       char *token = NULL;
 
-       if (sscanf(param[1], "%d", &slotID) != 1) {
+       if (sscanf(param[1], "%d", &bufferID) != 1)
                return -CMDERR_BADPAR;
-       }
-       if (sscanf(param[2], " %2x", &values[0]) != 1) {
+       if (sscanf(param[2], " %2x", &values[0]) != 1)
                return -CMDERR_BADPAR;
-       }
        data[0] = (uint8_t)values[0];
        token = strtok(param[2], " ");
        token = strtok(NULL, " ");
        dataLength = 1;
        while (dataLength < MAX_PARAM_VALUES_NUM && token != NULL) {
-               if (sscanf(token, "%2x", &values[dataLength]) == EOF) {
+               if (sscanf(token, "%2x", &values[dataLength]) == EOF)
                        break;
-               }
                data[dataLength] = (uint8_t)values[dataLength];
                token = strtok(NULL, " ");
                dataLength++;
        }
 
-       retVal = rpp_fr_transmit_lpdu(0, slotID, data, dataLength);
-       if (retVal == SUCCESS) {
+       retVal = rpp_fr_transmit_lpdu(0, bufferID, data, dataLength);
+       if (retVal == SUCCESS)
                rpp_sci_printf("Data were set for transmission.\r\n");
-       }
        else {
                rpp_sci_printf("General error.\r\n");
                return -CMDERR_BADCFG;
@@ -1267,28 +1241,26 @@ int cmd_do_fr_transmittxlpdu(cmd_io_t *cmd_io, const struct cmd_des *des, char *
 }
 
 /**
- *     @brief  Cancel the transmission in the selected slot.
+ *  @brief     Cancel the transmission in the selected slot.
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_canceltxlpdu(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_canceltxlpdu(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
-       uint32_t slotID;
+       uint32_t bufferID;
 
-       if (sscanf(param[1], "%d", &slotID) != 1) {
+       if (sscanf(param[1], "%d", &bufferID) != 1)
                return -CMDERR_BADPAR;
-       }
-       if (param[2] != NULL) {
+       if (param[2] != NULL)
                return -CMDERR_BADPAR;
-       }
 
-       retVal = rpp_fr_cancel_transmit_lpdu(0, slotID);
-       if (retVal == SUCCESS) {
+       retVal = rpp_fr_cancel_transmit_lpdu(0, bufferID);
+       if (retVal == SUCCESS)
                rpp_sci_printf("Transmission canceled.\r\n");
-       }
        else {
                rpp_sci_printf("General error.\r\n");
                return -CMDERR_BADCFG;
@@ -1297,31 +1269,30 @@ int cmd_do_fr_canceltxlpdu(cmd_io_t *cmd_io, const struct cmd_des *des, char *pa
 }
 
 /**
- *     @brief  Receive data from selected slot.
+ *  @brief     Receive data from selected slot.
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_receiverxlpdu(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_receiverxlpdu(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
-       uint32_t slotID;
+       uint32_t bufferID;
        uint8_t data[cPayloadLengthMax];
        Fr_RxLPduStatusType status;
        uint8_t receivedLength = 0;
        uint8_t i;
 
-       if (sscanf(param[1], "%d", &slotID) != 1) {
+       if (sscanf(param[1], "%d", &bufferID) != 1)
                return -CMDERR_BADPAR;
-       }
-       if (param[2] != NULL) {
+       if (param[2] != NULL)
                return -CMDERR_BADPAR;
-       }
 
        memset(data, 0, sizeof(data));
 
-       retVal = rpp_fr_receive_lpdu(0, slotID, data, &status, &receivedLength);
+       retVal = rpp_fr_receive_lpdu(0, bufferID, data, &status, &receivedLength);
        if (retVal == SUCCESS) {
                switch (status) {
                case FR_RECEIVED_MORE_DATA_AVAILABLE:
@@ -1346,30 +1317,28 @@ int cmd_do_fr_receiverxlpdu(cmd_io_t *cmd_io, const struct cmd_des *des, char *p
 }
 
 /**
- *     @brief  Returns TX LPdu status.
+ *  @brief     Returns TX LPdu status.
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_checktxlpdustatus(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_checktxlpdustatus(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
-       uint32_t slotID;
+       uint32_t bufferID;
        Fr_TxLPduStatusType status;
-       charstatusStrings[] = {"is not", "is"};
+       char *statusStrings[] = {"is not", "is"};
 
-       if (sscanf(param[1], "%d", &slotID) != 1) {
+       if (sscanf(param[1], "%d", &bufferID) != 1)
                return -CMDERR_BADPAR;
-       }
-       if (param[2] != NULL) {
+       if (param[2] != NULL)
                return -CMDERR_BADPAR;
-       }
 
-       retVal = rpp_fr_check_tx_lpdu_status(0, slotID, &status);
-       if (retVal == SUCCESS) {
+       retVal = rpp_fr_check_tx_lpdu_status(0, bufferID, &status);
+       if (retVal == SUCCESS)
                rpp_sci_printf("Message transmission %s pending.\r\n", statusStrings[status]);
-       }
        else {
                rpp_sci_printf("General error.\r\n");
                return -CMDERR_BADCFG;
@@ -1378,28 +1347,26 @@ int cmd_do_fr_checktxlpdustatus(cmd_io_t *cmd_io, const struct cmd_des *des, cha
 }
 
 /**
- *     @brief  Disable buffer.
+ *  @brief     Disable buffer.
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_disablelpdu(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_disablelpdu(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
-       uint32_t slotID;
+       uint32_t bufferID;
 
-       if (sscanf(param[1], "%d", &slotID) != 1) {
+       if (sscanf(param[1], "%d", &bufferID) != 1)
                return -CMDERR_BADPAR;
-       }
-       if (param[2] != NULL) {
+       if (param[2] != NULL)
                return -CMDERR_BADPAR;
-       }
 
-       retVal = rpp_fr_disable_lpdu(0, slotID);
-       if (retVal == SUCCESS) {
+       retVal = rpp_fr_disable_lpdu(0, bufferID);
+       if (retVal == SUCCESS)
                rpp_sci_printf("Buffer disabled.\r\n");
-       }
        else {
                rpp_sci_printf("General error.\r\n");
                return -CMDERR_BADCFG;
@@ -1408,22 +1375,22 @@ int cmd_do_fr_disablelpdu(cmd_io_t *cmd_io, const struct cmd_des *des, char *par
 }
 
 /**
- *     @brief  Print global time of the FlexRay network.
+ *  @brief     Print global time of the FlexRay network.
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_getglobaltime(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_getglobaltime(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
        uint8_t cycle = 0;
        uint16_t macroTick = 0;
 
        retVal = rpp_fr_get_global_time(0, &cycle, &macroTick);
-       if (retVal == SUCCESS) {
+       if (retVal == SUCCESS)
                rpp_sci_printf("Cycle number: %d\r\nMacrotick number: %d\r\n", cycle, macroTick);
-       }
        else {
                rpp_sci_printf("General error.\r\n");
                return -CMDERR_BADCFG;
@@ -1432,14 +1399,15 @@ int cmd_do_fr_getglobaltime(cmd_io_t *cmd_io, const struct cmd_des *des, char *p
 }
 
 /**
- *     @brief  Print network management vector of the FlexRay node.
+ *  @brief     Print network management vector of the FlexRay node.
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_getnmvector(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_getnmvector(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
        uint8_t nmVector[12];
        uint8_t i;
@@ -1459,7 +1427,8 @@ int cmd_do_fr_getnmvector(cmd_io_t *cmd_io, const struct cmd_des *des, char *par
        return 0;
 }
 
-int cmd_do_fr_nmwatch(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_nmwatch(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
        uint8_t nmVector[12];
        uint8_t i;
@@ -1468,7 +1437,7 @@ int cmd_do_fr_nmwatch(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]
        static const portTickType freq_ticks = 100 /* ms */ / portTICK_RATE_MS;
        portTickType last_wake_time = xTaskGetTickCount();
 
-       while(cmd_io->getc(cmd_io) < 0) {
+       while (cmd_io->getc(cmd_io) < 0) {
                retVal = rpp_fr_get_network_management_vector(0, nmVector);
                if (retVal == SUCCESS) {
                        rpp_sci_printf("Network management vector:");
@@ -1488,48 +1457,48 @@ int cmd_do_fr_nmwatch(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]
 }
 
 /**
- *     @brief  Print both channels status of the FlexRay node.
+ *  @brief     Print both channels status of the FlexRay node.
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_getchannelstatus(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_getchannelstatus(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
        uint8_t index;
        uint8_t channel;
-       chardecodeStrings[] = {
-                       "aggregated channel status vSS!ValidFrame",
-                       "aggregated channel status vSS!SyntaxError",
-                       "aggregated channel status vSS!ContentError",
-                       "aggregated channel status additional communication",
-                       "aggregated channel status vSS!Bviolation",
-                       "aggregated channel status vSS!TxConflict",
-                       "Not used (0)",
-                       "Not used (0)",
-                       "symbol window status data vSS!ValidMTS",
-                       "symbol window status data vSS!SyntaxError",
-                       "symbol window status data vSS!Bviolation",
-                       "symbol window status data vSS!TxConflict",
-                       "NIT status data vSS!SyntaxError",
-                       "NIT status data vSS!Bviolation",
-                       "Not used (0)",
-                       "Not used (0)"
+       char *decodeStrings[] = {
+               "aggregated channel status vSS!ValidFrame",
+               "aggregated channel status vSS!SyntaxError",
+               "aggregated channel status vSS!ContentError",
+               "aggregated channel status additional communication",
+               "aggregated channel status vSS!Bviolation",
+               "aggregated channel status vSS!TxConflict",
+               "Not used (0)",
+               "Not used (0)",
+               "symbol window status data vSS!ValidMTS",
+               "symbol window status data vSS!SyntaxError",
+               "symbol window status data vSS!Bviolation",
+               "symbol window status data vSS!TxConflict",
+               "NIT status data vSS!SyntaxError",
+               "NIT status data vSS!Bviolation",
+               "Not used (0)",
+               "Not used (0)"
        };
-       charchannelNames[] = {"A", "B"};
-       charboolStrings[] = {"FALSE", "TRUE"};
+       char *channelNames[] = {"A", "B"};
+       char *boolStrings[] = {"FALSE", "TRUE"};
        uint16_t channelStatuses[2];
 
        retVal = rpp_fr_get_channel_status(0, &channelStatuses[0], &channelStatuses[1]);
-       if (retVal == SUCCESS) {
+       if (retVal == SUCCESS)
                for (channel = 0; channel < 2; channel++) {
                        rpp_sci_printf("Channel %s status:\r\n", channelNames[channel]);
                        for (index = 0; index < 16; index++) {
                                rpp_sci_printf("\t%s: %s\r\n", decodeStrings[index], boolStrings[ (channelStatuses[channel] >> index) & 0x1 ] );
                        }
                }
-       }
        else {
                rpp_sci_printf("General error.\r\n");
                return -CMDERR_BADCFG;
@@ -1538,22 +1507,22 @@ int cmd_do_fr_getchannelstatus(cmd_io_t *cmd_io, const struct cmd_des *des, char
 }
 
 /**
- *     @brief  Print clock correction of the FlexRay node
+ *  @brief     Print clock correction of the FlexRay node
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_getclockcorrection(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_getclockcorrection(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
        int16_t rateCorrection;
        int32_t offsetCorrection;
 
        retVal = rpp_fr_get_clock_correction(0, &rateCorrection, &offsetCorrection);
-       if (retVal == SUCCESS) {
+       if (retVal == SUCCESS)
                rpp_sci_printf("Rate correction: %d\r\nOffset correction: %d\r\n", rateCorrection, offsetCorrection);
-       }
        else {
                rpp_sci_printf("General error.\r\n");
                return -CMDERR_BADCFG;
@@ -1562,14 +1531,15 @@ int cmd_do_fr_getclockcorrection(cmd_io_t *cmd_io, const struct cmd_des *des, ch
 }
 
 /**
- *     @brief  Print list of syncframec transmitted on both channels via the even and odd cycle.
+ *  @brief     Print list of syncframec transmitted on both channels via the even and odd cycle.
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_getsyncframelist(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_getsyncframelist(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
        uint16_t channelAEvenList[FR_MAX_SYNC_FRAME_LIST_SIZE];
        uint16_t channelBEvenList[FR_MAX_SYNC_FRAME_LIST_SIZE];
@@ -1578,15 +1548,12 @@ int cmd_do_fr_getsyncframelist(cmd_io_t *cmd_io, const struct cmd_des *des, char
        uint32_t listSize = 0;
        uint8_t i;
 
-       if (sscanf(param[1], "%d", &listSize) != 1) {
+       if (sscanf(param[1], "%d", &listSize) != 1)
                return -CMDERR_BADPAR;
-       }
-       if (param[2] != NULL) {
+       if (param[2] != NULL)
                return -CMDERR_BADPAR;
-       }
-       if (listSize > FR_MAX_SYNC_FRAME_LIST_SIZE) {
+       if (listSize > FR_MAX_SYNC_FRAME_LIST_SIZE)
                return -CMDERR_BADPAR;
-       }
 
        retVal = rpp_fr_get_sync_frame_list(0, listSize, channelAEvenList, channelBEvenList, channelAOddList, channelBOddList);
        if (retVal == SUCCESS) {
@@ -1606,26 +1573,26 @@ int cmd_do_fr_getsyncframelist(cmd_io_t *cmd_io, const struct cmd_des *des, char
 }
 
 /**
- *     @brief  Print status of wakeup on each channels (wakeup received on channel or not yet received).
+ *  @brief     Print status of wakeup on each channels (wakeup received on channel or not yet received).
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_getwakeuprxstatus(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_getwakeuprxstatus(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
        uint8_t status = 0;
-       charstatusStrings[] = {"was not yet", "was"};
-       charchannelNames[] = {"A", "B"};
+       char *statusStrings[] = {"was not yet", "was"};
+       char *channelNames[] = {"A", "B"};
        uint8_t i;
 
        retVal = rpp_fr_get_wakeup_rx_status(0, &status);
-       if (retVal == SUCCESS) {
+       if (retVal == SUCCESS)
                for (i = 0; i < 2; i++) {
                        rpp_sci_printf("Wake up pattern %s received on channel %s.\r\n", statusStrings[(status >> i) & 0x1], channelNames[i]);
                }
-       }
        else {
                rpp_sci_printf("General error.\r\n");
                return -CMDERR_BADCFG;
@@ -1634,22 +1601,22 @@ int cmd_do_fr_getwakeuprxstatus(cmd_io_t *cmd_io, const struct cmd_des *des, cha
 }
 
 /**
- *     @brief  Set and start absolute timer.
+ *  @brief     Set and start absolute timer.
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_settimer(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_settimer(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
        int timer = 0;
        int cycle = 0;
        int offset = 0;
 
-       if (sscanf(param[1], "%i %i %i", &timer, &cycle, &offset) != 3) {
+       if (sscanf(param[1], "%i %i %i", &timer, &cycle, &offset) != 3)
                return -CMDERR_BADPAR;
-       }
 
        retVal = rpp_fr_set_timer(0, timer, cycle, offset);
        if (retVal == SUCCESS) {
@@ -1660,7 +1627,7 @@ int cmd_do_fr_settimer(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[
                        i = 1;
 
                rpp_sci_printf("Timer was set for every %d-th cycle, offset %d, macrotick %d\n",
-                              i, cycle & ~i, offset);
+                                          i, cycle & ~i, offset);
        }
        else {
                rpp_sci_printf("General error.\r\n");
@@ -1670,29 +1637,27 @@ int cmd_do_fr_settimer(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[
 }
 
 /**
- *     @brief  Cancel selected timer
+ *  @brief     Cancel selected timer
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_canceltimer(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_canceltimer(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
        int timer = 0;
 
-       if (sscanf(param[1], "%d", &timer) != 1) {
+       if (sscanf(param[1], "%d", &timer) != 1)
                return -CMDERR_BADPAR;
-       }
 
-       if (param[2] != NULL) {
+       if (param[2] != NULL)
                return -CMDERR_BADPAR;
-       }
 
        retVal = rpp_fr_cancel_timer(0, timer);
-       if (retVal == SUCCESS) {
+       if (retVal == SUCCESS)
                rpp_sci_printf("Timer was canceled.\r\n");
-       }
        else {
                rpp_sci_printf("General error.\r\n");
                return -CMDERR_BADCFG;
@@ -1701,55 +1666,48 @@ int cmd_do_fr_canceltimer(cmd_io_t *cmd_io, const struct cmd_des *des, char *par
 }
 
 /**
- *     @brief  Enable/disable, acknowledge, get timer IRQ
+ *  @brief     Enable/disable, acknowledge, get timer IRQ
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_timerirq(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_timerirq(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
        int timer = 0;
        char str[4];
        boolean_t status = FALSE;
-       charboolStrings[] = {"FALSE", "TRUE"};
+       char *boolStrings[] = {"FALSE", "TRUE"};
 
 
-       if (sscanf(param[1], "%d", &timer) != 1) {
+       if (sscanf(param[1], "%d", &timer) != 1)
                return -CMDERR_BADPAR;
-       }
 
-       if (param[2] == NULL) {         // Get timer IRQ
+       if (param[2] == NULL) {     // Get timer IRQ
                retVal = rpp_fr_get_timer_irq_status(0, timer, &status);
-               if (retVal == SUCCESS) {
+               if (retVal == SUCCESS)
                        rpp_sci_printf("IRQ = %s\r\n", boolStrings[status]);
-               }
                else {
                        rpp_sci_printf("General error.\r\n");
                        return -CMDERR_BADCFG;
                }
        }
-       else {  // Some set action
-               if (sscanf(param[2], "%4s", str) != 1) {
+       else {  // Some set action
+               if (sscanf(param[2], "%4s", str) != 1)
                        return -CMDERR_BADPAR;
-               }
-               if (strcmp(str, "EN") == 0) { // Enable IRQ
-                       retVal = SUCCESS;       // No interrupts imlemented
-               }
-               else if (strcmp(str, "DIS") == 0) { // Disable IRQ
-                       retVal = SUCCESS;       // No interrupts implemented
-               }
-               else if  (strcmp(str, "ACK") == 0) { // Clear IRQ
+               if (strcmp(str, "EN") == 0)   // Enable IRQ
+                       retVal = SUCCESS;   // No interrupts imlemented
+               else if (strcmp(str, "DIS") == 0)   // Disable IRQ
+                       retVal = SUCCESS;   // No interrupts implemented
+               else if  (strcmp(str, "ACK") == 0)   // Clear IRQ
                        retVal = rpp_fr_clear_timer_irq(0, timer);
-               }
-               else {  // Bad argument
+               else    // Bad argument
                        return -CMDERR_BADPAR;
-               }
 
-               if (retVal == SUCCESS) {
+               if (retVal == SUCCESS)
                        rpp_sci_printf("OK\r\n");
-               }
                else {
                        rpp_sci_printf("General error.\r\n");
                        return -CMDERR_BADCFG;
@@ -1759,14 +1717,15 @@ int cmd_do_fr_timerirq(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[
 }
 
 /**
- *     @brief  Print FlexRay driver version info.
+ *  @brief     Print FlexRay driver version info.
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_getversioninfo(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_getversioninfo(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        Std_VersionInfoType versionInfo;
 
        rpp_fr_get_driver_version(&versionInfo);
@@ -1780,30 +1739,28 @@ int cmd_do_fr_getversioninfo(cmd_io_t *cmd_io, const struct cmd_des *des, char *
 }
 
 /**
- *     @brief  Print value of FlexRay configuratoin parameter.
+ *  @brief     Print value of FlexRay configuratoin parameter.
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_readcconfig(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_readcconfig(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int8_t retVal = ERR_PARAM_NO_ERROR;
        int index = 0;
        uint32_t value = 0;
 
-       if (sscanf(param[1], "%d", &index) != 1) {
+       if (sscanf(param[1], "%d", &index) != 1)
                return -CMDERR_BADPAR;
-       }
 
-       if (param[2] != NULL) {
+       if (param[2] != NULL)
                return -CMDERR_BADPAR;
-       }
 
        retVal = rpp_fr_read_com_ctrl_config(0, index, &value);
-       if (retVal == SUCCESS) {
+       if (retVal == SUCCESS)
                rpp_sci_printf("Value = %#x\r\n", value);
-       }
        else {
                rpp_sci_printf("General error.\r\n");
                return -CMDERR_BADCFG;
@@ -1812,35 +1769,36 @@ int cmd_do_fr_readcconfig(cmd_io_t *cmd_io, const struct cmd_des *des, char *par
 }
 
 /**
- *     @brief  Reconfigure buffer
+ *  @brief     Reconfigure buffer
  *
  * @param[in]  cmd_io  Pointer to IO stack
  * @param[in]  des             Pointer to command descriptor
  * @param[in]  param   Parameters of command
  * @return     0 when OK or error code
  */
-int cmd_do_fr_reconfigure_buffer(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[]) {
+int cmd_do_fr_reconfigure_buffer(cmd_io_t *cmd_io, const struct cmd_des *des, char *param[])
+{
        int ret;
        char channel[3];
-       unsigned id, slot, maxpayload, cycleset, cycleoffset;
+       unsigned bufferID, slot, maxpayload, cycleset, cycleoffset;
        Fr_TMS570LS_BufferConfigType tmp_buffer;
        boolean_t is_pow2;
        uint8_t pow2;
 
        ret = sscanf(param[2], "id%i slot%i %2s cycset%i cycoffset%i max%i",
-                    &id,
-                    &slot,
-                    channel,
-                    &cycleset,
-                    &cycleoffset,
-                    &maxpayload
-                    );
+                                &bufferID,
+                                &slot,
+                                channel,
+                                &cycleset,
+                                &cycleoffset,
+                                &maxpayload
+                                );
        if (ret != 6) {
                printf("Error parsing parameter %d\n", ret+1);
                return -CMDERR_BADPAR;
        }
 
-       if (slot > 2047 || id > 2047)
+       if (slot > 2047 || bufferID > FR_MAX_BUFFERS_CNT)
                return badpar("Invalid slot number\n");
        tmp_buffer.slotId = slot;
        if (strcmp(channel, "A") == 0) tmp_buffer.channel = FR_CHANNEL_A;
@@ -1848,54 +1806,52 @@ int cmd_do_fr_reconfigure_buffer(cmd_io_t *cmd_io, const struct cmd_des *des, ch
        else if (strcmp(channel, "AB") == 0) tmp_buffer.channel = FR_CHANNEL_AB;
        else return badpar("Channel parsing error\n");
        if (cycleset == 0) cycleset = 1;
-       for (pow2 = 1, is_pow2 = FALSE; pow2 < 128; pow2*=2) {
+       for (pow2 = 1, is_pow2 = FALSE; pow2 < 128; pow2 *= 2) {
                if (cycleset == pow2) {
                        is_pow2 = TRUE;
                        break;
                }
        }
-       if (!is_pow2) {
+       if (!is_pow2)
                return badpar("Cycle set must be one of 0, 1, 2, 4, 8, 16, 32, 64.\n");
-       }
-       if (cycleoffset >= cycleset) {
+       if (cycleoffset >= cycleset)
                return badpar("Cycle offset must in range 0 - cycset-1.\n");
-       }
 
        if (maxpayload >= 256)
                return badpar("Maximum payload in bytes must be less than 256\n");
        tmp_buffer.maxPayload = maxpayload;
 
-       if (rpp_fr_reconfigure_lpdu(0, id, tmp_buffer.slotId, tmp_buffer.channel, cycleset, cycleoffset, tmp_buffer.maxPayload, 0) == SUCCESS) {
+       if (rpp_fr_reconfigure_lpdu(0, bufferID, tmp_buffer.slotId, tmp_buffer.channel, cycleset, cycleoffset, tmp_buffer.maxPayload, 0) == SUCCESS) {
                printf("id%i slot%i %2s cycset%i cycoffset%i max%i\n",
-                            id,
-                            slot,
-                            channel,
-                            cycleset,
-                            cycleoffset,
-                            maxpayload
-                            );
+                          bufferID,
+                          slot,
+                          channel,
+                          cycleset,
+                          cycleoffset,
+                          maxpayload
+                          );
                return 0;
        }
-       else {
+       else
                printf("Reconfiguration failed.\n");
-       }
        return -CMDERR_BADPAR;
 }
 
-#endif /* DOCGEN */
+#endif  /* DOCGEN */
 
 /** Command descriptor for FlexRay user config cluster command */
-cmd_des_t const cmd_des_fr_user_config={
+cmd_des_t const cmd_des_fr_user_config = {
        0, 0,
        "frbtconfig*","Set the user configuration parameters",
-               "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtconfig<TYPE> <PARAMS>\n"
+       "    frbtconfig<TYPE> <PARAMS>\n"
        "where\n"
-       "* <TYPE> is a string specifying the type of parameters to be set. It can be: \"cluster\" or  \"node\"\n"
-       "* <PARAMS> is a sequence of numbers separated by spaces. Each number stands for one parameter.\n"
        "\n"
-       "=== Description ===\n"
+       "- `<TYPE>` is a string specifying the type of parameters to be set. It can be: \"cluster\" or  \"node\"\n"
+       "- `<PARAMS>` is a sequence of numbers separated by spaces. Each number stands for one parameter.\n"
+       "\n"
+       "### Description ###\n"
        "\n"
        "The command takes the configuration parameters in the form of a string\n"
        "and sets the appropriate type of the FlexRay parameters. It is\n"
@@ -1904,131 +1860,134 @@ cmd_des_t const cmd_des_fr_user_config={
        "command are applied by the frbtinitU command. Once frbtinit is called,\n"
        "it is no longer possible to change the parameters.\n"
        "\n"
-       "The type of the parameters can be selected by the <TYPE> selector.\n"
+       "The type of the parameters can be selected by the `<TYPE>` selector.\n"
        "\n"
        "Type \"cluster\" sets global FlexRay network parameters. It expects a\n"
        "sequence of 25 parameters in this order:\n"
-       "* 1) gColdStartAttempts\n"
-       "* 2) gListenNoise\n"
-       "* 3) gMacroPerCycle\n"
-       "* 4) gMaxWithoutClockCorrectionFatal\n"
-       "* 5) gMaxWithoutClockCorrectionPassive\n"
-       "* 6) gNetworkManagementVectorLength\n"
-       "* 7) gNumberOfMinislots\n"
-       "* 8) gNumberOfStaticSlots\n"
-       "* 9) gOffsetCorrectionStart\n"
-       "* 10) gPayloadLengthStatic\n"
-       "* 11) gSyncNodeMax\n"
-       "* 12) gdActionPointOffset\n"
-       "* 13) gdCASRxLowMax\n"
-       "* 14) gdDynamicSlotIdlePhase\n"
-       "* 15) gdMinislot\n"
-       "* 16) gdMinislotActionPointOffset\n"
-       "* 17) gdNIT\n"
-       "* 18) gdSampleClockPeriod\n"
-       "* 19) gdStaticSlot\n"
-       "* 20) gdTSSTransmitter\n"
-       "* 21) gdWakeupSymbolRxIdle\n"
-       "* 22) gdWakeupSymbolRxLow\n"
-       "* 23) gdWakeupSymbolRxWindow\n"
-       "* 24) gdWakeupSymbolTxIdle\n"
-       "* 25) gdWakeupSymbolTxLow\n"
+       "\n"
+       "- 1) gColdStartAttempts\n"
+       "- 2) gListenNoise\n"
+       "- 3) gMacroPerCycle\n"
+       "- 4) gMaxWithoutClockCorrectionFatal\n"
+       "- 5) gMaxWithoutClockCorrectionPassive\n"
+       "- 6) gNetworkManagementVectorLength\n"
+       "- 7) gNumberOfMinislots\n"
+       "- 8) gNumberOfStaticSlots\n"
+       "- 9) gOffsetCorrectionStart\n"
+       "- 10) gPayloadLengthStatic\n"
+       "- 11) gSyncNodeMax\n"
+       "- 12) gdActionPointOffset\n"
+       "- 13) gdCASRxLowMax\n"
+       "- 14) gdDynamicSlotIdlePhase\n"
+       "- 15) gdMinislot\n"
+       "- 16) gdMinislotActionPointOffset\n"
+       "- 17) gdNIT\n"
+       "- 18) gdSampleClockPeriod\n"
+       "- 19) gdStaticSlot\n"
+       "- 20) gdTSSTransmitter\n"
+       "- 21) gdWakeupSymbolRxIdle\n"
+       "- 22) gdWakeupSymbolRxLow\n"
+       "- 23) gdWakeupSymbolRxWindow\n"
+       "- 24) gdWakeupSymbolTxIdle\n"
+       "- 25) gdWakeupSymbolTxLow\n"
        "\n"
        "Type \"node\" sets local FlexRay network parameters. It expects a\n"
        "sequence of 28 parameters in this order:\n"
-       "* 1) pAllowHaltDueToClock\n"
-       "* 2) pAllowPassiveToActive\n"
-       "* 3) pChannels (0 - A, 1 - B, 2 - AB)\n"
-       "* 4) pClusterDriftDamping\n"
-       "* 5) pDelayCompensationA\n"
-       "* 6) pDelayCompensationB\n"
-       "* 7) pExternOffsetCorrection\n"
-       "* 8) pExternRateCorrection\n"
-       "* 9) pKeySlotUsedForStartup\n"
-       "* 10) pKeySlotUsedForSync\n"
-       "* 11) pLatestTx\n"
-       "* 12) pMacroInitialOffsetA\n"
-       "* 13) pMacroInitialOffsetB\n"
-       "* 14) pMicroInitialOffsetA\n"
-       "* 15) pMicroInitialOffsetB\n"
-       "* 16) pMicroPerCycle\n"
-       "* 17) pRateCorrectionOut\n"
-       "* 18) pOffsetCorrectionOut\n"
-       "* 19) pSamplesPerMicrotick\n"
-       "* 20) pSingleSlotEnabled\n"
-       "* 21) pWakeupChannel (0 - A, 1 - B)\n"
-       "* 22) pWakeupPattern\n"
-       "* 23) pdAcceptedStartupRange\n"
-       "* 24) pdListenTimeout\n"
-       "* 25) pdMaxDrift\n"
-       "* 26) pDecodingCorrection\n"
-       "* 27) syncFramePayloadMultiplexEnabled\n"
-       "* 28) secureBuffers (0 - FR_SB_RECONFIG_ENABLED, 1 - FR_SB_STAT_REC_DISABLED_STAT_TR_DISABLED, 2 - FR_SB_ALL_REC_DISABLED, 3 - FR_SB_ALL_REC_DISABLED_STAT_TR_DISABLED)\n"
-       "\n"
-       "=== Example ===\n"
-       "\n"
-       "   --> frbtconfigcluster 0x2 0xF 0x15E0 0xF 0xF 0xC 0x15A 0x8 0xAE4 0x9 0xF 0x4 0x43 0x1 0x4 0x2 0xAE3 0x0 0x56 0xA 0x12 0x12 0x4C 0xB4 0x3C\n"
-       "   FlexRay cluster configuration accepted.\n"
-       "   --> frbtconfignode 0x0 0x0 0x2 0x1 0x3 0x3 0x0 0x0 0x1 0x1 0x10D 0x6 0x6 0x18 0x18 0x36B00 0xCD 0x151 0x0 0x1 0x0 0x2 0x81 0x36DA2 0x151 0x33 0x0 0x0\n"
-       "   FlexRay node configuration accepted.\n",
+       "\n"
+       "- 1) pAllowHaltDueToClock\n"
+       "- 2) pAllowPassiveToActive\n"
+       "- 3) pChannels (0 - A, 1 - B, 2 - AB)\n"
+       "- 4) pClusterDriftDamping\n"
+       "- 5) pDelayCompensationA\n"
+       "- 6) pDelayCompensationB\n"
+       "- 7) pExternOffsetCorrection\n"
+       "- 8) pExternRateCorrection\n"
+       "- 9) pKeySlotUsedForStartup\n"
+       "- 10) pKeySlotUsedForSync\n"
+       "- 11) pLatestTx\n"
+       "- 12) pMacroInitialOffsetA\n"
+       "- 13) pMacroInitialOffsetB\n"
+       "- 14) pMicroInitialOffsetA\n"
+       "- 15) pMicroInitialOffsetB\n"
+       "- 16) pMicroPerCycle\n"
+       "- 17) pRateCorrectionOut\n"
+       "- 18) pOffsetCorrectionOut\n"
+       "- 19) pSamplesPerMicrotick\n"
+       "- 20) pSingleSlotEnabled\n"
+       "- 21) pWakeupChannel (0 - A, 1 - B)\n"
+       "- 22) pWakeupPattern\n"
+       "- 23) pdAcceptedStartupRange\n"
+       "- 24) pdListenTimeout\n"
+       "- 25) pdMaxDrift\n"
+       "- 26) pDecodingCorrection\n"
+       "- 27) syncFramePayloadMultiplexEnabled\n"
+       "- 28) secureBuffers (0 - FR_SB_RECONFIG_ENABLED, 1 - FR_SB_STAT_REC_DISABLED_STAT_TR_DISABLED, 2 - FR_SB_ALL_REC_DISABLED, 3 - FR_SB_ALL_REC_DISABLED_STAT_TR_DISABLED)\n"
+       "\n"
+       "### Example ###\n"
+       "\n"
+       "    --> frbtconfigcluster 0x2 0xF 0x15E0 0xF 0xF 0xC 0x15A 0x8 0xAE4 0x9 0xF 0x4 0x43 0x1 0x4 0x2 0xAE3 0x0 0x56 0xA 0x12 0x12 0x4C 0xB4 0x3C\n"
+       "    FlexRay cluster configuration accepted.\n"
+       "    --> frbtconfignode 0x0 0x0 0x2 0x1 0x3 0x3 0x0 0x0 0x1 0x1 0x10D 0x6 0x6 0x18 0x18 0x36B00 0xCD 0x151 0x0 0x1 0x0 0x2 0x81 0x36DA2 0x151 0x33 0x0 0x0\n"
+       "    FlexRay node configuration accepted.\n",
        CMD_HANDLER(cmd_do_fr_user_config), (void *)&cmd_list_fr_basic_test
 };
 
-cmd_des_t const cmd_des_fr_config_buffer={
+cmd_des_t const cmd_des_fr_config_buffer = {
        0, 0,
        "frbtcfgbuf?*","Configure a message buffer in the user configuration",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtcfgbuf<TYPE><NUM> slot<SLOT> <CHN> cyc<CYC> <RXTX> max<MAX> <REP> ppi<PPI> int<INT>\n"
+       "    frbtcfgbuf<TYPE><BUFID> slot<SLOT> <CHN> cyc<CYC> <RXTX> max<MAX> <REP> ppi<PPI> int<INT>\n"
        "where\n"
-       "* <TYPE> is 'S' for static segment buffers and 'D' for dynamic segment buffers,\n"
-       "* <NUM> is the number of the buffer. Both static and dynamic buffers are numbered independently starting from zero,\n"
-       "* <SLOT> is the number of the slot,\n"
-       "* <CHN> is one of 'A', 'B' or 'AB' and identifies the used channel,\n"
-       "* <CYC> is the cycle set when to send the buffer,\n"
-       "* <RXTX> is either string \"rx\" or \"tx\",\n"
-       "* <MAX> is the number determining the maximum payload (in hald-words),\n"
-       "* <REP> is a string \"s\" or \"single\" for single transmission or \"c\" or \"continuous\" for continuous transmission,\n"
-       "* <PPI> is 0 or 1 determining whether the payload preamble indicator is set,\n"
-       "* <INT> is 0 or 1 and is currently ignored.\n"
-       "\n"
-       "=== Description ===\n"
+       "\n"
+       "- `<TYPE>` is 'S' for static segment buffers and 'D' for dynamic segment buffers,\n"
+       "- `<BUFID>` is the number of the buffer. Both static and dynamic buffers are numbered independently starting from zero,\n"
+       "- `<SLOT>` is the number of the slot,\n"
+       "- `<CHN>` is one of 'A', 'B' or 'AB' and identifies the used channel,\n"
+       "- `<CYC>` is the cycle set when to send the buffer,\n"
+       "- `<RXTX>` is either string \"rx\" or \"tx\",\n"
+       "- `<MAX>` is the number determining the maximum payload (in hald-words),\n"
+       "- `<REP>` is a string \"s\" or \"single\" for single transmission or \"c\" or \"continuous\" for continuous transmission,\n"
+       "- `<PPI>` is 0 or 1 determining whether the payload preamble indicator is set,\n"
+       "- `<INT>` is 0 or 1 and is currently ignored.\n"
+       "\n"
+       "### Description ###\n"
        "\n"
        "The command sets the configuration parameters for static or dynamic\n"
        "buffers in user configuration. The parameters set by this command are\n"
        "applied by the frbtinitU command. Once frbtinit is called, it is no\n"
        "longer possible to change the parameters.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtcfgbufS0 slot2 AB cyc0 tx max9 continous ppi0 int1\n"
-       "   frbtcfgbufS0 slot2 AB cyc0 tx max9  continous ppi0 int1\n"
-       "   --> frbtcfgbufS1 slot1 AB cyc0 rx max9 continuous ppi0 int1\n"
-       "   frbtcfgbufS1 slot1 AB cyc0 rx max9 continuous ppi0 int1\n"
-       "   --> frbtcfgbufD0  slot9  A cyc0 rx max0x40 single ppi0 int0\n"
-       "   frbtcfgbufD0 slot9  A cyc0 rx max64 single ppi0 int0\n"
-       "   --> frbtcfgbufD1  slot10 A cyc0 tx max0x40 single ppi0 int0\n"
-       "   frbtcfgbufD1 slot10  A cyc0 tx max64 single ppi0 int0\n",
+       "    --> frbtcfgbufS0 slot2 AB cyc0 tx max9 continous ppi0 int1\n"
+       "    frbtcfgbufS0 slot2 AB cyc0 tx max9  continous ppi0 int1\n"
+       "    --> frbtcfgbufS1 slot1 AB cyc0 rx max9 continuous ppi0 int1\n"
+       "    frbtcfgbufS1 slot1 AB cyc0 rx max9 continuous ppi0 int1\n"
+       "    --> frbtcfgbufD0  slot9  A cyc0 rx max0x40 single ppi0 int0\n"
+       "    frbtcfgbufD0 slot9  A cyc0 rx max64 single ppi0 int0\n"
+       "    --> frbtcfgbufD1  slot10 A cyc0 tx max0x40 single ppi0 int0\n"
+       "    frbtcfgbufD1 slot10  A cyc0 tx max64 single ppi0 int0\n",
        CMD_HANDLER(cmd_do_fr_config_bufer), (void *)&cmd_list_fr_basic_test
 };
 
-cmd_des_t const cmd_des_fr_config_fifo={
+cmd_des_t const cmd_des_fr_config_fifo = {
        0, 0,
        "frbtcfgfifo*","Configure a RX FIFO message buffer in the user configuration",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtcfgfifo rejslot<SLOT> slotmask<MASK> depth<DEPTH> <CHN> cyc<CYC> max<MAX> <REJNULL> <REJSTAT>\n"
+       "    frbtcfgfifo rejslot<SLOT> slotmask<MASK> depth<DEPTH> <CHN> cyc<CYC> max<MAX> <REJNULL> <REJSTAT>\n"
        "where\n"
-       "* <SLOT> is the number of the slot that will be rejected. If it is 0, no slot will be rejected,\n"
-       "* <MASK> is a number specifying which bits of the <SLOT> will be ignored,"
-       "* <DEPTH> is a number specifying the depth of the FIFO,\n"
-       "* <CHN> is one of 'A', 'B' or 'AB' and identifies the used channel,\n"
-       "* <CYC> is the cycle set when to send the buffer,\n"
-       "* <MAX> is the number determining the maximum payload (in hald-words),\n"
-       "* <REJNULL> is a string \"rejnull\" for rejecting NULL frames or \"accnull\" for accepting NULL frames,\n"
-       "* <REJSTAT> is a string \"rejstat\" for rejecting frames in static segment or \"accstat\" for accepting frames from static segment,\n"
+       "- `<SLOT>` is the number of the slot that will be rejected. If it is 0, no slot will be rejected,\n"
+       "- `<MASK>` is a number specifying which bits of the `<SLOT>` will be ignored,"
+       "- `<DEPTH>` is a number specifying the depth of the FIFO,\n"
+       "- `<CHN>` is one of 'A', 'B' or 'AB' and identifies the used channel,\n"
+       "- `<CYC>` is the cycle set when to send the buffer,\n"
+       "- `<MAX>` is the number determining the maximum payload (in hald-words),\n"
+       "- `<REJNULL>` is a string \"rejnull\" for rejecting NULL frames or \"accnull\" for accepting NULL frames,\n"
+       "- `<REJSTAT>` is a string \"rejstat\" for rejecting frames in static segment or \"accstat\" for accepting frames from static segment,\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command sets the configuration parameters for RX FIFO buffer\n"
        "in user configuration. The parameters set by this command are\n"
@@ -2037,26 +1996,26 @@ cmd_des_t const cmd_des_fr_config_fifo={
        "Those messages, which are not accepted by any other buffer and pass the\n"
        "FIFO rejection filter will be stored in the RX FIFO buffer.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtcfgfifo rejslot6 slotmask6 depth5 AB cyc0 max0x20 rejnull accstat\n"
-       "   frbtcfgfifo rejslot6 slotmask6 depth5 AB cyc0 max0x20 rejnull accstat\n",
+       "    --> frbtcfgfifo rejslot6 slotmask6 depth5 AB cyc0 max0x20 rejnull accstat\n"
+       "    frbtcfgfifo rejslot6 slotmask6 depth5 AB cyc0 max0x20 rejnull accstat\n",
        CMD_HANDLER(cmd_do_fr_config_fifo), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay init command */
-cmd_des_t const cmd_des_fr_init={
+cmd_des_t const cmd_des_fr_init = {
        0, 0,
        "frbtinit?","Initialize a FlexRay node",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtinit<CFG>\n"
+       "    frbtinit<CFG>\n"
        "\n"
-       "where <CFG> identifies the configuration to use. It can be one of A, B\n"
+       "where `<CFG>` identifies the configuration to use. It can be one of A, B\n"
        "or U. The A and B are predefined configurations. If U is specified,\n"
        "the user configuration previously set by frbtconfig command is used.\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_Init and Fr_ControllerInit functions from\n"
        "the Autosar specification. It initializes the internal data structures\n"
@@ -2072,23 +2031,23 @@ cmd_des_t const cmd_des_fr_init={
        "to send NULL frames. This command should be called as the very first\n"
        "command, when trying to communicate over the FlexRay bus.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtinitA\n"
-       "   FlexRay driver initialized.\n"
-       "   FlexRay controller initialized.\n",
+       "    --> frbtinitA\n"
+       "    FlexRay driver initialized.\n"
+       "    FlexRay controller initialized.\n",
        CMD_HANDLER(cmd_do_fr_init), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay controller init command */
-cmd_des_t const cmd_des_fr_start={
+cmd_des_t const cmd_des_fr_start = {
        0, 0,
        "frbtstart","Start a new FlexRay network or join to the existing one",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtstart\n"
+       "    frbtstart\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_StartCommunication function from the Autosar\n"
        "specification.\n"
@@ -2103,22 +2062,25 @@ cmd_des_t const cmd_des_fr_start={
        "\n"
        "The command should be called after the frbtinit command.\n"
        "\n"
-       "=== Example ===\n"
+       "You may also want to call frbtallslots command to allow the communication\n"
+       "for all other slots besides the key slots.\n"
+       "\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtstart\n"
-       "   FlexRay communication is running.\n",
+       "    --> frbtstart\n"
+       "    FlexRay communication is running.\n",
        CMD_HANDLER(cmd_do_fr_start), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay controller all slots command */
-cmd_des_t const cmd_des_fr_allslots={
+cmd_des_t const cmd_des_fr_allslots = {
        0, 0,
        "frbtallslots","Enables communication for all frames",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtallslots\n"
+       "    frbtallslots\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_AllSlots function from the Autosar\n"
        "specification.\n"
@@ -2130,22 +2092,22 @@ cmd_des_t const cmd_des_fr_allslots={
        "all frames. The command can be called after the controller\n"
        "initialization.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtallslots\n"
-       "   FlexRay node started communication on all slots.\n",
+       "    --> frbtallslots\n"
+       "    FlexRay node started communication on all slots.\n",
        CMD_HANDLER(cmd_do_fr_allslots), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay controller halt command */
-cmd_des_t const cmd_des_fr_halt={
+cmd_des_t const cmd_des_fr_halt = {
        0, 0,
        "frbthalt","Halt FlexRay communication after the end of the actual communication cycle",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbthalt\n"
+       "    frbthalt\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_HaltCommunication function from the Autosar\n"
        "specification. The command invokes the FlexRay POC command HALT, which\n"
@@ -2154,22 +2116,22 @@ cmd_des_t const cmd_des_fr_halt={
        "command, which stops the communication immediately. To restart the\n"
        "communication, the frbtinit and frbtstart commands have to be called.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbthalt\n"
-       "   FlexRay node communication halted.\n",
+       "    --> frbthalt\n"
+       "    FlexRay node communication halted.\n",
        CMD_HANDLER(cmd_do_fr_halt), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay controller abort command */
-cmd_des_t const cmd_des_fr_abort={
+cmd_des_t const cmd_des_fr_abort = {
        0, 0,
        "frbtabort","Abort FlexRay communication immediately",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtabort\n"
+       "    frbtabort\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_AbortCommunication function from the Autosar\n"
        "specification. The command invokes the FlexRay POC command FREEZE,\n"
@@ -2179,45 +2141,45 @@ cmd_des_t const cmd_des_fr_abort={
        "restart the communication, the frbtinit and frbtstart commands have\n"
        "to be called.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtabort\n"
-       "   FlexRay node communication aborted.\n",
+       "    --> frbtabort\n"
+       "    FlexRay node communication aborted.\n",
        CMD_HANDLER(cmd_do_fr_abort), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay controller send wake up pattern command */
-cmd_des_t const cmd_des_fr_sendwup={
+cmd_des_t const cmd_des_fr_sendwup = {
        0, 0,
        "frbtwup","Initiate the wake up procedure",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtwup\n"
+       "    frbtwup\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_SendWUP function from the Autosar\n"
        "specification. It initiates the wake up procedure by switching FlexRay\n"
        "controller state machine to WAKEUP state.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtwup\n"
-       "   Wake up pattern has been sent.\n",
+       "    --> frbtwup\n"
+       "    Wake up pattern has been sent.\n",
        CMD_HANDLER(cmd_do_fr_sendwup), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay controller sent wake up pattern channel command */
-cmd_des_t const cmd_des_fr_setwuchannel={
+cmd_des_t const cmd_des_fr_setwuchannel = {
        0, 0,
        "frbtsetwuch?","Set wake up channel",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtsetwuch<CHANNEL>\n"
+       "    frbtsetwuch<CHANNEL>\n"
        "\n"
-       "where <CHANNEL> is a character A or B, specifying the channel.\n"
+       "where `<CHANNEL>` is a character A or B, specifying the channel.\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_SetWakeupChannel function from the Autosar\n"
        "specification. Wake up channel is the channel, where Wake Up Pattern\n"
@@ -2225,381 +2187,384 @@ cmd_des_t const cmd_des_fr_setwuchannel={
        "initialized and before the communication is running. The actual\n"
        "wake-up pattern is sent by the frbtwup command.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtsetwuchA\n"
-       "   Wake up channel has been set.\n",
+       "    --> frbtsetwuchA\n"
+       "    Wake up channel has been set.\n",
        CMD_HANDLER(cmd_do_fr_setwuchannel), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay controller get POC status command */
-cmd_des_t const cmd_des_fr_getpocstatus={
+cmd_des_t const cmd_des_fr_getpocstatus = {
        0, 0,
        "frbtgetpocst","Print FlexRay POC status",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtgetpocst\n"
+       "    frbtgetpocst\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_GetPOCStatus function from the Autosar\n"
        "specification. It prints the main FlexRay POC status values in the\n"
        "form of a table. The command should be called after the frbtinit\n"
        "command.\n"
        "\n"
-       "=== Example ===\n"
-       "\n"
-       "   --> frbtgetpocst\n"
-       "   POC status:\n"
-       "   CHIHaltRequest: FALSE\n"
-       "   CHIReadyRequest: FALSE\n"
-       "   ColdstartNoise: FALSE\n"
-       "   Freeze: FALSE\n"
-       "   ErrorMode: ACTIVE\n"
-       "   SlotMode: ALL\n"
-       "   StartupState: UNDEFINED\n"
-       "   State: READY\n"
-       "   WakeupStatus: UNDEFINED\n",
+       "### Example ###\n"
+       "\n"
+       "    --> frbtgetpocst\n"
+       "    POC status:\n"
+       "    CHIHaltRequest: FALSE\n"
+       "    CHIReadyRequest: FALSE\n"
+       "    ColdstartNoise: FALSE\n"
+       "    Freeze: FALSE\n"
+       "    ErrorMode: ACTIVE\n"
+       "    SlotMode: ALL\n"
+       "    StartupState: UNDEFINED\n"
+       "    State: READY\n"
+       "    WakeupStatus: UNDEFINED\n",
        CMD_HANDLER(cmd_do_fr_getpocstatus), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay transmit tx lpdu command */
-cmd_des_t const cmd_des_fr_transmittxlpdu={
+cmd_des_t const cmd_des_fr_transmittxlpdu = {
        0, 0,
-       "frbttransmit*","Transmit data in selected frame",
-       "=== Command syntax ===\n"
+       "frbttransmit*","Transmit data from the selected frame buffer",
+       "### Command syntax ###\n"
        "\n"
-       "   frbttransmit<FRID> <DATA>\n"
+       "    frbttransmit<BUFID> <DATA>\n"
        "where\n"
-       "* <FRID> is a decimal number specifying the ID of the frame for which a buffer has been configured.\n"
-       "* <DATA> is a sequence of hexadecimal numbers separated by spaces. Each number represents one byte of the message.\n"
        "\n"
-       "=== Description ===\n"
+       "- `<BUFID>` is a decimal number specifying the ID of the frame\n"
+       "            buffer configured for data transmission\n"
+       "- `<DATA>`  is a sequence of hexadecimal numbers separated by spaces.\n"
+       "            Each number represents one byte of the message.\n"
+       "\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_TransmitTxLPdu function from the Autosar\n"
-       "specification. The command finds the first buffer assigned to the\n"
-       "specified frame ID and copies the given data into its data section in\n"
-       "the message RAM. Transmit request is set after the data are copied, so\n"
-       "transmission starts at the next occurrence of the frame in the\n"
+       "specification. The command copies the given data into the buffers data\n"
+       "section in the message RAM. Transmit request is set after the data are\n"
+       "copied, so transmission starts at the next occurrence of the frame in the\n"
        "communication cycle.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbttransmit1 12 34 56 AA BB CC\n"
-       "   Data were set for transmission.\n",
+       "    --> frbttransmit1 12 34 56 AA BB CC\n"
+       "    Data were set for transmission.\n",
        CMD_HANDLER(cmd_do_fr_transmittxlpdu), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay cancel tx lpdu command */
-cmd_des_t const cmd_des_fr_canceltxlpdu={
+cmd_des_t const cmd_des_fr_canceltxlpdu = {
        0, 0,
-       "frbtcanceltx*","Stop the transmission of the frame",
-       "=== Command syntax ===\n"
+       "frbtcanceltx*","Stop the transmission from the frame buffer",
+       "### Command syntax ###\n"
        "\n"
-       "   frbtcanceltx<FRID>\n"
+       "    frbtcanceltx<BUFID>\n"
        "\n"
-       "where <FRID> is a decimal number specifying the ID of the frame for\n"
-       "which a buffer has been configured.\n"
+       "where `<BUFID>` is a decimal number specifying the ID of a configured\n"
+       "frame buffer\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_CancelTxLPdu function from the Autosar\n"
-       "specification. The command finds all buffers assigned to the specified\n"
-       "frame ID and reconfigures them to stop transmitting data. The command\n"
-       "finishes successfully only if reconfiguration is allowed in message\n"
-       "RAM configuration (secureBuffers configuration parameter). Only TX\n"
-       "buffers and buffers not used for startup frames can be canceled.\n"
+       "specification. The command reconfigures the selected buffer to stop\n"
+       "data transmission. The command finishes successfully only if the\n"
+       "reconfiguration is allowed in message RAM configuration (secureBuffers\n"
+       "configuration parameter). Only TX buffers and buffers not used for startup\n"
+       "frames can be canceled.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtcanceltx3\n"
-       "   Transmission canceled.\n",
+       "    --> frbtcanceltx3\n"
+       "    Transmission canceled.\n",
        CMD_HANDLER(cmd_do_fr_canceltxlpdu), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay receive rx lpdu command */
-cmd_des_t const cmd_des_fr_receiverxlpdu={
+cmd_des_t const cmd_des_fr_receiverxlpdu = {
        0, 0,
        "frbtreceive*","Receive a new message",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtreceive<FRID>\n"
+       "    frbtreceive<BUFID>\n"
        "\n"
-       "where <FRID> is a decimal number specifying the ID of the frame for\n"
-       "which a buffer was configured.\n"
+       "where `<BUFID>` is a decimal number specifying the ID of a configured\n"
+       "frame buffer.\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_ReceiveRxLPdu function from the Autosar\n"
-       "specification. The command finds the first buffer assigned to the\n"
-       "specified frame ID, determines if a new message has been received and\n"
-       "reads it out of the buffer. If no message was received, \"No message\n"
-       "received\" is printed. If a new message was received, all message data\n"
-       "are printed as a hexadecimal values. If a new message was retrieved\n"
-       "from a FIFO buffer and more messages are available in it, \"More\n"
-       "messages are still in FIFO\" is printed.\n"
-       "\n"
-       "=== Example ===\n"
-       "\n"
-       "   --> frbtreceive0\n"
-       "   More messages are still in FIFO:\n"
-       "   Received message (32 B):\n"
-       "    ee ff 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00\n",
+       "specification. The command tries to read a new message from the selected\n"
+       "buffer. If new message is available, it is copied out of the buffer and\n"
+       "printed. If no message is available, \"No message received\" is printed.\n"
+       "If a new message was retrieved from a FIFO buffer and more messages are\n"
+       "available in it, \"More messages are still in FIFO\" is printed.\n"
+       "\n"
+       "### Example ###\n"
+       "\n"
+       "    --> frbtreceive0\n"
+       "    More messages are still in FIFO:\n"
+       "    Received message (32 B):\n"
+       "     ee ff 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00\n"
+       "     00 00 00 00 00 00 00 00 00\n",
        CMD_HANDLER(cmd_do_fr_receiverxlpdu), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay check TX LPdu status command */
-cmd_des_t const cmd_des_fr_checktxlpdustatus={
+cmd_des_t const cmd_des_fr_checktxlpdustatus = {
        0, 0,
        "frbtchecktx*","Print the status of the transmit buffer",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtchecktx<FRID>\n"
+       "    frbtchecktx<BUFID>\n"
        "\n"
-       "where <FRID> is a decimal number specifying the ID of the frame for\n"
-       "which a buffer has been configured.\n"
+       "where `<BUFID>` is a decimal number specifying the ID of a configured\n"
+       "frame buffer.\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_CheckTxLPduStatus function from the Autosar\n"
-       "specification. The command finds the first buffer assigned to the\n"
-       "specified frame ID, reads its status and prints it. The buffer can be\n"
-       "in one of the two states:\n"
-       "* Message transmission is pending, which means that the buffer has not yet sent its message in single shot mode or that it is in continuous mode.\n"
-       "* No message transmission is pending, which means that the buffer is in single shot mode and the message has already been sent.\n"
+       "specification. The command reads and prints status of the selected frame buffer.\n"
+       "The buffer can be in one of the two states:\n"
        "\n"
-       "=== Example ===\n"
+       "- Message transmission is pending, which means that the buffer has not yet sent its\n"
+       "  message in single shot mode or that it is in continuous mode.\n"
+       "- No message transmission is pending, which means that the buffer is in single shot\n"
+       "  mode and the message has already been sent.\n"
        "\n"
-       "   --> frbtchecktx1\n"
-       "   Message transmission is not pending.\n",
+       "### Example ###\n"
+       "\n"
+       "    --> frbtchecktx1\n"
+       "    Message transmission is not pending.\n",
        CMD_HANDLER(cmd_do_fr_checktxlpdustatus), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay disable LPdu command */
-cmd_des_t const cmd_des_fr_disablelpdu={
+cmd_des_t const cmd_des_fr_disablelpdu = {
        0, 0,
        "frbtdisable*","Disable the buffers assigned to the frame",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtdisable<FRID>\n"
+       "    frbtdisable<BUFID>\n"
        "\n"
-       "where <FRID> is a decimal number specifying the ID of a frame. The\n"
-       "buffers configure for this frame will be disabled.\n"
+       "where `<BUFID>` is a decimal number specifying the ID of a frame buffer.\n"
+       "The buffer configured will be disabled.\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_DisableLPdu function from the Autosar\n"
-       "specification. The command finds all buffers assigned to the specified\n"
-       "frame ID and disables them. This means that those buffers will be\n"
-       "unavailable for the communication until their reconfiguration (which\n"
-       "is not yet implemented). Buffers used for startup frames and FIFO RX\n"
-       "buffers cannot be disabled.\n"
+       "specification. The command disables the selected buffer. This means\n"
+       "that this buffer will be unavailable for the communication until\n"
+       "their reconfiguration (which is not yet implemented). Buffers used\n"
+       "for startup frames and FIFO RX buffers cannot be disabled.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtdisable3\n"
-       "   Buffer disabled.\n",
+       "    --> frbtdisable3\n"
+       "    Buffer disabled.\n",
        CMD_HANDLER(cmd_do_fr_disablelpdu), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay get global time command */
-cmd_des_t const cmd_des_fr_getglobaltime={
+cmd_des_t const cmd_des_fr_getglobaltime = {
        0, 0,
        "frbtglobtime","Print actual global time of the network",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtglobtime\n"
+       "    frbtglobtime\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_GetGlobalTime function from the Autosar\n"
        "specification. The command prints the time as a number of the current\n"
        "cycle and the offset in the cycle in macroticks.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtglobtime\n"
-       "   Cycle number: 23\n"
-       "   Macrotick number: 6\n",
+       "    --> frbtglobtime\n"
+       "    Cycle number: 23\n"
+       "    Macrotick number: 6\n",
        CMD_HANDLER(cmd_do_fr_getglobaltime), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay get network management vector command */
-cmd_des_t const cmd_des_fr_getnmvector={
+cmd_des_t const cmd_des_fr_getnmvector = {
        0, 0,
        "frbtnmvector","Print network management vector of the node",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtnmvector\n"
+       "    frbtnmvector\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_GetNmVector function from the Autosar\n"
        "specification. It prints the values of the network management vector\n"
        "as hexadecimal numbers.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtnmvector\n"
-       "   Network management vector: 0 0 0 0 0 0 0 0 0 0 0 0\n",
+       "    --> frbtnmvector\n"
+       "    Network management vector: 0 0 0 0 0 0 0 0 0 0 0 0\n",
        CMD_HANDLER(cmd_do_fr_getnmvector), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay get network management vector command */
-cmd_des_t const cmd_des_fr_nmwatch={
+cmd_des_t const cmd_des_fr_nmwatch = {
        0, 0,
        "frbtnmwatch","Watch the changes of the network managment vector in real-time",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtnmwatch\n"
+       "    frbtnmwatch\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "Reads the network management vector every 100 ms and prints it out.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtnmwatch\n"
-       "   Network management vector: 0 0 0 0 0 0 0 0 0 0 0 0\n",
+       "    --> frbtnmwatch\n"
+       "    Network management vector: 0 0 0 0 0 0 0 0 0 0 0 0\n",
        CMD_HANDLER(cmd_do_fr_nmwatch), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay get channel status command */
-cmd_des_t const cmd_des_fr_getchannelstatus={
+cmd_des_t const cmd_des_fr_getchannelstatus = {
        0, 0,
        "frbtchstat","Print channel A and B status",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtchstat\n"
+       "    frbtchstat\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_GetChannelStatus function from the Autosar\n"
        "specification.\n"
        "\n"
-       "=== Example ===\n"
-       "\n"
-       "   --> frbtchstat\n"
-       "   Channel A status:\n"
-       "       aggregated channel status vSS!ValidFrame: TRUE\n"
-       "       aggregated channel status vSS!SyntaxError: FALSE\n"
-       "       aggregated channel status vSS!ContentError: FALSE\n"
-       "       aggregated channel status additional communication: FALSE\n"
-       "       aggregated channel status vSS!Bviolation: FALSE\n"
-       "       aggregated channel status vSS!TxConflict: FALSE\n"
-       "       Not used (0): FALSE\n"
-       "       Not used (0): FALSE\n"
-       "       symbol window status data vSS!ValidMTS: FALSE\n"
-       "       symbol window status data vSS!SyntaxError: FALSE\n"
-       "       symbol window status data vSS!Bviolation: FALSE\n"
-       "       symbol window status data vSS!TxConflict: FALSE\n"
-       "       NIT status data vSS!SyntaxError: FALSE\n"
-       "       NIT status data vSS!Bviolation: FALSE\n"
-       "       Not used (0): FALSE\n"
-       "       Not used (0): FALSE\n"
-       "   Channel B status:\n"
-       "       aggregated channel status vSS!ValidFrame: TRUE\n"
-       "       aggregated channel status vSS!SyntaxError: FALSE\n"
-       "       aggregated channel status vSS!ContentError: FALSE\n"
-       "       aggregated channel status additional communication: FALSE\n"
-       "       aggregated channel status vSS!Bviolation: FALSE\n"
-       "       aggregated channel status vSS!TxConflict: FALSE\n"
-       "       Not used (0): FALSE\n"
-       "       Not used (0): FALSE\n"
-       "       symbol window status data vSS!ValidMTS: FALSE\n"
-       "       symbol window status data vSS!SyntaxError: FALSE\n"
-       "       symbol window status data vSS!Bviolation: FALSE\n"
-       "       symbol window status data vSS!TxConflict: FALSE\n"
-       "       NIT status data vSS!SyntaxError: FALSE\n"
-       "       NIT status data vSS!Bviolation: FALSE\n"
-       "       Not used (0): FALSE\n"
-       "       Not used (0): FALSE\n",
+       "### Example ###\n"
+       "\n"
+       "    --> frbtchstat\n"
+       "    Channel A status:\n"
+       "       aggregated channel status vSS!ValidFrame: TRUE\n"
+       "       aggregated channel status vSS!SyntaxError: FALSE\n"
+       "       aggregated channel status vSS!ContentError: FALSE\n"
+       "       aggregated channel status additional communication: FALSE\n"
+       "       aggregated channel status vSS!Bviolation: FALSE\n"
+       "       aggregated channel status vSS!TxConflict: FALSE\n"
+       "       Not used (0): FALSE\n"
+       "       Not used (0): FALSE\n"
+       "       symbol window status data vSS!ValidMTS: FALSE\n"
+       "       symbol window status data vSS!SyntaxError: FALSE\n"
+       "       symbol window status data vSS!Bviolation: FALSE\n"
+       "       symbol window status data vSS!TxConflict: FALSE\n"
+       "       NIT status data vSS!SyntaxError: FALSE\n"
+       "       NIT status data vSS!Bviolation: FALSE\n"
+       "       Not used (0): FALSE\n"
+       "       Not used (0): FALSE\n"
+       "    Channel B status:\n"
+       "       aggregated channel status vSS!ValidFrame: TRUE\n"
+       "       aggregated channel status vSS!SyntaxError: FALSE\n"
+       "       aggregated channel status vSS!ContentError: FALSE\n"
+       "       aggregated channel status additional communication: FALSE\n"
+       "       aggregated channel status vSS!Bviolation: FALSE\n"
+       "       aggregated channel status vSS!TxConflict: FALSE\n"
+       "       Not used (0): FALSE\n"
+       "       Not used (0): FALSE\n"
+       "       symbol window status data vSS!ValidMTS: FALSE\n"
+       "       symbol window status data vSS!SyntaxError: FALSE\n"
+       "       symbol window status data vSS!Bviolation: FALSE\n"
+       "       symbol window status data vSS!TxConflict: FALSE\n"
+       "       NIT status data vSS!SyntaxError: FALSE\n"
+       "       NIT status data vSS!Bviolation: FALSE\n"
+       "       Not used (0): FALSE\n"
+       "       Not used (0): FALSE\n",
        CMD_HANDLER(cmd_do_fr_getchannelstatus), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay get clock correction command */
-cmd_des_t const cmd_des_fr_getclockcorrection={
+cmd_des_t const cmd_des_fr_getclockcorrection = {
        0, 0,
        "frbtclkcor","Print clock correction (rate and offset)",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtclkcor\n"
+       "    frbtclkcor\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_GetClockCorrection function from the Autosar\n"
        "specification.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtclkcor\n"
-       "   Rate correction: 0\n"
-       "   Offset correction: 0\n",
+       "    --> frbtclkcor\n"
+       "    Rate correction: 0\n"
+       "    Offset correction: 0\n",
        CMD_HANDLER(cmd_do_fr_getclockcorrection), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay get sync frame list command */
-cmd_des_t const cmd_des_fr_getsyncframelist={
+cmd_des_t const cmd_des_fr_getsyncframelist = {
        0, 0,
        "frbtgetsyncfrlist*","Print the list of sync frames transmitted on both channels via the odd and even communication cycle",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtgetsyncfrlist<LENGTH>\n"
+       "    frbtgetsyncfrlist<LENGTH>\n"
        "\n"
-       "where <LENGTH> is a decimal number in range 0 - 15, specifying the\n"
+       "where `<LENGTH>` is a decimal number in range 0 - 15, specifying the\n"
        "length of the list to be printed.\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_GetSyncFrameList function from the Autosar\n"
        "specification.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtgetsyncfrlist2\n"
-       "   | Channel A even | channel B even | channel A odd  | channel B odd  |\n"
-       "   |----------------|----------------|----------------|----------------|\n"
-       "   | 1              | 1              | 1              | 1              |\n"
-       "   | 2              | 2              | 2              | 2              |\n"
-       "   |----------------|----------------|----------------|----------------|\n",
+       "    --> frbtgetsyncfrlist2\n"
+       "    | Channel A even | channel B even | channel A odd  | channel B odd  |\n"
+       "    |----------------|----------------|----------------|----------------|\n"
+       "    | 1              | 1              | 1              | 1              |\n"
+       "    | 2              | 2              | 2              | 2              |\n"
+       "    |----------------|----------------|----------------|----------------|\n",
        CMD_HANDLER(cmd_do_fr_getsyncframelist), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay get sync frame list command */
-cmd_des_t const cmd_des_fr_getwakeuprxstatus={
+cmd_des_t const cmd_des_fr_getwakeuprxstatus = {
        0, 0,
        "frbtgetwurxstat","Prints whether the wake up pattern has been or has not been received",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtgetwurxstat\n"
+       "    frbtgetwurxstat\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_GetWakeupRxStatus function from the Autosar\n"
        "specification. The status of the wake up receiving is bitcoded in the\n"
        "controller. This command decodes and prints it in a readable format.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtgetwurxstat\n"
-       "   Wake up pattern was not yet received on channel A.\n"
-       "   Wake up pattern was not yet received on channel B.\n",
+       "    --> frbtgetwurxstat\n"
+       "    Wake up pattern was not yet received on channel A.\n"
+       "    Wake up pattern was not yet received on channel B.\n",
        CMD_HANDLER(cmd_do_fr_getwakeuprxstatus), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay set absolute timer command */
-cmd_des_t const cmd_des_fr_settimer={
+cmd_des_t const cmd_des_fr_settimer = {
        0, 0,
        "frbtsettimer*","Set and start timer",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtsettimer<TMID> <CYCLE> <OFFSET>\n"
+       "    frbtsettimer<TMID> <CYCLE> <OFFSET>\n"
        "where\n"
-       "* <TMID> is a number (0, 1) specifying the timer.\n"
-       "* <CYCLE> is a 7-bit number (0 - 127) specifying the set of cycles, in which timer interrupt should be requested. The first set bit determines the period (1, 2, ..., 64) and the lower bits determine the offset in cycles within the period.\n"
-       "* <OFFSET> is a decimal number (0 - 16383) specifying the offset in macroticks, where precisely in the cycle should be the timer interrupt requested.\n"
        "\n"
-       "=== Description ===\n"
+       "- `<TMID>` is a number (0, 1) specifying the timer.\n"
+       "- `<CYCLE>` is a 7-bit number (0 - 127) specifying the set of cycles, in which timer interrupt should be requested. The first set bit determines the period (1, 2, ..., 64) and the lower bits determine the offset in cycles within the period.\n"
+       "- `<OFFSET>` is a decimal number (0 - 16383) specifying the offset in macroticks, where precisely in the cycle should be the timer interrupt requested.\n"
+       "\n"
+       "### Description ###\n"
        "\n"
        "The command is similar to Fr_SetAbsoluteTimer function from the\n"
        "Autosar specification. The difference is that the command allows to\n"
@@ -2609,57 +2574,59 @@ cmd_des_t const cmd_des_fr_settimer={
        "Before using this command, FlexRay communication has to be started\n"
        "(see frbtstart).\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtsettimer0 32 50\n"
-       "   Timer was set for every 32-th cycle, offset 0, macrotick 50\n"
-       "   --> frbtsettimer0 31 50\n"
-       "   Timer was set for every 16-th cycle, offset 15, macrotick 50\n"
-       "   --> frbtsettimer0 0x42 0\n"
-       "   Timer was set for every 64-th cycle, offset 2, macrotick 0\n",
+       "    --> frbtsettimer0 32 50\n"
+       "    Timer was set for every 32-th cycle, offset 0, macrotick 50\n"
+       "    --> frbtsettimer0 31 50\n"
+       "    Timer was set for every 16-th cycle, offset 15, macrotick 50\n"
+       "    --> frbtsettimer0 0x42 0\n"
+       "    Timer was set for every 64-th cycle, offset 2, macrotick 0\n",
        CMD_HANDLER(cmd_do_fr_settimer), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay cancel absolute timer command */
-cmd_des_t const cmd_des_fr_canceltimer={
+cmd_des_t const cmd_des_fr_canceltimer = {
        0, 0,
        "frbtcanceltimer*","Stop the timer",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtcanceltimer<TMID>\n"
-       "where <TMID> is a number (0 or 1) specifying the timer.\n"
+       "    frbtcanceltimer<TMID>\n"
+       "where `<TMID>` is a number (0 or 1) specifying the timer.\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_CancelAbsoluteTimer function from the\n"
        "Autosar specification. It stops the timer selected by the parameter.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtcanceltimer0\n"
-       "   Timer was canceled.\n",
+       "    --> frbtcanceltimer0\n"
+       "    Timer was canceled.\n",
        CMD_HANDLER(cmd_do_fr_canceltimer), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay absolute timer irq manipulation command */
-cmd_des_t const cmd_des_fr_timerirq={
+cmd_des_t const cmd_des_fr_timerirq = {
        0, 0,
        "frbttimerirq*","Perform selected action on the timer IRQ",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbttimerirq<TMID> <ACTION> - Run the <ACTION> on specified timer\n"
-       "   frbttimerirq<TMID> - Get timer IRQ status\n"
+       "    frbttimerirq<TMID> <ACTION> - Run the <ACTION> on specified timer\n"
+       "    frbttimerirq<TMID> - Get timer IRQ status\n"
        "\n"
        "where\n"
-       "* <TMID> is a number (0, 1) specifying the timer.\n"
-       "* where <ACTION> is a string specifying the action  to be performed on the selected timer IRQ.\n"
        "\n"
-       "<ACTIONS> can be one of:\n"
-       "* EN - Enable the IRQ on the selected timer\n"
-       "* DIS - Disable the IRQ on the selected timer\n"
-       "* ACK - Acknowledge the IRQ on the selected timer (reset flag in the register).\n"
+       "- `<TMID>` is a number (0, 1) specifying the timer.\n"
+       "- where `<ACTION>` is a string specifying the action  to be performed on the selected timer IRQ.\n"
+       "\n"
+       "`<ACTIONS>` can be one of:\n"
        "\n"
-       "=== Description ===\n"
+       "- EN - Enable the IRQ on the selected timer\n"
+       "- DIS - Disable the IRQ on the selected timer\n"
+       "- ACK - Acknowledge the IRQ on the selected timer (reset flag in the register).\n"
+       "\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_EnableAbsoluteTimerIRQ,\n"
        "Fr_AckAbsoluteTimerIRQ, Fr_DisableAbsoluteTimerIRQ and\n"
@@ -2668,53 +2635,53 @@ cmd_des_t const cmd_des_fr_timerirq={
        "interrupt request. If no action is specified it prints whether the IRQ\n"
        "is pending for the timer.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbttimerirq0\n"
-       "   IRQ = FALSE\n"
+       "    --> frbttimerirq0\n"
+       "    IRQ = FALSE\n"
        "\n"
-       "   --> frbttimerirq0 EN\n"
-       "   OK\n",
+       "    --> frbttimerirq0 EN\n"
+       "    OK\n",
        CMD_HANDLER(cmd_do_fr_timerirq), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay get version info command */
-cmd_des_t const cmd_des_fr_getversioninfo={
+cmd_des_t const cmd_des_fr_getversioninfo = {
        0, 0,
        "frbtversion","Print FlexRay driver version information",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtversion\n"
+       "    frbtversion\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_GetVersionInfo function from the Autosar\n"
        "specification.\n"
        "It reads and prints the information about vendor, module and version of\n"
        "the FlexRay driver\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtversion\n"
-       "   vendorID: 0xAAAA\n"
-       "   moduleID: 0xBBBB\n"
-       "   sw_major_version: 0x1\n"
-       "   sw_minor_version: 0x2\n"
-       "   sw_patch_version: 0x4\n",
+       "    --> frbtversion\n"
+       "    vendorID: 0xAAAA\n"
+       "    moduleID: 0xBBBB\n"
+       "    sw_major_version: 0x1\n"
+       "    sw_minor_version: 0x2\n"
+       "    sw_patch_version: 0x4\n",
        CMD_HANDLER(cmd_do_fr_getversioninfo), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay get controller configuration command */
-cmd_des_t const cmd_des_fr_readcconfig={
+cmd_des_t const cmd_des_fr_readcconfig = {
        0, 0,
        "frbtccconfig*","Print value of a FlexRay cluster and node configuration parameter",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtccconfig<INDEX>\n"
+       "    frbtccconfig<INDEX>\n"
        "\n"
-       "where <INDEX> is an identifier of the parameter.\n"
+       "where `<INDEX>` is an identifier of the parameter.\n"
        "\n"
-       "=== Description ===\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_ReadCCConfig function from the Autosar\n"
        "specification. The driver stores the configuration parameters as an\n"
@@ -2723,29 +2690,30 @@ cmd_des_t const cmd_des_fr_readcconfig={
        "(http://www.autosar.org/download/R4.1/AUTOSAR_SWS_FlexRayDriver.pdf),\n"
        "section 8.2.1 for parameter indexes.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtccconfig1\n"
-       "   Value = 0x1\n",
+       "    --> frbtccconfig1\n"
+       "    Value = 0x1\n",
        CMD_HANDLER(cmd_do_fr_readcconfig), (void *)&cmd_list_fr_basic_test
 };
 
 /** Command descriptor for FlexRay reconfigure buffer command */
-cmd_des_t const cmd_des_fr_reconfigure_buffer={
+cmd_des_t const cmd_des_fr_reconfigure_buffer = {
        0, 0,
        "frbtreconfigurebuf*","Reconfigure a buffer to communicate in another slot",
-       "=== Command syntax ===\n"
+       "### Command syntax ###\n"
        "\n"
-       "   frbtreconfigurebuf id<ID> slot<SLOT> <CHN> cycset<CYCS> cycoffset<CYCO> max<MAX>\n"
+       "    frbtreconfigurebuf id<BUFID> slot<SLOT> <CHN> cycset<CYCS> cycoffset<CYCO> max<MAX>\n"
        "where\n"
-       "* <ID> is a number specifying a slot, where the buffer is currently communicating,\n"
-       "* <SLOT> is a number, where buffer will be communicating after the reconfiguration,\n"
-       "* <CHN> is one of 'A', 'B' or 'AB' and identifies the used channel,\n"
-       "* <CYCS> is the cycle set. It has to be one of 0, 1, 2, 4, 8, 16, 32, 64. It specifies together with <CYCO> the cycle filtering.\n"
-       "* <CYCO> is the cycle offset. It has to be in range 0 - <CYCS>-1"
-       "* <MAX> is the number determining the maximum payload (in hald-words).\n"
        "\n"
-       "=== Description ===\n"
+       "- `<BUFID>` is a number specifying a slot, where the buffer is currently communicating,\n"
+       "- `<SLOT>` is a number, where buffer will be communicating after the reconfiguration,\n"
+       "- `<CHN>` is one of 'A', 'B' or 'AB' and identifies the used channel,\n"
+       "- `<CYCS>` is the cycle set. It has to be one of 0, 1, 2, 4, 8, 16, 32, 64. It specifies together with `<CYCO>` the cycle filtering.\n"
+       "- `<CYCO>` is the cycle offset. It has to be in range 0 - `<CYCS>`-1"
+       "- `<MAX>` is the number determining the maximum payload (in hald-words).\n"
+       "\n"
+       "### Description ###\n"
        "\n"
        "The command stands for Fr_ReconfigLPDu function from the Autosar\n"
        "specification. It reconfigures specified buffer to communicate in\n"
@@ -2755,44 +2723,44 @@ cmd_des_t const cmd_des_fr_reconfigure_buffer={
        "are not reconfigurable.\n"
        "The command can be called any time when the communication is running.\n"
        "\n"
-       "=== Example ===\n"
+       "### Example ###\n"
        "\n"
-       "   --> frbtreconfigurebuf id2 slot3 AB cycset1 cycoffset0 max9\n"
-       "   frbtreconfigurebuf id2 slot3 AB cycset1 cycoffset0 max9\n",
+       "    --> frbtreconfigurebuf id2 slot3 AB cycset1 cycoffset0 max9\n"
+       "    frbtreconfigurebuf id2 slot3 AB cycset1 cycoffset0 max9\n",
        CMD_HANDLER(cmd_do_fr_reconfigure_buffer), (void *)&cmd_list_fr_basic_test
 };
 
 
 /** List of commands for flexRay, defined as external */
-cmd_des_t const *cmd_list_fr_basic_test[]={
-  &cmd_des_fr_user_config,
-  &cmd_des_fr_config_buffer,
-  &cmd_des_fr_config_fifo,
-  &cmd_des_fr_init,
-  &cmd_des_fr_start,
-  &cmd_des_fr_allslots,
-  &cmd_des_fr_halt,
-  &cmd_des_fr_abort,
-  &cmd_des_fr_sendwup,
-  &cmd_des_fr_setwuchannel,
-  &cmd_des_fr_getpocstatus,
-  &cmd_des_fr_transmittxlpdu,
-  &cmd_des_fr_canceltxlpdu,
-  &cmd_des_fr_receiverxlpdu,
-  &cmd_des_fr_checktxlpdustatus,
-  &cmd_des_fr_disablelpdu,
-  &cmd_des_fr_getglobaltime,
-  &cmd_des_fr_getnmvector,
-  &cmd_des_fr_nmwatch,
-  &cmd_des_fr_getchannelstatus,
-  &cmd_des_fr_getclockcorrection,
-  &cmd_des_fr_getsyncframelist,
-  &cmd_des_fr_getwakeuprxstatus,
-  &cmd_des_fr_settimer,
-  &cmd_des_fr_canceltimer,
-  &cmd_des_fr_timerirq,
-  &cmd_des_fr_getversioninfo,
-  &cmd_des_fr_readcconfig,
-  &cmd_des_fr_reconfigure_buffer,
-  NULL
+cmd_des_t const *cmd_list_fr_basic_test[] = {
+       &cmd_des_fr_user_config,
+       &cmd_des_fr_config_buffer,
+       &cmd_des_fr_config_fifo,
+       &cmd_des_fr_init,
+       &cmd_des_fr_start,
+       &cmd_des_fr_allslots,
+       &cmd_des_fr_halt,
+       &cmd_des_fr_abort,
+       &cmd_des_fr_sendwup,
+       &cmd_des_fr_setwuchannel,
+       &cmd_des_fr_getpocstatus,
+       &cmd_des_fr_transmittxlpdu,
+       &cmd_des_fr_canceltxlpdu,
+       &cmd_des_fr_receiverxlpdu,
+       &cmd_des_fr_checktxlpdustatus,
+       &cmd_des_fr_disablelpdu,
+       &cmd_des_fr_getglobaltime,
+       &cmd_des_fr_getnmvector,
+       &cmd_des_fr_nmwatch,
+       &cmd_des_fr_getchannelstatus,
+       &cmd_des_fr_getclockcorrection,
+       &cmd_des_fr_getsyncframelist,
+       &cmd_des_fr_getwakeuprxstatus,
+       &cmd_des_fr_settimer,
+       &cmd_des_fr_canceltimer,
+       &cmd_des_fr_timerirq,
+       &cmd_des_fr_getversioninfo,
+       &cmd_des_fr_readcconfig,
+       &cmd_des_fr_reconfigure_buffer,
+       NULL
 };