aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Embedded_SW/Embedded/Modules/Thread
diff options
context:
space:
mode:
Diffstat (limited to 'Software/Embedded_SW/Embedded/Modules/Thread')
-rw-r--r--Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c b/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c
index 22f54eb50..ac6dd1969 100644
--- a/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c
+++ b/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c
@@ -5,6 +5,7 @@
* operating the dispensers according to predefined dispensing rate from the UI
**************************************************************************************************************************/
#include "include.h"
+#include <DataDef.h>
#include "thread.h"
#include "thread_ex.h"
#include "../control/control.h"
@@ -316,12 +317,12 @@ uint32_t ThreadControlSpeedReadFunction(uint32_t IfIndex, uint32_t ReadValue)
//double eNormalizedError[100];
//int TranslatedreadValue[100];
#define MAX_THREAD_CONTROL_LOG 500
-double calculatedError[MAX_THREAD_CONTROL_LOG];
-int MotorId[MAX_THREAD_CONTROL_LOG];
-int readValue[MAX_THREAD_CONTROL_LOG];
-int AveragereadValue[MAX_THREAD_CONTROL_LOG];
-int calculatedspeed[MAX_THREAD_CONTROL_LOG];
-int timestamp[MAX_THREAD_CONTROL_LOG];
+double calculatedError[MAX_THREAD_CONTROL_LOG+1];
+int MotorId[MAX_THREAD_CONTROL_LOG+1];
+int readValue[MAX_THREAD_CONTROL_LOG+1];
+int AveragereadValue[MAX_THREAD_CONTROL_LOG+1];
+int calculatedspeed[MAX_THREAD_CONTROL_LOG+1];
+int timestamp[MAX_THREAD_CONTROL_LOG+1];
int controlIndex = 0;
bool keepdata = true;
/*int32_t KeepReadValue = 0;