9
Unit 7: Programming (Electronic Music) Lesson 1: What is Electrical Engineering? U07_L01_03-H1-Circuit_Diagram Circuit Background: You can build an electronic system to play simple melodies using these components: Arduino microcontroller Breadboard and wires 10kΩ potentiometer Piezoelectric speaker USB cable (standard A to B) Computer with USB port and Arduino-compatible software Below are brief descriptions of some of the more common electrical components and symbols found in electrical diagrams, or schematics. Component Description Symbol Piezoelectric Buzzer: These buzzers use a special crystal that expands and contracts to create sound. Potentiometer: A variable resistor that resists the flow of electricity, and prevent too much current from flowing to the speaker. This will serve as a volume knob. Copyright 2016-17, The Board of Regents of the University of Texas System. All Rights Reserved. Requests to reproduce any part of this material may be made to Engineer Your World. Page 1 of 9

 · Web viewA variable resistor that resists the flow of electricity, and prevent too much current from flowing to the speaker. This will serve as a volume knob

  • Upload
    others

  • View
    5

  • Download
    0

Embed Size (px)

Citation preview

Page 1:  · Web viewA variable resistor that resists the flow of electricity, and prevent too much current from flowing to the speaker. This will serve as a volume knob

Unit 7: Programming (Electronic Music)Lesson 1: What is Electrical Engineering? U07_L01_03-H1-Circuit_Diagram

Circuit Background:

You can build an electronic system to play simple melodies using these components:

Arduino microcontroller Breadboard and wires 10kΩ potentiometer Piezoelectric speaker USB cable (standard A to B) Computer with USB port and Arduino-compatible software

Below are brief descriptions of some of the more common electrical components and symbols found in electrical diagrams, or schematics.

Component Description Symbol

Piezoelectric Buzzer:These buzzers use a special crystal that expands and contracts to create sound.

Potentiometer:A variable resistor that resists the flow of electricity, and prevent too much current from flowing to the speaker. This will serve as a volume knob.Breadboard:A breadboard is used to make electrical connections between sockets or pins. It makes constructing circuits simple.

Jumper Wires:Wires are used to make electrical connections.

Connected (dot = “node”)

Not Connected

or

Copyright 2016-17, The Board of Regents of the University of Texas System. All Rights Reserved.Requests to reproduce any part of this material may be made to Engineer Your World. Page 1 of 7

Page 2:  · Web viewA variable resistor that resists the flow of electricity, and prevent too much current from flowing to the speaker. This will serve as a volume knob

Unit 7: Programming (Electronic Music)Lesson 1: What is Electrical Engineering? U07_L01_03-H1-Circuit_Diagram

Below is an example of a speaker system that is depicted in a schematic. This diagram shows one way to connect different components together with wires to make sounds. Note that the speaker may or may not have polarity; or in other words, it may have a positive and a negative pin. If your speaker is labeled with a positive and/or negative mark, make sure to place it in the correct orientation in the circuit. Also the USB cable connects to a computer, not shown in this diagram.

Building the circuit:

Using the given components, your team can start building the physical circuit that is represented by the electrical schematic above. For every physical connection that is made between two components (e.g. pin 12 of the Arduino to a potentiometer via the breadboard), highlight the corresponding connection depicted in the schematic.

If you build your circuit correctly, you should make a closed circuit, which is necessary for electricity to make its way through every component.Copyright 2016-17, The Board of Regents of the University of Texas System. All Rights Reserved.Requests to reproduce any part of this material may be made to Engineer Your World. Page 2 of 7

Page 3:  · Web viewA variable resistor that resists the flow of electricity, and prevent too much current from flowing to the speaker. This will serve as a volume knob

Unit 7: Programming (Electronic Music)Lesson 1: What is Electrical Engineering? U07_L01_03-H1-Circuit_Diagram

Recommended Steps:

Step 1:Place speaker on the breadboard, and connect the rows across the ditch with wires from a wire kit. After this is done, push speaker against the bread board so that its pins are firmly in the sockets.

Step 2: Connect the potentiometer to the speaker. Notice that the potentiometer has three leads, but we will only have to connect two leads. One lead will not be connected to anything.

Per the schematic, one of the outer leads of the potentiometer will be connected to one side of the speaker.

The middle lead of the potentiometer will eventually connect to pin 12 of the Arduino.

See the schematic and the close-up photo on the next page for an example layout. Make sure the leads are place firmly in the sockets by pressing down on the component.

Copyright 2016-17, The Board of Regents of the University of Texas System. All Rights Reserved.Requests to reproduce any part of this material may be made to Engineer Your World. Page 3 of 7

