<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="fr">
	<id>https://wikilipo.unige.ch/w/index.php?action=history&amp;feed=atom&amp;title=SimpleButton.ino</id>
	<title>SimpleButton.ino - Historique des versions</title>
	<link rel="self" type="application/atom+xml" href="https://wikilipo.unige.ch/w/index.php?action=history&amp;feed=atom&amp;title=SimpleButton.ino"/>
	<link rel="alternate" type="text/html" href="https://wikilipo.unige.ch/w/index.php?title=SimpleButton.ino&amp;action=history"/>
	<updated>2026-04-28T19:51:39Z</updated>
	<subtitle>Historique des versions pour cette page sur le wiki</subtitle>
	<generator>MediaWiki 1.39.4</generator>
	<entry>
		<id>https://wikilipo.unige.ch/w/index.php?title=SimpleButton.ino&amp;diff=1185&amp;oldid=prev</id>
		<title>Pdunandf le 13 avril 2012 à 12:59</title>
		<link rel="alternate" type="text/html" href="https://wikilipo.unige.ch/w/index.php?title=SimpleButton.ino&amp;diff=1185&amp;oldid=prev"/>
		<updated>2012-04-13T12:59:47Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;fr&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Version précédente&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Version du 13 avril 2012 à 12:59&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l60&quot;&gt;Ligne 60 :&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Ligne 60 :&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;}&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;}&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/pre&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/pre&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-added&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[[Fichier:Exemple.jpg]]&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-added&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Pdunandf</name></author>
	</entry>
	<entry>
		<id>https://wikilipo.unige.ch/w/index.php?title=SimpleButton.ino&amp;diff=1184&amp;oldid=prev</id>
		<title>Pdunandf : Page créée avec « &lt;pre&gt; /*  * bouton simple  * la DEL est allumée aussi longtemps que le bouton est pressé    *    * Le circuit:  * LED connectée entre la fiche 13 la terre  * le poussoir c... »</title>
		<link rel="alternate" type="text/html" href="https://wikilipo.unige.ch/w/index.php?title=SimpleButton.ino&amp;diff=1184&amp;oldid=prev"/>
		<updated>2012-04-13T12:59:04Z</updated>

		<summary type="html">&lt;p&gt;Page créée avec « &amp;lt;pre&amp;gt; /*  * bouton simple  * la DEL est allumée aussi longtemps que le bouton est pressé    *    * Le circuit:  * LED connectée entre la fiche 13 la terre  * le poussoir c... »&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Nouvelle page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;&amp;lt;pre&amp;gt;&lt;br /&gt;
/*&lt;br /&gt;
 * bouton simple&lt;br /&gt;
 * la DEL est allumée aussi longtemps que le bouton est pressé  &lt;br /&gt;
 *  &lt;br /&gt;
 * Le circuit:&lt;br /&gt;
 * LED connectée entre la fiche 13 la terre&lt;br /&gt;
 * le poussoir connecnté entre la fiche 2 (numérique) et les 5V&lt;br /&gt;
 * une résistance de 10K est intercalée entre le boutton et la terre&lt;br /&gt;
 &lt;br /&gt;
 * Note: sur le pluspart des Arduino le fiche 13 est déjà munie d&amp;#039;une DEL&lt;br /&gt;
 *  &lt;br /&gt;
 * created 2005&lt;br /&gt;
 * by DojoDave &amp;lt;http://www.0j0.org&amp;gt;&lt;br /&gt;
 * modified 30 Aug 2011&lt;br /&gt;
 * by Tom Igoe&lt;br /&gt;
 *&lt;br /&gt;
 * April 13, 2012 revision with French comments&lt;br /&gt;
 * follow up in the serial monitor added&lt;br /&gt;
 * @atelierpdf.com&lt;br /&gt;
 */&lt;br /&gt;
&lt;br /&gt;
// on fixe les numéros de fiches dans des constantes: &lt;br /&gt;
// elles ne sont pas destiées à changer&lt;br /&gt;
&lt;br /&gt;
const int buttonPin = 2;     // la fiche 2 pour le poussoir&lt;br /&gt;
const int ledPin =  13;      // la fiche 13 pour la DEL&lt;br /&gt;
&lt;br /&gt;
// une variable de type entière&lt;br /&gt;
int buttonState = 0;         // qui contiendra l&amp;#039;état de boutton  &lt;br /&gt;
&lt;br /&gt;
void setup() {&lt;br /&gt;
  // initilisation de la communication entre l&amp;#039;ordi et l&amp;#039;aduino&lt;br /&gt;
  Serial.begin(9600);&lt;br /&gt;
  // la fiche (PIN) de la DEL est initialisée comme une sortie:&lt;br /&gt;
  pinMode(ledPin, OUTPUT);      &lt;br /&gt;
  // la fiche (PIN) du poussoirL est initialisée comme une sortie:&lt;br /&gt;
  pinMode(buttonPin, INPUT);     &lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void loop(){&lt;br /&gt;
  // lecture de l&amp;#039;état du bouton&lt;br /&gt;
  buttonState = digitalRead(buttonPin);&lt;br /&gt;
&lt;br /&gt;
  // affichage de l&amp;#039;état du bouton dans le moniteur sériel&lt;br /&gt;
  Serial.println(buttonState);&lt;br /&gt;
  &lt;br /&gt;
  // si le bouton est pressé&lt;br /&gt;
  // c&amp;#039;est à dire &amp;quot;HIGH&amp;quot;:&lt;br /&gt;
  if (buttonState == HIGH) {     &lt;br /&gt;
    // on allume la DEL    &lt;br /&gt;
    digitalWrite(ledPin, HIGH);  &lt;br /&gt;
  } &lt;br /&gt;
&lt;br /&gt;
  // sinon&lt;br /&gt;
  else {&lt;br /&gt;
    // on l&amp;#039;éteint&lt;br /&gt;
    digitalWrite(ledPin, LOW); &lt;br /&gt;
  }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Fichier:Exemple.jpg]]&lt;/div&gt;</summary>
		<author><name>Pdunandf</name></author>
	</entry>
</feed>