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

Work on the look and feel of my interface.

parent ccb3c724
No related branches found
No related tags found
1 merge request!17Malaurie's work on UI + CLI interface + AccelStepper interface
...@@ -25,15 +25,12 @@ void web_setup () ...@@ -25,15 +25,12 @@ void web_setup ()
syringe_filled_placement = ESPUI.addControl(ControlType::Switcher, "Mise en marche", "Arrêt", ControlColor::None, status_syringe_filled, syringe_filled_placement_callback, (void*)19); syringe_filled_placement = ESPUI.addControl(ControlType::Switcher, "Mise en marche", "Arrêt", ControlColor::None, status_syringe_filled, syringe_filled_placement_callback, (void*)19);
ESPUI.addControl(ControlType::Separator, "", "", ControlColor::None);
//***Initialisation***// //***Initialisation***//
initialisation = ESPUI.button("Initialisation", initialisation_callback, ControlColor::None, ""); initialisation = ESPUI.button("Initialisation", initialisation_callback, ControlColor::None, "");
//Deplacement demandé du pousse-seringue
position_choice = ESPUI.number("Choix du volume à echanger", position_choice_callback, ControlColor::None, 0, 0, 50, (void*)19);
label_push_pull_choice = ESPUI.addControl(ControlType::Label, "Delivrer ou recupérer", "Délivrer", ControlColor::None, position_choice);
switch_push_pull_choice = ESPUI.addControl(ControlType::Switcher, "Delivrer ou recupérer", "Délivrer", ControlColor::None, position_choice, switch_push_pull_choice_callback, (void*)19);
ESPUI.updateSwitcher(switch_push_pull_choice, true); //pour mettre a "Delivrer" par défaut au début
//Volume restant //Volume restant
label_remaining_volume = ESPUI.label("Volume restant en mL", ControlColor::None, "Volume restant en mL"); label_remaining_volume = ESPUI.label("Volume restant en mL", ControlColor::None, "Volume restant en mL");
...@@ -46,21 +43,29 @@ void web_setup () ...@@ -46,21 +43,29 @@ void web_setup ()
//TAB1 = Configurations //TAB1 = Configurations
//Choix de la seringue 1 //Choix de la seringue 1
ESPUI.addControl(ControlType::Separator, "Seringue 1", "", ControlColor::None, tab1); //ESPUI.addControl(ControlType::Separator, "Seringue 1", "", ControlColor::None, tab1);
select_syringe_maj(tab1); select_syringe_maj(tab1);
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, tab1);
syringe_brand =ESPUI.addControl( ControlType::Label, "Caractéristiques de la seringue 1 : ", "Marque : ? " , ControlColor::None, syringe_ref); syringe_brand =ESPUI.addControl( ControlType::Label, "Caractéristiques de la seringue 1 : ", "Marque : ? " , ControlColor::None, syringe_ref);
syringe_volume =ESPUI.addControl( ControlType::Label, "Caractéristiques de la seringue 1 : ", "Volume total = ? mL" , ControlColor::None, syringe_ref); syringe_volume =ESPUI.addControl( ControlType::Label, "Caractéristiques de la seringue 1 : ", "Volume total = ? mL" , ControlColor::None, syringe_ref);
syringe_diameter =ESPUI.addControl( ControlType::Label, "Caractéristiques de la seringue 1 : ", "Diamètre interne = ? mm" , ControlColor::None, syringe_ref); syringe_diameter =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);
choose_syringe = ESPUI.addControl(ControlType::Button, "Choisir cette seringue", "Valider", ControlColor::None, syringe_selection, choose_syringe_callback, (void*)19);
ESPUI.addControl(ControlType::Separator, "", "", ControlColor::None, tab1);
//Deplacement demandé du pousse-seringue
position_choice = ESPUI.addControl(ControlType::Number,"Choix du volume à echanger en mL", "", ControlColor::None, tab1, position_choice_callback, (void*)19);
label_push_pull_choice = ESPUI.addControl(ControlType::Label, "Delivrer ou recupérer", "Délivrer", ControlColor::None, position_choice);
switch_push_pull_choice = ESPUI.addControl(ControlType::Switcher, "Delivrer ou recupérer", "Délivrer", ControlColor::None, position_choice, switch_push_pull_choice_callback, (void*)19);
ESPUI.updateSwitcher(switch_push_pull_choice, true); //pour mettre a "Delivrer" par défaut au début
//TAB3 : Nouvelle seringue //TAB3 : Nouvelle seringue
name_new_syringe_label = ESPUI.addControl(ControlType::Label, "Nouvelle seringue", "Nom de la seringue :", ControlColor::None, tab3); name_new_syringe_label = ESPUI.addControl(ControlType::Label, "Nouvelle seringue", "Nom de la seringue :", ControlColor::None, tab3);
......
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