Notice that the leads of the speaker are connected to rows 1 and 7 on the breadboard. Depending on your speaker, your row numbers may be different.

These wires belong in the same rows as the speaker leads. Placing them across the ditch allows for more connections to be made to each row.

Ditch

Page 4:  · Web viewA variable resistor that resists the flow of electricity, and prevent too much current from flowing to the speaker. This will serve as a volume knob

Unit 7: Programming (Electronic Music)Lesson 1: What is Electrical Engineering? U07_L01_03-H1-Circuit_Diagram

Step 3: Connect the Arduino Microcontroller to the breadboard. Per the schematic, notice that

The center lead of the potentiometer is connected to pin 12 on the Arduino. Make this connection between the microcontroller and the breadboard using a jumper wire.

The other side of the speaker needs to be connected to a GND pin on the Arduino. Also make this connection between the microcontroller and the breadboard using a jumper wire.

Copyright 2016-17, The Board of Regents of the University of Texas System. All Rights Reserved.Requests to reproduce any part of this material may be made to Engineer Your World. Page 4 of 7

Lead in breadboard but not connected to anything (shown here in row 5)

Center lead will connect to pin 12 of the Arduino in step 3 (shown here in row 6)

Outer lead connected to one side of the speaker (shown here in row 7)

Leave at least a column of empty sockets for the next step

Page 5:  · Web viewA variable resistor that resists the flow of electricity, and prevent too much current from flowing to the speaker. This will serve as a volume knob

Unit 7: Programming (Electronic Music)Lesson 1: What is Electrical Engineering? U07_L01_03-H1-Circuit_Diagram

Final Circuit:

After it is built, it may look something like this photo. Note that connections exist underneath the speaker; the size of the speaker makes those connections difficult to photograph. Note the Arduino connects to a computer via a USB cable, which is not shown here.

Copyright 2016-17, The Board of Regents of the University of Texas System. All Rights Reserved.Requests to reproduce any part of this material may be made to Engineer Your World. Page 5 of 7

This wire is connected to the center lead of the potentiometer (row 6 in this example). The other end of this wire is connected to pin 12 on the Arduino.

This wire is connected to the second pin of the speaker (row 1 in this example). The other end of this wire is connected to a GND (ground) pin on the Arduino.

Page 6:  · Web viewA variable resistor that resists the flow of electricity, and prevent too much current from flowing to the speaker. This will serve as a volume knob

Unit 7: Programming (Electronic Music)Lesson 1: What is Electrical Engineering? U07_L01_03-H1-Circuit_Diagram

To verify your circuit, continue to the next lesson and program your system to beep. Remember that the potentiometer will serve as a volume knob.

Copyright 2016-17, The Board of Regents of the University of Texas System. All Rights Reserved.Requests to reproduce any part of this material may be made to Engineer Your World. Page 6 of 7

Page 7:  · Web viewA variable resistor that resists the flow of electricity, and prevent too much current from flowing to the speaker. This will serve as a volume knob

Unit 7: Programming (Electronic Music)Lesson 1: What is Electrical Engineering? U07_L01_03-H1-Circuit_Diagram

How does it work?

To help explain what this system does, a simple functional model of the system is shown below, not including the computer.

The USB port receives 5V of power from the computer. It also both receives and sends electrical signals between the Arduino system and the computer.

The Arduino microcontroller then transmits this electrical energy in pulses to the resistor, through wires and the breadboard.

The resistor resists flow of electrons. It converts some of the electrical energy to heat, which is released into the air. This decreases the voltage of energy flowing into the piezoelectric speaker. That helps protect the speaker, and it also will decrease the speaker volume.

The speaker converts the remaining electrical energy to mechanical energy. As the electrons flow through the piezoelectric material in pulses, the speaker expands and contracts in pulses, too. This also makes the air around it expand and contract in waves. Our ears hear these waves as sound.

The remaining electrical energy is essentially used up after going through the speaker. The electrons flow back to the Arduino and back into the computer.

Reference: “Getting Started with Arduino”. Arduino SA. http://arduino.cc/en/Guide/HomePage. Feb 2014.

Copyright 2016-17, The Board of Regents of the University of Texas System. All Rights Reserved.Requests to reproduce any part of this material may be made to Engineer Your World. Page 7 of 7

Electrical signals (to computer)Transmit mechanical

energy (to air)

Resist electrical energy; convert some to heat

Sound (pneumatic vibration)

Heat

Release heat

Transmit remaining electrical energy

Convert electrical energy to mechanical

energy

Transmit electrical energy in pulses

Electrical energy and signals (from computer)

Receive electrical energy and signals