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
main.cpp
- Committer:
- cr7sim
- Date:
- 2020-09-09
- Revision:
- 30:643834f77e0d
- Parent:
- 29:c7336563fcd7
File content as of revision 30:643834f77e0d:
#include "mbed.h"
// DigitalOut Led_rouge (D2);
DigitalOut Led(D2);
// DigitalOut Led_rouge (D2);
DigitalIn BP2 (D3);
int main()
{
Led=0; // eteint a led
while(1) {
if (BP2==1) // si le BP2 est appuyé
{
Led=1; // on allume la led
}
else // sinon
{
Led=0; //on eteint la led
}
} // fin boucle infinie
} // fin programme