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 SerialHalfDuplex SDFileSystem DISCO-F469NI_portrait liaison_Bluetooth ident_crac
Diff: Robots/Strategie_small.cpp
- Revision:
- 84:44d6cd2cab99
- Parent:
- 83:23e04b85ae06
diff -r 23e04b85ae06 -r 44d6cd2cab99 Robots/Strategie_small.cpp --- a/Robots/Strategie_small.cpp Fri May 31 05:02:55 2019 +0000 +++ b/Robots/Strategie_small.cpp Fri May 31 17:33:28 2019 +0000 @@ -63,15 +63,11 @@ case 108: //goldenium avant //SendRawId(GOLDENIUM_AVANT); x = arg1; - if(InversStrat == 1) - { + if(InversStrat == 1) { y = 3000 - arg2; - } - else - { + } else { y = arg2; } - Send2Short(GOLDENIUM_AVANT, x, y); break; case 109: //goldenium arriere @@ -91,19 +87,18 @@ case 113: //sol arriere relache SendRawId(SOL_ARRIERE_RELACHE); break; - case 114: + case 114://relache les 3 ventouses avants SendRawId(AVANT_RELACHE); break; - case 115: + case 115://relache les 3 ventouses arrieres SendRawId(ARRIERE_RELACHE); break; - case 116: + case 116://relache une pompe unsigned char arg_tempo; - if(InversStrat == 1) - { - switch(arg1){ + if(InversStrat == 1) { + switch(arg1) { case AV_DROIT: arg_tempo = AV_GAUCHE; break; @@ -120,9 +115,8 @@ arg_tempo =(unsigned char)arg1; break; } - - } - else arg_tempo =(unsigned char)arg1; + + } else arg_tempo =(unsigned char)arg1; SendMsgCan(HACHEUR_RELEASE_ATOM, &arg_tempo,1); waitingAckFrom = 0; waitingAckID =0; @@ -139,11 +133,11 @@ case 120: SendRawId(ACCELERATEUR_INSERTION_AVANT_GAUCHE); break; - + case 121: SendRawId(ACCELERATEUR_INSERTION_ARRIERE_GAUCHE); break; - + case 150: SCORE_PR+=arg1; liaison_Tx.envoyer_short(0x30,SCORE_PR); @@ -165,20 +159,20 @@ retour = 2; break; - + case 11://0 Désactiver le stop,1 Activer le stop saut de strat,2 Activer le stop avec evitement isStopEnable =(unsigned char) arg1; - // SendMsgCan(0x5BC, &isStopEnable,1); + // SendMsgCan(0x5BC, &isStopEnable,1); waitingAckFrom = 0; waitingAckID =0; break; - - - + + + case 20://Désactiver l'asservissement setAsservissementEtat(0); break; - + case 21://Activer l'asservissement setAsservissementEtat(1); break; @@ -195,7 +189,7 @@ waitingAckFrom = 0; waitingAckID = 0; break; - + case 19: // CHANGER LA VITESSE + DECELERATION //SendSpeedDecel(arg1,(unsigned short) arg2);