Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed ident_crac
class_ventouse.h
00001 #ifndef CLASS_VENTOUSE_H 00002 #define CLASS_VENTOUSE_H 00003 #include "extern.h" 00004 00005 #define NB_VENTOUSES 6 00006 00007 typedef enum {Attente, Attraper, Attraper_ok, Relacher, Relacher_ok} type_etat ; 00008 00009 class Ventouse{ 00010 public: 00011 Ventouse(PinName pinPompe, PinName pinElectrovanne, PinName pinCapteurPression, char index); 00012 00013 void automate(); 00014 void action(bool action); 00015 void attraper(); 00016 void relacher(); 00017 00018 bool getPression(); 00019 bool getPompe(); 00020 00021 void setPompe(float val); 00022 void setElectrovanne(int val); 00023 00024 00025 private: 00026 PwmOut* m_pompe; 00027 PwmOut* m_electrovanne; 00028 AnalogIn* m_pression; 00029 00030 bool flag_electrovanne; 00031 bool flag_attraper; 00032 bool flag_relacher; 00033 type_etat etat; 00034 char m_index; 00035 char m_ack; 00036 00037 PinName m_pinPompe, m_pinElectrovanne, m_pinCapteurPression; 00038 }; 00039 #endif //CLASS_VENTOUSE_H
Generated on Thu Jul 28 2022 00:11:33 by
