aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Embedded_SW/Embedded/Modules
diff options
context:
space:
mode:
authorShlomo Hecht <shlomo@twine-s.com>2018-03-19 15:51:40 +0200
committerShlomo Hecht <shlomo@twine-s.com>2018-03-19 15:51:40 +0200
commit8357cc0350ad2b92c69fd20b8dac7e87014f0e34 (patch)
treea896a3f177dadb3c67f64cd5a41811016cfdf2a1 /Software/Embedded_SW/Embedded/Modules
parentace16e89b777d94d9a655fef27aa58c763f5b378 (diff)
downloadTango-8357cc0350ad2b92c69fd20b8dac7e87014f0e34.tar.gz
Tango-8357cc0350ad2b92c69fd20b8dac7e87014f0e34.zip
updating to the latest PMR
Diffstat (limited to 'Software/Embedded_SW/Embedded/Modules')
-rw-r--r--Software/Embedded_SW/Embedded/Modules/IDS/IDS_init.c2
-rw-r--r--Software/Embedded_SW/Embedded/Modules/Thread/Thread.h13
-rw-r--r--Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c18
3 files changed, 18 insertions, 15 deletions
diff --git a/Software/Embedded_SW/Embedded/Modules/IDS/IDS_init.c b/Software/Embedded_SW/Embedded/Modules/IDS/IDS_init.c
index d575b0b6e..db4dbb1f0 100644
--- a/Software/Embedded_SW/Embedded/Modules/IDS/IDS_init.c
+++ b/Software/Embedded_SW/Embedded/Modules/IDS/IDS_init.c
@@ -12,7 +12,7 @@
DispenserConfigStruc DispensersCfg[ MAX_SYSTEM_DISPENSERS];
-uint32_t DispenserIdToMotorId[MAX_SYSTEM_DISPENSERS] = {MOTOR_DISPENSER_1,MOTOR_DISPENSER_2,MOTOR_DISPENSER_3,MOTOR_DISPENSER_4,MOTOR_DISPENSER_5,MOTOR_DISPENSER_6,MOTOR_DISPENSER_7,MOTOR_DISPENSER_8,};
+uint32_t DispenserIdToMotorId[MAX_SYSTEM_DISPENSERS] = {MOTOR_DISPENSER_1,MOTOR_DISPENSER_2,MOTOR_DISPENSER_3,MOTOR_DISPENSER_4,MOTOR_DISPENSER_5,MOTOR_DISPENSER_6,MOTOR_DISPENSER_7,MOTOR_DISPENSER_8};
diff --git a/Software/Embedded_SW/Embedded/Modules/Thread/Thread.h b/Software/Embedded_SW/Embedded/Modules/Thread/Thread.h
index f0dd35da9..f568f9816 100644
--- a/Software/Embedded_SW/Embedded/Modules/Thread/Thread.h
+++ b/Software/Embedded_SW/Embedded/Modules/Thread/Thread.h
@@ -45,7 +45,18 @@ typedef struct
int32_t pulsepermmspring;
int id; //HardwareDancerType
}DancerConfigStruc;
-#define MAX_THREAD_MOTORS_NUM HARDWARE_MOTOR_TYPE__WinderMotor +1
+
+typedef enum threadMotorsEnum
+{
+ FEEDER_MOTOR,
+ DRYER_MOTOR,
+ POOLER_MOTOR,
+ WINDER_MOTOR,
+ SCREW_MOTOR,
+ MAX_THREAD_MOTORS_NUM
+}threadMotorsEnum;
+
+extern uint32_t ThreadMotorIdToMotorId[MAX_THREAD_MOTORS_NUM];
extern MotorConfigStruc MotorsCfg[MAX_THREAD_MOTORS_NUM];
diff --git a/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c b/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c
index 44e5c8936..89ff63363 100644
--- a/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c
+++ b/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c
@@ -26,6 +26,9 @@ typedef enum
Stop
} ReturnCode;
+
+uint32_t ThreadMotorIdToMotorId[MAX_THREAD_MOTORS_NUM] = {MOTOR_RDRIVING,MOTOR_DRYER_DRIVING,MOTOR_LDRIVING,MOTOR_WINDER,MOTOR_SCREW};
+
/********************************************************************************************
* functions describes motor operation flow and movement state during profile execution
* used to operate in runtime correct profileflow execution
@@ -282,20 +285,9 @@ bool ThreadPrintingIterate(void *JobDetails)
// screw_movement[gPrintingState[_motorId]]++;
ReturnCode returnCode = state_fun(JobDetails);
- /*if ((_motorId == SCREW_MOTOR)&&(pause_active))
- {
- tick = UsersysTickGet();
- len = usnprintf(str, 60, "\r\n PrintingIterate tick %d state %d retcode %d ",tick, gPrintingState[_motorId],returnCode);
- cb_push_back (str, len);
- //SendInterruptMessageToHost(10+gPrintingState[_motorId],returnCode);
- }*/
gPrintingState = LookupTransitions(gPrintingState, returnCode);
- if (keepstate != gPrintingState){
- tick = UsersysTickGet();
- len = usnprintf(str, 60, "\r\n changed state tick %d state %d retcode %d ", tick, gPrintingState,returnCode);
- cb_push_back (str, len);
-
- }
+// if (keepstate != gPrintingState){
+// }
//
// Enable all interrupts.