The first example of digital output uses a LED to realize a blinking LED. It can be managed from the Internet via start and stop commands.
Connect the LED as shown in figure 1:
The long PIN is positive as shown in Figure 2.
Write a sketch K to define:
led :: d2 start = [led=!led #1] stop = [led=0] or simply load the sketch with the command
] load e01_blinkTry the following commands now:
] ?--- Pin connectionsled :: d2 --- Commandsstart = [led=!led#1] stop = [led=0] shows the loaded sketch
] startthe led starts blinking
] pausethe flashing of the led stops
] playthe flashing of the led resumes
] ??--- Periodic commandsled=!led #1shows the periodic commands running
] trace=1ok] # led=!led] # led=!led...traces the commands running
] trace=0ends the tracing
] stopturns off the led and stops the flashing of the led
] ??nullstop command also clears the commands running.
In this lesson you learned: