Skip to content
Snippets Groups Projects
Commit c0c9ea5d authored by Malaurie Bernard's avatar Malaurie Bernard
Browse files

Rename id to id_Syringe in class SyringeFilled to be more precise.

parent e753a763
No related branches found
No related tags found
1 merge request!17Malaurie's work on UI + CLI interface + AccelStepper interface
...@@ -23,8 +23,8 @@ void SyringeFilled :: set_push(bool push) ...@@ -23,8 +23,8 @@ void SyringeFilled :: set_push(bool push)
SyringeFilledJSON["push"] = push; SyringeFilledJSON["push"] = push;
} }
void SyringeFilled :: set_id(int* id){ void SyringeFilled :: set_id_syringe(int* id_syringe){
SyringeFilledJSON["id"] = id; SyringeFilledJSON["id_syringe"] = id_syringe;
} }
...@@ -49,14 +49,14 @@ bool SyringeFilled :: get_push() ...@@ -49,14 +49,14 @@ bool SyringeFilled :: get_push()
return SyringeFilledJSON["push"].as<bool>(); return SyringeFilledJSON["push"].as<bool>();
} }
int* SyringeFilled :: get_id() int* SyringeFilled :: get_id_syringe()
{ {
return SyringeFilledJSON["id"].as<int*>(); return SyringeFilledJSON["id_syringe"].as<int*>();
} }
void SyringeFilled :: setupJsonSyringeFilled(float exchange_throughput_uL_per_sec, float exchange_volume_mL, float remaining_volume_mL, bool push, int* id) void SyringeFilled :: setupJsonSyringeFilled(float exchange_throughput_uL_per_sec, float exchange_volume_mL, float remaining_volume_mL, bool push, int* id_syringe)
{ {
//ADD INITIALISATION VALUES TO THE DOC //ADD INITIALISATION VALUES TO THE DOC
...@@ -64,7 +64,7 @@ void SyringeFilled :: setupJsonSyringeFilled(float exchange_throughput_uL_per_se ...@@ -64,7 +64,7 @@ void SyringeFilled :: setupJsonSyringeFilled(float exchange_throughput_uL_per_se
SyringeFilledJSON["exchange_volume_mL"] = exchange_volume_mL; SyringeFilledJSON["exchange_volume_mL"] = exchange_volume_mL;
SyringeFilledJSON["remaining_volume_mL"] = remaining_volume_mL; SyringeFilledJSON["remaining_volume_mL"] = remaining_volume_mL;
SyringeFilledJSON["push"] = push; SyringeFilledJSON["push"] = push;
SyringeFilledJSON["id"] = SyringeJSON["id"]; SyringeFilledJSON["id_syringe"] = SyringeJSON["id"];
//GENERATE THE MINIFIED JSON AND SEND IT TO THE SERIAL PORT //GENERATE THE MINIFIED JSON AND SEND IT TO THE SERIAL PORT
......
...@@ -13,7 +13,7 @@ class SyringeFilled : Motor ...@@ -13,7 +13,7 @@ class SyringeFilled : Motor
float _exchange_volume_mL; float _exchange_volume_mL;
float _remaining_volume_mL; float _remaining_volume_mL;
bool _push; //false means pull bool _push; //false means pull
int* _id; int* _id_syringe;
public : public :
...@@ -23,7 +23,7 @@ class SyringeFilled : Motor ...@@ -23,7 +23,7 @@ class SyringeFilled : Motor
void set_exchange_volume_mL(float exchange_volume_mL); void set_exchange_volume_mL(float exchange_volume_mL);
void set_remaining_volume_mL(float remaining_volume_mL); void set_remaining_volume_mL(float remaining_volume_mL);
void set_push(bool push); void set_push(bool push);
void set_id(int* id); void set_id_syringe(int* id_syringe);
//GET METHODS //GET METHODS
...@@ -31,13 +31,13 @@ class SyringeFilled : Motor ...@@ -31,13 +31,13 @@ class SyringeFilled : Motor
float get_exchange_volume_mL(); float get_exchange_volume_mL();
float get_remaining_volume_mL(); float get_remaining_volume_mL();
bool get_push(); bool get_push();
int* get_id(); int* get_id_syringe();
//JSON DOCUMENT //JSON DOCUMENT
StaticJsonDocument<200> SyringeFilledJSON; //200 = RAM allocated to this document StaticJsonDocument<200> SyringeFilledJSON; //200 = RAM allocated to this document
void setupJsonSyringeFilled(float exchange_throughput_uL_per_sec, float exchange_volume_mL, float remaining_volume_mL, bool push, int* id); void setupJsonSyringeFilled(float exchange_throughput_uL_per_sec, float exchange_volume_mL, float remaining_volume_mL, bool push, int* id_syringe);
}; };
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment