code de la carte IHM avant les bugs et avant le travail effectué avec Melchior

Dependencies:   mbed SerialHalfDuplex SDFileSystem liaison_Bluetooth ident_crac DISCO-F469NI_portrait

Committer:
goldmas
Date:
Sat Jul 17 16:07:29 2021 +0000
Revision:
37:f1a8734c193d
Parent:
36:c37dbe2be916
code de l'IHM avant bug

Who changed what in which revision?

UserRevisionLine numberNew contents of line
gabrieltetar 1:7e925468f9d9 1 #ifndef CRAC_STRATEGIE
gabrieltetar 1:7e925468f9d9 2 #define CRAC_STRATEGIE
gabrieltetar 1:7e925468f9d9 3
gabrieltetar 1:7e925468f9d9 4 typedef enum
gabrieltetar 1:7e925468f9d9 5 {
gabrieltetar 1:7e925468f9d9 6 RECALAGE_1,
gabrieltetar 1:7e925468f9d9 7 RECULER_1,
gabrieltetar 1:7e925468f9d9 8 TOURNER,
gabrieltetar 1:7e925468f9d9 9 RECALAGE_2,
gabrieltetar 1:7e925468f9d9 10 RECULER_2,
gabrieltetar 1:7e925468f9d9 11 GOTOPOS,
gabrieltetar 1:7e925468f9d9 12 FIN_POS,
gabrieltetar 1:7e925468f9d9 13 }E_Stratposdebut;
gabrieltetar 1:7e925468f9d9 14
gabrieltetar 21:d137ec53c3a9 15 typedef enum {
maximilienlv 28:7f2990747e09 16 INIT,
maximilienlv 28:7f2990747e09 17 ATT,
maximilienlv 28:7f2990747e09 18 CHOIX,
gabrieltetar 22:c7763a7ec6c7 19 DEMO,
gabrieltetar 24:1a13c998c7ac 20 DEMO2,
gabrieltetar 21:d137ec53c3a9 21 TEST_MOTEUR,
gabrieltetar 21:d137ec53c3a9 22 TEST_COULEUR,
gabrieltetar 21:d137ec53c3a9 23 TEST_SERVO_BRAS,
gabrieltetar 21:d137ec53c3a9 24 TEST_VENTOUSE,
gabrieltetar 24:1a13c998c7ac 25 TEST_ELECTROV,
gabrieltetar 24:1a13c998c7ac 26 TEST_AUD,
gabrieltetar 22:c7763a7ec6c7 27 TEST_DIVE,
gabrieltetar 22:c7763a7ec6c7 28 TEST_ASSERVE,
goldmas 37:f1a8734c193d 29 TEST_MANCHES,
goldmas 37:f1a8734c193d 30 TEST_GIROUS,
gabrieltetar 21:d137ec53c3a9 31 SELECT_SIDE,
goldmas 36:c37dbe2be916 32 SELECT_ROB,
gabrieltetar 21:d137ec53c3a9 33 TACTIQUE,
gabrieltetar 21:d137ec53c3a9 34 DETAILS,
gabrieltetar 21:d137ec53c3a9 35 LECTURE,
gabrieltetar 21:d137ec53c3a9 36 LAUNCH,
gabrieltetar 21:d137ec53c3a9 37 AFF_WAIT_JACK,
gabrieltetar 21:d137ec53c3a9 38 WAIT_JACK,
gabrieltetar 21:d137ec53c3a9 39 FIN} T_etat;
gabrieltetar 21:d137ec53c3a9 40
gabrieltetar 1:7e925468f9d9 41 typedef enum
gabrieltetar 1:7e925468f9d9 42 {
gabrieltetar 1:7e925468f9d9 43 ETAT_CHECK_CARTE_SCREEN, //Envoie check carte screen
gabrieltetar 1:7e925468f9d9 44 ETAT_CHECK_CARTE_SCREEN_WAIT_ACK, //Time out de 1s si erreur clignotement des led et fin prog
gabrieltetar 1:7e925468f9d9 45 ETAT_CHECK_CARTES, //Envoie check toutes les carte
gabrieltetar 1:7e925468f9d9 46 ETAT_CHECK_CARTES_WAIT_ACK, //Time out de 1s
gabrieltetar 1:7e925468f9d9 47 ETAT_WAIT_FORCE,//Attente du forçage du lancement
gabrieltetar 1:7e925468f9d9 48 ETAT_CONFIG, //attente reception du choix du mode( debug ou game)
gabrieltetar 1:7e925468f9d9 49 ETAT_GAME_INIT,//Mise en mémoire du fichier de stratégie
gabrieltetar 1:7e925468f9d9 50 ETAT_GAME_WAIT_FOR_JACK,//Attente du retrait du jack
goldmas 37:f1a8734c193d 51 ETAT_GAME_START,//Lancement du timer 100s
gabrieltetar 1:7e925468f9d9 52 ETAT_GAME_LOAD_NEXT_INSTRUCTION,
gabrieltetar 1:7e925468f9d9 53 ETAT_GAME_PROCESS_INSTRUCTION,
gabrieltetar 1:7e925468f9d9 54 ETAT_GAME_WAIT_ACK,
gabrieltetar 1:7e925468f9d9 55 ETAT_GAME_JUMP_TIME,
gabrieltetar 1:7e925468f9d9 56 ETAT_GAME_JUMP_CONFIG,
gabrieltetar 1:7e925468f9d9 57 ETAT_GAME_JUMP_POSITION,
gabrieltetar 1:7e925468f9d9 58 ETAT_GAME_WAIT_END_INSTRUCTION,
gabrieltetar 1:7e925468f9d9 59 ETAT_END,
gabrieltetar 1:7e925468f9d9 60 ETAT_END_LOOP,
gabrieltetar 1:7e925468f9d9 61 } E_stratGameEtat;
gabrieltetar 21:d137ec53c3a9 62 extern E_stratGameEtat gameEtat;
gabrieltetar 21:d137ec53c3a9 63 extern T_etat strat_etat_s;
goldmas 35:2a745eeb7922 64 extern Timer gameTimer;
goldmas 37:f1a8734c193d 65
goldmas 37:f1a8734c193d 66 extern char val_girou ;
goldmas 37:f1a8734c193d 67
goldmas 37:f1a8734c193d 68 extern int Flag_Bras_Re;
goldmas 37:f1a8734c193d 69 extern int Flag_Manche_Bas;
goldmas 37:f1a8734c193d 70 extern int Flag_pavillon;
goldmas 37:f1a8734c193d 71 extern int Flag_Manche_Moy;
goldmas 37:f1a8734c193d 72 extern int Flag_bon_port;
goldmas 37:f1a8734c193d 73 extern unsigned short Flag_num_bras;
goldmas 37:f1a8734c193d 74
gabrieltetar 1:7e925468f9d9 75 void canProcessRx(void);
gabrieltetar 19:e70b9d4a319c 76 void Strategie(void);
gabrieltetar 1:7e925468f9d9 77 short recalageAngulaireCapteur(void);
gabrieltetar 1:7e925468f9d9 78 short recalageDistanceX(void);
gabrieltetar 1:7e925468f9d9 79 short recalageDistanceY(void);
gabrieltetar 1:7e925468f9d9 80 #endif