]> rtime.felk.cvut.cz Git - pes-rpp/rpp-lib.git/commitdiff
Maximum sync frame list length defined as macro to be easily accessible outside the...
authorMichal Horn <hornmich@fel.cvut.cz>
Wed, 7 Aug 2013 16:22:47 +0000 (18:22 +0200)
committerMichal Sojka <sojkam1@fel.cvut.cz>
Fri, 9 Aug 2013 12:35:59 +0000 (14:35 +0200)
rpp/include/drv/fr_tms570.h
rpp/src/drv/fr_tms570.c

index e60dc3eae59e28b55d2a62d9efe1fe21cdc74711..584f256b7c3c6a3b3cbdd5d793f69defd869d1a6 100644 (file)
@@ -53,6 +53,8 @@
 #define cVotingSamples 5                       /**< Numbers of samples in the voting window used for majority voting of the RxD input. */
 #define cVotingDelay (cVotingSamples-1)/2      /**< Number of samples of delay between the RxD input and the majority voted output in the glitch-free case. */
 
+#define FR_MAX_SYNC_FRAME_LIST_SIZE    15
+
 /* Flags for indicating error during parameters check */
 #define ERR_PARAM_NO_ERROR                                             0
 /* Global parameters errors */
index 6dec973a44bcfb04c7754c29d974646f8cf4f05e..afce19552e0d51491dbe3f72ff15398f85a73194 100644 (file)
@@ -1475,8 +1475,8 @@ Std_ReturnType Fr_GetSyncFrameList(uint8_t Fr_CtrlIdx, uint8_t Fr_ListSize, uint
        }
 #endif
 
-       if (Fr_ListSize > 15) { // Limit list size to 15
-               Fr_ListSize = 15;
+       if (Fr_ListSize > FR_MAX_SYNC_FRAME_LIST_SIZE) { // Limit list size to 15
+               Fr_ListSize = FR_MAX_SYNC_FRAME_LIST_SIZE;
        }
 
        for (i = 0; i < Fr_ListSize; i++) {