diff --git a/syringe.cpp b/syringe.cpp index 17189c4e0ecbee4fd29e5a1c4b56c343d620c174..f0a29233ab63a6ac19f361fb325eb24e4451f478 100644 --- a/syringe.cpp +++ b/syringe.cpp @@ -29,7 +29,6 @@ void Syringe::showConfiguration (const Syringe_configuration_t& conf) mm3ToMm(conf.rate_ul_per_s), conf.volume_value * conf.volume_unit_ul, conf.direction > 0? "infuse": "withdraw", - conf.findZero, emergency(), stepToMm(step), mmToMm3(stepToMm(step)), step); //Current position of syringe pump in terms of displacement, volume and motor pitch } @@ -142,7 +141,6 @@ void Syringe::findZero (float mmPerSec, float maxCourseMm) setSpeedMmPerSec(mm3ToMm(current_configuration.rate_ul_per_s)); resetPosition(); moveToMm(-maxCourseMm); - current_configuration.findZero = true; } void Syringe::runFromEmergency (float mmPerSec, float maxCourseMm) @@ -154,7 +152,6 @@ void Syringe::runFromEmergency (float mmPerSec, float maxCourseMm) { if (emergency()) { - current_configuration.findZero = true; Serial.printf("EMERGENCY: running away slowly\n"); setSpeedMmPerSec(mmPerSec); resetPosition(); @@ -169,7 +166,6 @@ void Syringe::resetPosition () -Action : Changes the zero position as the current one ***/ { - //current_configuration.findZero = false; Motor::resetPosition(); } diff --git a/syringe.h b/syringe.h index 963f5c81be923d692a42c8a9252b0168a1b26975..45b2ead615987cd05299049506fc76b775ad6260 100644 --- a/syringe.h +++ b/syringe.h @@ -17,7 +17,6 @@ public: float volume_value; // see volume_unit_ul /***************************a quoi sert cette variable ? pk pas avoir directement fait volume_in_ul**************/ float volume_unit_ul; // volume in ul = volume_value * volume_unit_ul int direction; - bool findZero; //to know when we are initializing the pump position } Syringe_configuration_t; @@ -103,7 +102,6 @@ private: .volume_value = 50, .volume_unit_ul = 1, .direction = 1, // 1 = push, -1 = pull - .findZero = false, }; bool is_configured = false;