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

Changing names of tab1, tab3 and tab4

parent 0d763f1d
No related branches found
No related tags found
1 merge request!17Malaurie's work on UI + CLI interface + AccelStepper interface
......@@ -9,9 +9,9 @@ void web_setup ()
//Create tabs
uint16_t tab1 = ESPUI.addControl(ControlType::Tab, "Configurations", "Configurations");
uint16_t tab3 = ESPUI.addControl(ControlType::Tab, "Nouvelle Seringue", "Nouvelle seringue");
uint16_t tab4 = ESPUI.addControl(ControlType::Tab, "Caracteristiques du pousse-seringue", "Caracteristiques du pousse-seringue");
uint16_t configurations = ESPUI.addControl(ControlType::Tab, "Configurations", "Configurations");
uint16_t new_syringe = ESPUI.addControl(ControlType::Tab, "Nouvelle Seringue", "Nouvelle seringue");
uint16_t features = ESPUI.addControl(ControlType::Tab, "Caracteristiques du pousse-seringue", "Caracteristiques du pousse-seringue");
//***ABOVE***//
......@@ -40,27 +40,27 @@ void web_setup ()
ESPUI.sliderContinuous = true;
//TAB1 = Configurations
//Configurations
//Choix de la seringue 1
//ESPUI.addControl(ControlType::Separator, "Seringue 1", "", ControlColor::None, tab1);
//ESPUI.addControl(ControlType::Separator, "Seringue 1", "", ControlColor::None, configurations);
select_syringe_maj(tab1);
select_syringe_maj(configurations);
//tests
float diametre = 10;
std::string temp = "internal diameter : " + std::to_string(diametre);
syringe_ref = ESPUI.addControl( ControlType::Label, "Caractéristiques de la seringue 1 : ", "Reférence : ? " , ControlColor::None, tab1);
syringe_ref = ESPUI.addControl( ControlType::Label, "Caractéristiques de la seringue 1 : ", "Reférence : ? " , ControlColor::None, configurations);
syringe_brand =ESPUI.addControl( ControlType::Label, "Caractéristiques de la seringue 1 : ", "Marque : ? " , ControlColor::None, syringe_ref);
syringe_volume_mL =ESPUI.addControl( ControlType::Label, "Caractéristiques de la seringue 1 : ", "Volume total = ? mL" , ControlColor::None, syringe_ref);
syringe_diameter_mm =ESPUI.addControl( ControlType::Label, "Caractéristiques de la seringue 1 : ", temp.c_str(), ControlColor::None, syringe_ref);
choose_syringe = ESPUI.addControl(ControlType::Button, "Choisir cette seringue", "Utiliser cette seringue", ControlColor::None, syringe_selection, choose_syringe_callback, (void*)19);
ESPUI.addControl(ControlType::Separator, "", "", ControlColor::None, tab1);
ESPUI.addControl(ControlType::Separator, "", "", ControlColor::None, configurations);
//Deplacement demandé du pousse-seringue
volume_exchange_mL = ESPUI.addControl(ControlType::Number,"Choix du volume à echanger en mL", "", ControlColor::None, tab1, volume_exchange_mL_callback, (void*)19);
volume_exchange_mL = ESPUI.addControl(ControlType::Number,"Choix du volume à echanger en mL", "", ControlColor::None, configurations, volume_exchange_mL_callback, (void*)19);
label_push_pull_choice = ESPUI.addControl(ControlType::Label, "Delivrer ou recupérer", "Délivrer", ControlColor::None, volume_exchange_mL);
......@@ -68,8 +68,8 @@ void web_setup ()
ESPUI.updateSwitcher(switch_push_pull_choice, true); //pour mettre a "Delivrer" par défaut au début
//TAB3 : Nouvelle seringue
name_new_syringe_label = ESPUI.addControl(ControlType::Label, "Nouvelle seringue", "Nom de la seringue :", ControlColor::None, tab3);
//new_syringe : Nouvelle seringue
name_new_syringe_label = ESPUI.addControl(ControlType::Label, "Nouvelle seringue", "Nom de la seringue :", ControlColor::None, new_syringe);
name_new_syringe = ESPUI.addControl(ControlType::Text, "Nouvelle seringue", "", ControlColor::None, name_new_syringe_label, name_new_syringe_callback);
internal_diameter_mm_new_syringe_label =ESPUI.addControl(ControlType::Label, "Nouvelle seringue", "Diamètre interne de la seringue en mm :", ControlColor::None, name_new_syringe_label);
internal_diameter_mm_new_syringe = ESPUI.addControl(ControlType::Number, "Diamètre interne de la seringue en mm", "5", ControlColor::None, name_new_syringe_label, number_callback);
......@@ -79,11 +79,11 @@ void web_setup ()
add_syringe = ESPUI.addControl(ControlType::Button, "Ajouter la seringue", "Valider", ControlColor::None, name_new_syringe_label, add_syringe_callback, (void*)19);
//TAB4 : Configurations avancées
//features : Configurations avancées
//Diamètre de la vis
worm_diameter_mm = ESPUI.addControl(ControlType::Number, "Diamètre de la vis sans fin", "5", ControlColor::None, tab4, number_callback);
worm_diameter_mm = ESPUI.addControl(ControlType::Number, "Diamètre de la vis sans fin", "5", ControlColor::None, features, number_callback);
//Sens de rotation du moteur
clockwise_equals_push_label = ESPUI.addControl(ControlType::Label, "Sens de rotation du moteur", "Horaire = Delivrer", ControlColor::None, tab4);
clockwise_equals_push_label = ESPUI.addControl(ControlType::Label, "Sens de rotation du moteur", "Horaire = Delivrer", ControlColor::None, features);
clockwise_equals_push = ESPUI.addControl(ControlType::Switcher, "Sens de rotation du moteur", "Horaire =", ControlColor::None, clockwise_equals_push_label, clockwise_equals_push_callback);
ESPUI.updateSwitcher(clockwise_equals_push, true); //pour mettre a "Horaire = Delivrer" par défaut au début
......@@ -235,7 +235,7 @@ void remaining_volume_mL_callback (Control* sender, int value, void* param)
}
//TAB1 = Configurations
//configurations = Configurations
void choose_syringe_callback (Control* sender, int value, void* param)
/***
......@@ -295,7 +295,7 @@ void add_syringe_callback (Control* sender, int value, void* param)
//TAB4 : Configurations avancées
//features : Configurations avancées
void clockwise_equals_push_callback(Control* sender, int value)
/***
......@@ -483,7 +483,7 @@ void set_init_style()
style (label_remaining_volume_mL, 3);
//TAB1 = Configurations
//configurations = Configurations
style (syringe_ref, 3);
style (syringe_brand, 3);
style (syringe_volume_mL, 3);
......@@ -501,7 +501,7 @@ void set_init_style()
style (add_syringe_label, 3);
//TAB4 : Configurations avancées
//features : Configurations avancées
style (worm_diameter_mm, 3);
style (clockwise_equals_push_label, 3);
......
......@@ -30,14 +30,14 @@ uint16_t volume_exchange_mL, label_push_pull_choice, switch_push_pull_choice;
uint16_t label_remaining_volume_mL;
//TAB1 = Configurations
//configurations = Configurations
uint16_t syringe_selection, syringe_ref, syringe_brand, syringe_volume_mL, syringe_diameter_mm, choose_syringe;
//TAB3 : Nouvelle seringue
//new_syringe : Nouvelle seringue
uint16_t name_new_syringe, name_new_syringe_label, internal_diameter_mm_new_syringe, internal_diameter_mm_new_syringe_label, total_volume_mL_new_syringe, total_volume_mL_new_syringe_label, add_syringe, add_syringe_label;
//TAB4 : Configurations avancées
//features : Configurations avancées
uint16_t worm_diameter_mm, clockwise_equals_push_label, clockwise_equals_push;
......@@ -85,12 +85,12 @@ void volume_exchange_mL_callback (Control* sender, int value, void* param);
void switch_push_pull_choice_callback (Control* sender, int value, void* param);
void remaining_volume_mL_callback (Control* sender, int value, void* param);
//TAB1 = Configurations
//Configurations
void choose_syringe_callback (Control* sender, int value, void* param);
void name_new_syringe_callback(Control* sender, int type);
void add_syringe_callback (Control* sender, int value, void* param);
//TAB4 : Configurations avancées
//features : Configurations avancées
void clockwise_equals_push_callback(Control* sender, int value);
//
......
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