#pragma once #include <DNSServer.h> #include <ESPUI.h> // https://github.com/s00500/ESPUI #include <ArduinoJson.h> #include "common.h" #include "syringe.h" #include "syringefilled.h" #include <EEPROM.h> #define syringe_pump_length_mm 50 //Create tabs uint16_t configurations, new_syringe, features; //***ABOVE***// int status_syringe_pump; uint16_t activation_syringe_pump; int status_syringe_filled; uint16_t syringe_filled_placement; uint16_t initialisation; uint16_t volume_exchange_mL, label_push_pull_choice, switch_push_pull_choice; uint16_t label_remaining_volume_mL; uint16_t remaining_volume_mL; //Configurations uint16_t syringe_selection, syringe_ref, syringe_brand, syringe_volume_mL, syringe_diameter_mm, choose_syringe; //New_syringe 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; String name_new_syringe_value, total_volume_mL_new_syringe_value, internal_diameter_mm_new_syringe_value; //Features uint16_t worm_diameter_mm, clockwise_equals_push_label, clockwise_equals_push; //Other String select_value; char couleur1[30], couleur2[30], couleur3[30], couleur4[30], couleur5[30], couleur6[30], couleur7[30], couleur8[30], couleur9[30], couleur10[30]; long unsigned last_time = 0; // Couleurs à utiliser const char* couleurs[] = { couleur1, couleur2, couleur3, couleur4, couleur5, couleur6, couleur7, couleur8, couleur9, couleur10 }; /************CALLBACK_METHODS****************/ //GENERAL CALLBACKS// void number_callback(Control* sender, int type); //SPECIFIC CALLBACKS// //***ABOVE***// void activation_syringe_pump_callback (Control* sender, int value, void* param); void syringe_filled_placement_callback (Control* sender, int value, void* param); void initialisation_callback(Control* sender, int type); 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); //Configurations void choose_syringe_callback (Control* sender, int value, void* param); void name_new_syringe_callback(Control* sender, int type); void total_volume_mL_new_syringe_callback(Control* sender, int type); void internal_diameter_mm_new_syringe_callback(Control* sender, int type); void add_syringe_callback (Control* sender, int value, void* param); //features : Configurations avancées void clockwise_equals_push_callback(Control* sender, int value); // void syringe_selection_callback(Control* sender, int value); //ON_OFF METHODS void syringe_pump_on_off(); void syringe_pump_on(); void syringe_pump_off(); void syringe_filled_placement_on(); void syringe_filled_placement_off(); //OTHER_METHODS void style (uint16_t id, int style); void set_init_style(); void set_theme(int theme); void select_syringe_maj(uint16_t tab);