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 bloc_8_pompe2 Herkulex_library_2022 ident_crac1 bloc_pompe2
Gestion_Torque/torque.cpp
- Committer:
- ares1999
- Date:
- 2022-04-26
- Revision:
- 3:77e937c315f1
- Parent:
- 2:c7f2e7d8b305
File content as of revision 3:77e937c315f1:
#include "torque.h"
void activer_torque(void) //Active le couple sur de tous les servomoteurs sur toutes les liaisons séries
{
for(int i=1;i<=12;i++)
{
setTorque(i,TORQUE_ON,1);
setTorque(i,TORQUE_ON,2);
setTorque(i,TORQUE_ON,3);
setTorque(i,TORQUE_ON,4);
setTorque(i,TORQUE_ON,5);
}
}
void desactiver_torque(void) //Désactive le couple de tous les servomoteurs sur toutes les liaisons séries
{
for(int i=1;i<=12;i++)
{
setTorque(i,TORQUE_FREE,1);
setTorque(i,TORQUE_FREE,2);
setTorque(i,TORQUE_FREE,3);
setTorque(i,TORQUE_FREE,4);
setTorque(i,TORQUE_FREE,5);
}
}