turn_on_led_using_webpage
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| turn_on_led_using_webpage [2026/07/09 18:17] – [Introduction] walkeradmin | turn_on_led_using_webpage [2026/07/09 19:07] (current) – walkeradmin | ||
|---|---|---|---|
| Line 28: | Line 28: | ||
| \\ | \\ | ||
| \\ | \\ | ||
| - | {{ :corporate: | + | {{ : |
| In this example, we have the LED being connected to GP14 (pin 19) and GND (pin 18) via a 100 ohm resistor. You can use one of the GND pins on the Pico, or a common GND rail if you have made one. | In this example, we have the LED being connected to GP14 (pin 19) and GND (pin 18) via a 100 ohm resistor. You can use one of the GND pins on the Pico, or a common GND rail if you have made one. | ||
| Line 70: | Line 71: | ||
| \\ | \\ | ||
| \\ | \\ | ||
| - | {{ :corporate: | + | {{ : |
| Looking at the simulation above, we can see that when the button is not pressed, we get a delay of 1000mS as per the MicroPython code, so 1 flash every two seconds (1s on, 1s off). | Looking at the simulation above, we can see that when the button is not pressed, we get a delay of 1000mS as per the MicroPython code, so 1 flash every two seconds (1s on, 1s off). | ||
| Line 243: | Line 244: | ||
| \\ | \\ | ||
| \\ | \\ | ||
| - | {{ :corporate: | + | {{ : |
| \\ | \\ | ||
| The page clearly states that the Button is NOT pressed, and the LED is off. | The page clearly states that the Button is NOT pressed, and the LED is off. | ||
| Line 251: | Line 252: | ||
| \\ | \\ | ||
| \\ | \\ | ||
| - | {{ :corporate: | + | {{ : |
| \\ | \\ | ||
| You should see now that the page states that the button IS pressed and that the LED is on. | You should see now that the page states that the button IS pressed and that the LED is on. | ||
| Line 305: | Line 306: | ||
| \\ | \\ | ||
| \\ | \\ | ||
| - | {{ :corporate: | + | {{ : |
| \\ | \\ | ||
| You can now change the LED status on or off by simply clicking the buttons on the webpage, clicking either button also refreshed the webpage. This means, if you hold the button down (or not) and click a button to change the LED, the LED status will change, and the text at the bottom of the webpage will also change to reflect the button status. | You can now change the LED status on or off by simply clicking the buttons on the webpage, clicking either button also refreshed the webpage. This means, if you hold the button down (or not) and click a button to change the LED, the LED status will change, and the text at the bottom of the webpage will also change to reflect the button status. | ||
turn_on_led_using_webpage.1783621073.txt.gz · Last modified: by walkeradmin
