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:
- snec_student
- Date:
- 2020-09-23
- Revision:
- 33:073294c58b40
- Parent:
- 32:231922dccf64
File content as of revision 33:073294c58b40:
#include "mbed.h"
DigitalOut Led_rouge(LED1);
DigitalOut Led_verte(LED2);
DigitalOut Led_bleue(LED3);
DigitalIn BP1(D3);
DigitalIn BP2(SW2);
DigitalIn BP3(SW3);
int main()
{
    while(1) {
    Led_rouge=BP2&&BP3||!BP1&&(BP2||BP3);
    Led_verte=BP2&&!BP3||!BP1&&(BP2||!BP3);
    Led_bleue=!BP2&&BP3||!BP1&&(!BP2||BP3);
    }   // fin boucle infinie
}       // fin programme