top of page
Rechercher

5.1 - Allumer une LED

  • L C
  • 5 nov. 2024
  • 1 min de lecture

Matériel


  • 1 carte Arduino Uno

  • 1 LED

  • 1 résistance 220 Ω

  • 2 fils de connexion

  • 1 breadboard


Montage


Ces 2 montages sont équivalents :


Schéma

Sketch


void setup()

{

//initialisation du pin 4 en sortie

pinMode(4,OUTPUT);

//le courant est envoyé sur le pin 4, la LED s'allume

digitalWrite(4,HIGH);

}

void loop()

{

}


Réalisation


bottom of page