-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathassignment2.html
53 lines (48 loc) · 2.21 KB
/
assignment2.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, maximum-scale=1.0" />
<title>HCDE 439 Assignment 2</title>
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Montserrat:wght@300&display=swap" rel="stylesheet">
<link href="p5/style.css" media="screen" rel="stylesheet" type="text/css" />
</head>
<body>
<div class="navbar">
<ul>
<li><a href="portfolio.html">Projects</a></li>
<li><a href="index.html">Home</a></li>
</ul>
</div>
<div>
<h2>Schematic for my circuit!</h2>
<p>
<img src="img/a2/a2_schematic.png" width=600>
</p>
<p>The circuit was powered with 5V through USB and I used the red, green and RGB LEDs included in our kits.</p>
<p>I used 220 ohm resistors for all of the LEDs I used because they were either 1.8V(R/G) or 3.3V(B) and they</p>
<p>needed to run at 30mA or less. For the button I used a 10k ohm resistor.</p>
</div>
<div>
<h2>Firmware running the lights and button!</h2>
<p>
<img src="img/a2/firmware0.png" width=700>
<img src="img/a2/firmware1.png" width=700>
<img src="img/a2/firmware2.png" width=700>
</p>
<p>The firmware used to control the lights was programmed in Arduino! I initialized the pins as outputs and</p>
<p>the button as an input because it waits for a press to close the circuit. I programmed the LEDs to turn on</p>
<p>when the button is pressed, where they turn on one at a time (from left to right) and the RGB light fades</p>
<p>from red to green, creating a wave effect.</p>
</div>
<div>
<h2>Final circuit result!</h2>
<p>
<img src="img/a2/circuit_operation.gif" width=800>
<img src="img/a2/circuit.jpg" width="800">
</p>
</div>
</body>
</html>