User Tools

Site Tools


notes:notes:notes:notes:notes:notes:notes:c4eng:fall2022:projects:vcc2

BACKGROUND

In vcc2 we will continue to build onto that baseline of knowledge that we have established from previous projects such as vcc0 and vcc1, to build an even more complex circuit. In this project we will combine different types of LEDs, buttons and switches to create multiple functions within a circuit. Circuit control, in its simplest form, is the application and removal of power. This can also be expressed as turning a circuit on and off or opening and closing a circuit.

ANALOG vs DIGITAL

You will use digital pin modes when dealing with signals that are either “on” or “off”, such as an LED, a switch, or another digital IC. Analog and digital signals are used to transmit information, usually through electric signals. In both these technologies, the information, such as any audio or video, is transformed into electric signals. The difference between analog and digital technologies is that in analog technology, information is translated into electric pulses of varying amplitude. In digital technology, translation of information is into binary format (zero or one) where each bit is representative of two distinct amplitudes.

https://www.diffen.com/difference/Analog_vs_Digital

PULSE-WIDTH MODULATION

This is a method of reducing the average power produced by an electrical signal by effectively chopping it up into discrete parts. The average value of voltage fed to the load is controlled by turning the switch between supply and load on and off at a fast rate.

The longer the switch is on, the higher the total power is to the supplied to the object. PWMs are particularly suited for running inertial loads such as, which is not as easily affected by this discrete switching because their inertia causes them to react slowly.

This means that the switching frequency must be high enough to not affect the load, which means that the resultant wave must be perceived as smooth by the load.

ELECTRONICS

7 10k ohm resistors 3 buttons 1 switch 2 leds 1 rgb LED 1 220 ohm resistor to each LED including rgb LED (3 for rgb LED) 1k ohm to switch

PARTS

RGBLED

This LED is basically THREE LEDs packaged together, all sharing a ground. The Red-Green-Blue (RGB) is three LEDs in one. By controlling the intensities of each of the three component colors individually, you can create all of the colors of the rainbow. The RGB LED in your kit is a common-cathode RGB LED. Each of the three shorter legs controls an individual color (red, green or blue). The fourth, longer leg is a shared ground—-the common cathode. In contrast to standard individual LEDs, the cathode leg on a common-cathode RGB LED is longer than the other legs. (https://learn.sparkfun.com/tutorials/experiment-guide-for-the-johnny-five-inventors-kit/experiment-8-driving-an-rgb-led)

BUTTON

SWITCH

You will also want to utilize a switch, which looks like this:

Your kit should have come with a couple of them, you will need ONE. A switch is a component which controls the open-ness or closed-ness of an electric circuit. They allow control over current flow in a circuit (without having to actually get in there and manually cut or splice the wires). Switches are critical components in any circuit which requires user interaction or control.A switch can only exist in one of two states: open or closed.

The switch circuit will involve hooking up 3.3v to the center pin, putting a 1k resistor between the pin of the switch and the 3.3v source coming from the pi. And ONE of the other pins should then go through a 10k resistor into a GPIO pin on the pi (set to INPUT mode, just like the buttons).

This switch is going to control the DIRECTION of change- one way, it will be INCREASING in value. The other, it will be DECREASING.

notes/notes/notes/notes/notes/notes/notes/c4eng/fall2022/projects/vcc2.txt · Last modified: 2022/09/28 23:47 by 127.0.0.1