diff options
| author | Shlomo Hecht <shlomo@twine-s.com> | 2018-10-25 11:15:14 +0300 |
|---|---|---|
| committer | Shlomo Hecht <shlomo@twine-s.com> | 2018-10-25 11:15:14 +0300 |
| commit | 3aa08870dc50c19cfaa619d26f7c37610d950457 (patch) | |
| tree | 8179304c8f91a367613ab814c5e9c653e0ab8464 /Software/Embedded_SW/Embedded/Modules/Thread | |
| parent | 2eb5e880d44c358ef6a97232e90e77ea0ec582ae (diff) | |
| download | Tango-3aa08870dc50c19cfaa619d26f7c37610d950457.tar.gz Tango-3aa08870dc50c19cfaa619d26f7c37610d950457.zip | |
small corrections
Diffstat (limited to 'Software/Embedded_SW/Embedded/Modules/Thread')
| -rw-r--r-- | Software/Embedded_SW/Embedded/Modules/Thread/Thread_Winder.c | 3 | ||||
| -rw-r--r-- | Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c | 8 |
2 files changed, 4 insertions, 7 deletions
diff --git a/Software/Embedded_SW/Embedded/Modules/Thread/Thread_Winder.c b/Software/Embedded_SW/Embedded/Modules/Thread/Thread_Winder.c index 9e3bdb052..b00e2fca4 100644 --- a/Software/Embedded_SW/Embedded/Modules/Thread/Thread_Winder.c +++ b/Software/Embedded_SW/Embedded/Modules/Thread/Thread_Winder.c @@ -186,7 +186,6 @@ uint32_t CalculateNumberOfSteps (uint32_t Counter, bool direction) NumberOfSteps -= (Counter/InternalWinderCfg.spoolbackingrate); REPORT_MSG(ScrewNumberOfSteps, "Head Backing"); ScrewNumberOfSteps--; - /* screw speed adjustment is suspended screw_horizontal_speed = InternalWinderCfg.segmentoffsetpulses / InternalWinderCfg.NumberOfRotationPerPassage; // calculation input#2: number of rotations per second - (basically: speed/winder perimeter. later - according to winder actual speed - calculate according to winder position accumulation in the last second. RotationsPerSecond = dyeingspeed / (InternalWinderCfg.diameter * PI); @@ -197,7 +196,6 @@ uint32_t CalculateNumberOfSteps (uint32_t Counter, bool direction) MotorSetMaxSpeed (HARDWARE_MOTOR_TYPE__MOTO_SCREW,ScrewSpeed); REPORT_MSG(ScrewSpeed, "CalculateNumberOfSteps"); CurrentControlledSpeed[SCREW_MOTOR] = ScrewSpeed; - */ } if ((Counter%InternalWinderCfg.SpoolBottomBackingRate == 0)||(Counter%InternalWinderCfg.SpoolBottomBackingRate == 1)) @@ -337,7 +335,6 @@ uint32_t Winder_End(void) RemoveControlCallback(ScrewControlId,ScrewDirectionChange); CurrentControlledSpeed[SCREW_MOTOR] = 0; pend = MillisecFlushMsgQ(HARDWARE_MOTOR_TYPE__MOTO_SCREW); - //Screw_Interrupt(false,NULL); return MotorStop (HARDWARE_MOTOR_TYPE__MOTO_SCREW,Hard_Hiz); } void Winder_ScrewHomeLimitSwitchInterrupt(void) diff --git a/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c b/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c index f579ff6bc..6c58e1645 100644 --- a/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c +++ b/Software/Embedded_SW/Embedded/Modules/Thread/Thread_print.c @@ -467,17 +467,17 @@ uint32_t ThreadControlCBFunction(uint32_t IfIndex, uint32_t ReadValue) calculated_speed = (1-MotorControlConfig[index].m_calculatedError)*OriginalMotorSpd_2PPS[index]; if (abs(calculated_speed-CurrentControlledSpeed[index])>2) { - /*if (keepdata == true) + if (keepdata == true) { - calculatedError[controlIndex] = MotorControlConfig[index].m_calculatedError; + /* calculatedError[controlIndex] = MotorControlConfig[index].m_calculatedError; MotorId[controlIndex] = index; readValue[controlIndex] = ReadValue; AveragereadValue[controlIndex] = avreageSampleValue; calculatedspeed[controlIndex] = calculated_speed; timestamp[controlIndex] = HibernateRTCSSGet(); if (controlIndex++>=999) - controlIndex = 0; - }*/ + controlIndex = 0;*/ + } CurrentControlledSpeed[index] = calculated_speed; MotorSetSpeed(ThreadMotorIdToMotorId[index], calculated_speed); } |
