aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Embedded_SW/Embedded/Modules/Thread
diff options
context:
space:
mode:
authorShlomo Hecht <shlomo@twine-s.com>2018-11-11 17:42:09 +0200
committerShlomo Hecht <shlomo@twine-s.com>2018-11-11 17:42:09 +0200
commit777f4ccf2d081fc70a7800d7c42a9e58035c20ef (patch)
treeab31d3060a27529ff7ab3938baa9959aba5f4158 /Software/Embedded_SW/Embedded/Modules/Thread
parente180cdba61271dde09bd26c0dd5879648fe13933 (diff)
parent6eb3026ffcb3f10c832ae80b92b0936a19954750 (diff)
downloadTango-777f4ccf2d081fc70a7800d7c42a9e58035c20ef.tar.gz
Tango-777f4ccf2d081fc70a7800d7c42a9e58035c20ef.zip
Merge branch 'master' of https://twinetfs.visualstudio.com/Tango/_git/Tango
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;