diff options
| author | Avi Levkovich <avi@twine-s.com> | 2018-08-05 11:20:36 +0300 |
|---|---|---|
| committer | Avi Levkovich <avi@twine-s.com> | 2018-08-05 11:20:36 +0300 |
| commit | 898213e7a5380bea18e5b45ef48b4d2d990b4832 (patch) | |
| tree | c0067b6a26ad3853681c9151e1fe9fc5ac5503c6 /Software/Embedded_SW/Embedded/Modules | |
| parent | 3f78570409abd79e46dcb0bfe8f8e2127cc7f67c (diff) | |
| parent | 9cdd202a86fec153935637fc43eef428fced2fd6 (diff) | |
| download | Tango-898213e7a5380bea18e5b45ef48b4d2d990b4832.tar.gz Tango-898213e7a5380bea18e5b45ef48b4d2d990b4832.zip | |
merge conflict
Diffstat (limited to 'Software/Embedded_SW/Embedded/Modules')
| -rw-r--r-- | Software/Embedded_SW/Embedded/Modules/Diagnostics/DiagnosticsHoming.c | 11 | ||||
| -rw-r--r-- | Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c | 6 |
2 files changed, 7 insertions, 10 deletions
diff --git a/Software/Embedded_SW/Embedded/Modules/Diagnostics/DiagnosticsHoming.c b/Software/Embedded_SW/Embedded/Modules/Diagnostics/DiagnosticsHoming.c index b70c5a744..9760b1715 100644 --- a/Software/Embedded_SW/Embedded/Modules/Diagnostics/DiagnosticsHoming.c +++ b/Software/Embedded_SW/Embedded/Modules/Diagnostics/DiagnosticsHoming.c @@ -170,7 +170,7 @@ uint32_t DispenserHomingRequestFunc(MessageContainer* requestContainer) Valve_Set((Valves_t) (request->index+VALVE_2W_MID_AIR_LF), Atm_MidTank_ON); - MotorMovetoLimitSwitch (MotorId,1-MotorsCfg[MotorId].directionthreadwize, /*request->speed*/1200, Motor_Id_to_LS_Id[MotorId], DispenserHomingRequestCallback); + MotorMovetoLimitSwitch (MotorId,1-MotorsCfg[MotorId].directionthreadwize, /*request->speed*/1000, Motor_Id_to_LS_Id[MotorId], DispenserHomingRequestCallback); ustrncpy (HomingToken[MotorId], requestContainer->token,36); return OK; } @@ -254,20 +254,17 @@ uint32_t DispenserJoggingRequestFunc(MessageContainer* requestContainer) { if (JobIsActive() == false) { - if (request->has_direction) + switch (request->direction) { - switch (request->direction) - { case MOTOR_DIRECTION__Forward: Control3WayValvesWithCallback ((Valves_t) request->index, Dispenser_Mixer, NULL); //direction: MidTank_Dispenser or Dispenser_Mixer break; case MOTOR_DIRECTION__Backward: Control3WayValvesWithCallback ((Valves_t) request->index, MidTank_Dispenser, NULL); //direction: MidTank_Dispenser or Dispenser_Mixer break; - } - MotorSetDirection(MotorId,request->direction); - MotorSetSpeed(MotorId, /*request->speed*/150); } + MotorSetDirection(MotorId,request->direction); + MotorSetSpeed(MotorId, /*request->speed*/150); } else { diff --git a/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c b/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c index 8d1ea20fa..75d54ef02 100644 --- a/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c +++ b/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c @@ -127,8 +127,8 @@ void ThreadUpdateProcessLength (double length, void *Funcptr) ProcessedLengthFuncPtr = (ProcessedLengthFunc)Funcptr; initialpos = 0xFFFF; } -double MotorSentData[102] = {0}; -uint32_t PosDif[102] = {0}; +double MotorSentData[100] = {0}; +uint32_t PosDif[100] = {0}; int MotorDataIndex = 0; @@ -181,7 +181,7 @@ uint32_t ThreadLengthCBFunction(uint32_t IfIndex, uint32_t ReadValue) //PosDif[MotorDataIndex] = positionDiff; MotorSentData[MotorDataIndex] = length; MotorDataIndex+=1; - if (MotorDataIndex >= 97) MotorDataIndex = 0; + if (MotorDataIndex == 99) MotorDataIndex = 0; static int pooler_counter = 0; pooler_counter++; TotalProcessedLength+= (length/100); |
