Modifications

Sauter à la navigation Sauter à la recherche
254 octets ajoutés ,  21 août 2024 à 15:26
Ligne 74 : Ligne 74 :  
=== Bouton Utilisateur ===
 
=== Bouton Utilisateur ===
   −
x
+
Le bouton utilisateur est branché sur le GPIO 12
 +
 
 +
<syntaxhighlight lang="python">
 +
from machine import Pin
 +
p = Pin( Pin.board.gp12 )
 +
p = Pin( Pin.board.GP12 )
 +
 
 +
# Affiche 1 lorsque relâché
 +
# Affiche 0 lorsque pressé
 +
print( p.value() )
 +
</syntaxhighlight>
    
=== Led NeoPixel ===
 
=== Led NeoPixel ===
32 920

modifications

Menu de navigation