1/25
Name | Mastery | Learn | Test | Matching | Spaced |
|---|
No study sessions yet.
Voltage
“push” in electricity
measured in volts
represented as V
obtained by multiplying the value of current and resistance
Current
the flow of electric charge
measured in amperes or amps
represented as I
obtained by dividing voltage by resistance
Resistance
how much a component resists current
measured in ohms (Ω)
represented as R
obtained by dividing voltage by current
Ohm’s Law
explains the relationship between voltage, current, and resistance
represented as V=IR
Forward Voltage
is the voltage consumed in order to power component, must be subtracted from the supply voltage in problem solving
Series Circuit
components are connected across a single path
the same current flows through all components
voltage is shared across all components
the components experience a lower voltage compared to parallel circuits
if one component fails, the whole circuit fails
this circuit is safer to add components to
Parallel Circuit
components are connected side by side
the total current is the sum of the current in each branch
each branch experiences the same voltage
the components experience a higher voltage compared to series circuits
if one component fails, the rest of the circuit keeps working
this circuit is more dangerous to add components to
Types of Displays
LCD
LED
OLED
LCD
requires a backlight behind the screen to be illuminated
has moderate contrast
has high energy use
used in old monitors and calculators
LED
uses an array of light-emitting diodes for brightness
has bright, vivid colors
has moderate energy use
used in TVs and signage
OLED
stands for Organic Light-Emitting Diode
produces light when an electric current passes through organic compounds
self-illuminating unlike older displays
used in smartphones, wearables, and embedded systems
OLED Characteristics
has deeper blacks as pixels can turn off completely
has better contrast because each pixel’s brightness can be controlled individually
is energy efficient as the only pixels that consume power are those that display light
is flexible as they can be made thin, bendable, or even transparent
How does the OLED work?
OLEDs have thin organic layers placed between two conductors
when electricity flows through, these layers emit light directly from each pixel,
each pixel can represent red, green, or blue light,
by combining these, OLEDs display full-color mages and animations,
Serial Data Line (SDA)
carries the actual data
Serial Clock Line (SCL)
carries the timing signal that keeps data transfer synchronized
Pin Connections
GND → GND
VCC → 5V
SDA → A4
SCL → A5
#include <Wire.h>
includes syntax from the Wire library, which is responsible for communication between the arduino and the OLED
#include <Adafruit_GFX.h>
includes syntax from the Adafruit_GFX library, which is responsible for the display and graphic functions
#include <Adafruit_SSD1306.h>
includes syntax from the Adafruit_SSD1306 library, which is used for monochrome OLEDs based on SSD1306 drivers
display.begin()
starts the display, in void setup
display.clearDisplay()
clears display, in void loop
display.setTextSize()
used to set the text size of the display, in void loop
display.setTextColor()
used to set the color of the text, in void loop
display.setCursor()
shows were on the board the text starts following the x and y axes
display.println()
displays the actual text, in void loop
display.display()
used to update the arduino with the contents, in the void loop