Commit b6c3716c authored by Kruliš Martin's avatar Kruliš Martin
Browse files

Updating materials, publishing zoom recording.

parent 492f2a3f
#include <funshield.h>
constexpr int pins[] { led1_pin, led2_pin, led3_pin, led4_pin };
constexpr int pinsCount = sizeof(pins) / sizeof(pins[0]);
constexpr unsigned long changeDelay = 300;
bool ledState = false;
unsigned long lastChange;
void setup() {
// put your setup code here, to run once:
for (int i = 0; i < pinsCount; ++i) {
pinMode(pins[i], OUTPUT);
digitalWrite(pins[i], OFF);
}
lastChange = millis();
}
void loop() {
// put your main code here, to run repeatedly:
unsigned long currentTime = millis();
if (currentTime - lastChange >= changeDelay) {
ledState = !ledState;
for (int i = 0; i < pinsCount; ++i) {
digitalWrite(pins[i], ledState ? ON : OFF);
}
lastChange += changeDelay;
}
}
......@@ -77,13 +77,14 @@ $(document).ready(function(){
</a>
</td>
<td>
<a class="extern" href="https://youtu.be/AoDzcXPOFC0">result visualization</a>
<a class="extern nowrap" href="https://youtu.be/AoDzcXPOFC0">result visualization</a>
<a class="extern nowrap" href="download/krulis/02-blinq.ino">source code from labs</a>
</td>
<td>
<a class="extern" href="https://web.microsoftstream.com/video/11a38260-2754-491f-beb9-2e1c24dc7310">recording</a>
</td>
<td>
<a class="extern" href="https://recodex.mff.cuni.cz/app/assignment/363bfed2-8c9c-11eb-a1a9-005056ad4f31">assignment</a>
</td>
</tr>
<tr>
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment