strat des robots

Fork of CRAC-Strat_2017 by CRAC Team

Committer:
ClementBreteau
Date:
Fri May 19 17:14:07 2017 +0000
Revision:
17:d1594579eec6
Parent:
15:c2fc239e85df
strat du robot, 19-05-2017, 19h

Who changed what in which revision?

UserRevisionLine numberNew contents of line
antbig 12:14729d584500 1 #ifndef CRAC_IDENTH
antbig 12:14729d584500 2 #define CRAC_IDENTH
antbig 12:14729d584500 3
antbig 12:14729d584500 4
antbig 12:14729d584500 5
antbig 0:ad97421fb1fb 6 #define GLOBAL_GAME_END 0x004 // Stop fin du match
antbig 0:ad97421fb1fb 7 #define GLOBAL_START 0x002 // Start
antbig 0:ad97421fb1fb 8 #define GLOBAL_END_INIT_POSITION 0x005 // Fin positionnement robot avant depart
antbig 5:dcd817534b57 9 #define GLOBAL_FUNNY_ACTION 0x007 // Funny action start (0: start, 1: stop)
antbig 0:ad97421fb1fb 10
antbig 12:14729d584500 11 #define BALISE_STOP 0x003 // Trame stop
antbig 12:14729d584500 12
antbig 12:14729d584500 13 #define BALISE_DANGER 0xA // Trame danger
antbig 12:14729d584500 14
antbig 0:ad97421fb1fb 15 #define BALISE_END_DANGER 0xB // Trame fin de danger
antbig 0:ad97421fb1fb 16
antbig 12:14729d584500 17
antbig 0:ad97421fb1fb 18 #define ASSERVISSEMENT_STOP 0x001 // Stop moteur
antbig 5:dcd817534b57 19 #define ASSERVISSEMENT_SPEED_DANGER 0x006 // Vitesse de danger
antbig 0:ad97421fb1fb 20 #define ASSERVISSEMENT_XYT 0x020 // Asservissement (x,y,theta) (0 : au choix 1 : avant -1 : arrière)
antbig 5:dcd817534b57 21 #define ASSERVISSEMENT_COURBURE 0x021 // Asservissement rayon de courbure (+ gauche, - droite , sens : 1avt , -1arr; enchainement => 1 oui, 0 => non, 2=>derniére instruction de l'enchainement)
antbig 5:dcd817534b57 22 #define ASSERVISSEMENT_CONFIG 0x022 // Asservissement paramètre (définir les valeurs de vitesse max et d'eccélération max)
antbig 0:ad97421fb1fb 23 #define ASSERVISSEMENT_ROTATION 0x023 // Asservissement rotation
antbig 0:ad97421fb1fb 24 #define ASSERVISSEMENT_RECALAGE 0x024 // Moteur tout droit (recalage : 0 mouvement seul, 1 x, 2y valeur : coordonnée à laquelle est recalé x/y; enchainement => 1 oui, 0 => non)
antbig 0:ad97421fb1fb 25
antbig 0:ad97421fb1fb 26 #define ODOMETRIE_BIG_POSITION 0x026 // Odométrie position robot (Position actuel du robot)
antbig 0:ad97421fb1fb 27 #define ODOMETRIE_BIG_VITESSE 0x027 // Odométrie vitesse (Indication sur l'état actuel)
antbig 0:ad97421fb1fb 28 #define ODOMETRIE_SMALL_POSITION 0x028 // Odométrie position robot (Position actuel du robot)
antbig 0:ad97421fb1fb 29 #define ODOMETRIE_SMALL_VITESSE 0x029 // Odométrie vitesse (Indication sur l'état actuel)
ClementBreteau 15:c2fc239e85df 30 #define ACTION_BIG_DEMARRAGE 0x025 // Action de départ du GR (Lancement de la trajectoire de départ du GR)
antbig 0:ad97421fb1fb 31
antbig 0:ad97421fb1fb 32 #define ASSERVISSEMENT_INFO_CONSIGNE 0x1F0 // Info Consigne et Commande moteur
antbig 10:a788d9cf60f2 33 #define ASSERVISSEMENT_CONFIG_KPP_DROITE 0x1F1 // Config coef KPP_Droit
antbig 10:a788d9cf60f2 34 #define ASSERVISSEMENT_CONFIG_KPI_DROITE 0x1F2 // Config coef KPI_Droit
antbig 10:a788d9cf60f2 35 #define ASSERVISSEMENT_CONFIG_KPD_DROITE 0x1F3 // Config coef KPD_Droit
antbig 10:a788d9cf60f2 36 #define ASSERVISSEMENT_CONFIG_KPP_GAUCHE 0x1F4 // Config coef KPP_Gauche
antbig 10:a788d9cf60f2 37 #define ASSERVISSEMENT_CONFIG_KPI_GAUCHE 0x1F5 // Config coef KPI_Gauche
antbig 10:a788d9cf60f2 38 #define ASSERVISSEMENT_CONFIG_KPD_GAUCHE 0x1F6 // Config coef KPD_Gauche
antbig 0:ad97421fb1fb 39 #define ASSERVISSEMENT_ENABLE 0x1F7 // Activation asservissement (0 : désactivation, 1 : activation)
antbig 0:ad97421fb1fb 40
antbig 12:14729d584500 41
antbig 0:ad97421fb1fb 42 #define RESET_BALISE 0x030 // Reset balise
antbig 0:ad97421fb1fb 43 #define RESET_MOTEUR 0x031 // Reset moteur
antbig 0:ad97421fb1fb 44 #define RESET_IHM 0x032 // Reset écran tactile
antbig 5:dcd817534b57 45 #define RESET_ACTIONNEURS 0x033 // Reset actionneurs
antbig 10:a788d9cf60f2 46 #define RESET_POMPES 0x034 // Reset pompes
antbig 12:14729d584500 47 #define RESET_AX12 0x035 // Reset AX12
ClementBreteau 15:c2fc239e85df 48 #define RESET_TELEMETRE 0x036 // Reset telemetre
antbig 12:14729d584500 49
antbig 12:14729d584500 50
antbig 12:14729d584500 51
antbig 0:ad97421fb1fb 52 #define RESET_STRAT 0x3A // Reset stratégie
antbig 0:ad97421fb1fb 53
antbig 12:14729d584500 54
antbig 0:ad97421fb1fb 55 #define CHECK_BALISE 0x060 // Check balise
antbig 0:ad97421fb1fb 56 #define CHECK_MOTEUR 0x061 // Check moteur
antbig 0:ad97421fb1fb 57 #define CHECK_IHM 0x062 // Check écran tactile
antbig 5:dcd817534b57 58 #define CHECK_ACTIONNEURS 0x063 // Check actionneurs
antbig 10:a788d9cf60f2 59 #define CHECK_POMPES 0x064 // Check pompes
antbig 12:14729d584500 60 #define CHECK_AX12 0x065 // Check AX12
ClementBreteau 15:c2fc239e85df 61 #define CHECK_OK_TELEMETRE 0x066 // Check telemetre
antbig 12:14729d584500 62
antbig 12:14729d584500 63
antbig 12:14729d584500 64
antbig 0:ad97421fb1fb 65
antbig 0:ad97421fb1fb 66 #define ALIVE_BALISE 0x070 // Alive balise
antbig 0:ad97421fb1fb 67 #define ALIVE_MOTEUR 0x071 // Alive moteur
antbig 0:ad97421fb1fb 68 #define ALIVE_IHM 0x072 // Alive écran tactile
antbig 5:dcd817534b57 69 #define ALIVE_ACTIONNEURS 0x073 // Alive actionneurs
antbig 10:a788d9cf60f2 70 #define ALIVE_POMPES 0x074 // Alive pompes
antbig 12:14729d584500 71 #define ALIVE_AX12 0x075 // Alive AX12
ClementBreteau 15:c2fc239e85df 72 #define ALIVE_TELEMETRE 0x076 // Alive telemetre
antbig 12:14729d584500 73
antbig 12:14729d584500 74
antbig 12:14729d584500 75
antbig 0:ad97421fb1fb 76
antbig 0:ad97421fb1fb 77 #define ACKNOWLEDGE_BALISE 0x100 // Acknowledge balise
antbig 0:ad97421fb1fb 78 #define ACKNOWLEDGE_MOTEUR 0x101 // Acknowledge moteur
antbig 0:ad97421fb1fb 79 #define ACKNOWLEDGE_IHM 0x102 // Acknowledge ecran tactile
antbig 5:dcd817534b57 80 #define ACKNOWLEDGE_ACTIONNEURS 0x103 // Acknowledge actionneurs
antbig 12:14729d584500 81 #define ACKNOWLEDGE_POMPES 0x104 // Acknowledge pompes
ClementBreteau 14:c8fc06c4887f 82 #define ACKNOWLEDGE_TELEMETRE 0x105 // Acknowledge telemetre
ClementBreteau 15:c2fc239e85df 83 #define ACKNOWLEDGE_AX12 0x106 // Ack ax12
antbig 12:14729d584500 84 #define ACKNOWLEDGE_STRAT 0x10A // Acknowledge pompes
antbig 0:ad97421fb1fb 85
ClementBreteau 15:c2fc239e85df 86
antbig 0:ad97421fb1fb 87 #define INSTRUCTION_END_BALISE 0x110 // Fin instruction balise (Indique que l'instruction est terminée)
antbig 0:ad97421fb1fb 88 #define INSTRUCTION_END_MOTEUR 0x111 // Fin instruction moteur (Indique que l'instruction est terminée)
antbig 0:ad97421fb1fb 89 #define INSTRUCTION_END_IHM 0x112 // Fin instruction ecran tactile (Indique que l'instruction est terminée)
antbig 5:dcd817534b57 90 #define INSTRUCTION_END_ACTIONNEURS 0x113 // Fin instruction actionneurs (Indique que l'instruction est terminée)
ClementBreteau 15:c2fc239e85df 91 #define INSTRUCTION_END_AX12 0x116
antbig 12:14729d584500 92
antbig 0:ad97421fb1fb 93 #define ECRAN_CHOICE_STRAT 0x601 // Choix d'une stratégie (n° strat (1-4))
ClementBreteau 14:c8fc06c4887f 94 #define ECRAN_CHOICE_COLOR 0x602 // Couleur (0->Blue;1->Yellow)
antbig 0:ad97421fb1fb 95 #define ECRAN_START_MATCH 0x603 // Match (Indique que l'on souhaite commencer le match)
ClementBreteau 14:c8fc06c4887f 96 #define ECRAN_DEMO_BEGIN 0x604 // Demo (Indique que l'on souhaite faire une demo)
antbig 0:ad97421fb1fb 97 #define ECRAN_ACK_STRAT 0x611 // Acknowledge stratégie (si 0 erreur, sinon n°strat)
ClementBreteau 14:c8fc06c4887f 98 #define ECRAN_ACK_COLOR 0x612 // Acknowledge couleur (0->Blue;1->Yellow)
antbig 0:ad97421fb1fb 99 #define ECRAN_ACK_START_MATCH 0x613 // Acknowledge Match (Indique que l'on a bien reçu le debut du match)
ClementBreteau 14:c8fc06c4887f 100 #define ECRAN_ACK_DEMO 0x614
antbig 0:ad97421fb1fb 101 #define ECRAN_ALL_CHECK 0x620 // Carte all check (Si provient de carte strat => toutes les cartes sont en ligne, Si provient IHM => forcer le lancement)
antbig 0:ad97421fb1fb 102 #define ECRAN_TIME 0x621 // Time match (Indication de moment cle du temps (10,30,60,70,80,85,90))
antbig 0:ad97421fb1fb 103 #define ECRAN_PRINTF_1 0x6C0 // Tactile printf (Afficher les 8 permier caractères)
antbig 0:ad97421fb1fb 104 #define ECRAN_PRINTF_2 0x6C1 // Tactile printf (Afficher les 8 second caractères)
antbig 0:ad97421fb1fb 105 #define ECRAN_PRINTF_3 0x6C2 // Tactile printf (Afficher les 8 troisième caractères)
antbig 0:ad97421fb1fb 106 #define ECRAN_PRINTF_4 0x6C3 // Tactile printf (Afficher les 8 quatrième caractères)
antbig 0:ad97421fb1fb 107 #define ECRAN_PRINTF_CLEAR 0x6CF // Tactile printf clear (Permet d'effacer l'ecran)
antbig 12:14729d584500 108 #define ECRAN_CHOICE_START_ACTION 0x604 // Tactile printf clear (Choisir si il faut lancer le test actionneur)
antbig 12:14729d584500 109 #define ECRAN_ACK_CHOICE_START_ACTION 0x605 // Tactile printf clear (Ack du test actionneur)
antbig 0:ad97421fb1fb 110
antbig 0:ad97421fb1fb 111 #define ERROR_OVERFLOW_BALISE 0x040 // Overflow odométrie
antbig 0:ad97421fb1fb 112 #define ERROR_OVERFLOW_MOTEUR 0x041 // Overflow asservissement
antbig 0:ad97421fb1fb 113 #define ERROR_OVERFLOW_IHM 0x042 // Overflow balise
antbig 0:ad97421fb1fb 114 #define ERROR_OVERFLOW_STRAT 0x043 // Overflow stratégie
antbig 0:ad97421fb1fb 115 #define ERROR_BALISE 0x785 // Bug balise
antbig 0:ad97421fb1fb 116 #define ERROR_RTC 0x786 // Bug RTC
antbig 0:ad97421fb1fb 117 #define ERROR_MOTEUR 0x787 // Bug moteur
antbig 0:ad97421fb1fb 118 #define ERROR_TELEMETRIE 0x788 // Bug télémètre
antbig 0:ad97421fb1fb 119 #define ERROR_STRATEGIE 0x789 // Bug stratégie
antbig 0:ad97421fb1fb 120
antbig 0:ad97421fb1fb 121 #define DEBUG_STRATEGIE_AUTOMATE 0x760 // Etat automate stratégie (Permet de savoir l'etat de l'automate)
antbig 1:116040d14164 122 #define DEBUG_FAKE_JAKE 0x761 // Fake jack (Permet d'outre passerr le JACk du robot)
antbig 5:dcd817534b57 123 #define DEBUG_ASSERV 0x762 // Info debug carte moteur
antbig 0:ad97421fb1fb 124
antbig 0:ad97421fb1fb 125 #define SERVO_AX12_SETGOAL 0x090 // AX12 setGoal (Indiquer la nouvelle position de l'AX12 !! Ne bouge pas)
antbig 0:ad97421fb1fb 126 #define SERVO_AX12_PROCESS 0x091 // AX12 processChange (Lancer le déplacement des AX12)
antbig 1:116040d14164 127 #define SERVO_AX12_DONE 0x092 // AX12 done (Indique q'un AX12 a terminé son déplacement)
antbig 1:116040d14164 128 #define SERVO_XL320 0x093 // XL320
ClementBreteau 15:c2fc239e85df 129 #define SERVO_AX12_ACTION 0x96
antbig 10:a788d9cf60f2 130
ClementBreteau 15:c2fc239e85df 131
ClementBreteau 14:c8fc06c4887f 132 #define TELEMETRE_RECHERCHE_COIN 0x301
ClementBreteau 15:c2fc239e85df 133 #define TELEMETRE_OBJET 0x302
ClementBreteau 14:c8fc06c4887f 134 #define OBJET_SUR_TABLE 0x304
ClementBreteau 14:c8fc06c4887f 135
antbig 10:a788d9cf60f2 136 #define POMPE_PWM 0x9A // pwm des pompes (pwm entre 0 et 100)
antbig 12:14729d584500 137
antbig 12:14729d584500 138 #endif