MISSION OBJECTIVE
Learn to create a piano using resistors.
Take our musical talents to the next level as Piperbot and Pip jam out with their new Adult Zomar buddy on a piano made of resistors. Ask students: “What is your code measuring to know when and what sound to play? How is this different from your ultrasonic drum?”
View student interface at make.playpiper.comMISSION CHARACTERS
MISSION MATERIALS
Computer with USB port and Chrome or Edge browser
Piper Make Base Station or Starter Kit
MISSION RESOURCES
Learning Goals
- Students will create a panel of resistors and use a jumper wire to “play notes” and craft musical creations.
- Students will understand how to use lists and mapping in code to map a voltage to a sound.
- Students will understand how voltage drops are associated with the number of resistors set up in series, as shown in the circuitry.
- Create my own musical creations by “playing notes” on a panel of resistors using a jumper wire
- Understand how resistors set up in series are associated with voltage drops
Learning Activities
ELA Extension: Resistor Piano Narrative
- Pair students together or allow them to work independently based on writing level and interest. Students will write a first-person narrative, journal entry, or fictional article from the perspective of a robot, inventor, or musician who creates or discovers a piano powered by resistors.
- Start by setting the scene. Ask students: Where is the resistor piano? Is it on Earth, Mars, or in a secret underground lab? Who built it—and why?
- Next, describe the moment the character realizes the resistors make different sounds. Use language that captures discovery and wonder, such as:
- “Each note buzzed like a hummingbird’s wings.”
- “The red resistor hummed low and steady, like a cello.”
- Have students compose a song through description. Encourage sensory detail, musical metaphors, and emotional reactions to the sound.
- Wrap up the story with a reflective paragraph from the robot or musician about what they learned—about sound, coding, creativity, or connection.
Bonus vocabulary words to include: resistor, tone, input, sound, circuit, frequency, value
EXTENSION: Students illustrate the keys of their piano and annotate which resistor values create specific tones. Then, write a “behind-the-scenes” artist statement explaining their creative process.
ELD Extension: Resistor Piano Language Practice
- Pair students up so that one English Learner (EL) works with one other student who is a non-EL or a higher-level EL. They will begin by exploring different tones from the resistor piano together. One student will press a key while the other describes the sound using sentence frames and visual supports.
Examples:- “The red resistor sounds ___.”
- “It was higher/lower than the last one.”
- “I played the ___ resistor. It sounded like ___.”
- Students will then switch roles and repeat the activity, ensuring both partners practice describing and listening. After both students have taken turns, they will draw a simple diagram of the resistor piano and label the keys with words or symbols that represent the sounds they heard.
- Each student will then retell what their partner described, using their drawing and sentence frames to support accuracy.
Examples: - “My partner said the green resistor was soft.”
- “They thought the blue one sounded like a bell.”
- Partners will give each other feedback based on how clearly and accurately the sounds were described and retold.
Math Extension: Resistor Piano Data & Patterns
- Pair students together or allow them to choose their partners. Partner A will press the resistor piano buttons, while Partner B records the timing, order, and tones. Then, they will switch roles.
- Connect back to sound sequencing and ask students to describe the pattern they hear using everyday or musical language (e.g., “It went slow-fast-slow,” or “It repeated the first note twice.”)
- Start by having students record the following during play:
- The order of notes played (e.g., 1-2-3-2-1)
- The timing between each press (e.g., 1 second, 2 seconds)
- The tone of each note (e.g., low beep, high beep)
- Then have students create a Rhythm Chart to organize their data, showing:
- Button press order
- Time delay between presses
- Tone labels or pitch categories
- Have students graph their pattern using a bar chart or line graph:
- X-axis = time or button order
- Y-axis = tone pitch or category label
- Encourage students to describe the pattern mathematically:
- “Every 2nd note is repeated.”
- “The tone changes every 3rd beat.”
- “Note = Button number × delay in seconds”
- Finally, challenge students to compose a repeating pattern using sequencing and logic, such as ABAB or ABCABC, and label it using ordinal numbers or functions.
Bonus vocabulary words to include: sequence, pattern, input, delay, repeat, order, output.
Career Connections
Robotics Engineer: Salary $104,600/yr
Automotive Engineer: Salary $95,300/yr
Civil Engineer: Salary $88,050/yr
Electro-Mechanical and Mechtronics Technicians: Salary $60,570/yr
Hardware Diagram
Code Diagram
Tutorial Steps
Resistor PianoA Resistor is used to limit the flow of electricity. One of the ways we can use Resistors is to divide a voltage. If we use a lot of Resistors, we can make something that has a bunch of different voltages - and that's what we will use to tell the Pico and your computer what notes to play!
When you "play" your Resistor piano, you will touch one end of the green wire to the Resistor leads marked with numbers in the drawing below.
There are two areas where you should NOT touch the green wire. They are marked with the yellow triangle symbol:
Your Pico has a protection circuit, but it's best not to take an unnecessary risk.
Click NEXT.
The Jumper wires don't have to be the same color as the ones in the diagrams - you can use any color wires that you have.
Make sure that the lead of one Resistor is in the same Breadboard row as the lead of the next one.
After all ten Resistors are inserted, connect one of the black Jumper wires from the right-most Resistor's right lead to a pin in the GROUND rail at the top of the Breadboard. Then, connect another black Jumper wire from a GROUND pin on the Pico to the GROUND rail at the top of the Breadboard.
Next, connect the red Jumper wire from the left-most Resistor's left lead to the Pico's 3.3V pin.
Then, connect the blue Jumper wire from the second Resistor's left lead to the A2 pin of the Pico.
Finally, connect one end of the green Jumper wire into the same Breadboard row as the black Jumper wire and the right-most Resistor.
Once you've built your circuit, click NEXT.
Look carefully at the image above. If the circuit has two Resistors, the junction will be at 1/2 of the voltage. If there are five Resistors in the circuit, then the first junction will be 4/5 of the voltage.
Click NEXT.
Most of the pins on the Pico are digital. this means that when they are set as an input, they can only tell if the voltage coming into the pin is closer to 3.3 volts (ON) or closer to 0 volts (OFF). An analog pin can read any voltage between 0 and 3.3 volts.
This means that we can connect it to our voltage divider and read all of the different voltages that our voltage divider makes!
Let's try it out! Build the program below by dragging out a start block, a repeat forever block, a print block, and a read voltage from block and connecting them together. Set the wait time in the repeat forever block to 0.5 seconds:
Click NEXT.
Then, click CONNECT and START to run the testing program.
The console will start displaying numbers - try touching the green wire to the leads of the Resistors:
If you touch the green wire to the lead labeled (1) in the image above, the console should show 0 (or something very close to it). This is because when you make that connection, you are connecting pin A2 to 0V (ground).
When you touch the green wire to lead (2), you console should show approximately 1.7.
Lead (3) should show approximately 2.2. 2/3 of 3.3V is 2.2.
Lead (4) should show approximately 2.5. 3/4 of 3.3V is 2.5.
Do you see the pattern yet? Click NEXT.
Did you notice that the values in the console match what we learned about voltage dividers?
Click NEXT to find out how.
The voltage of our circuit is 3.3V. All we have to do is take 3.3V minus the value from pin A2:
First, pull the read voltage from pin block out of the print block.
Drag out a _ + _ block from the Logic menu and place it in the print block. Then, grab a 0 block from the Values menu and place it into the left side of the _ + _ block.
Place the read voltage from pin block into the right side of the _ + _ block. Finally, change the "+" (plus) to a "-" (minus), and change the 0 to 3.3:
Lead (1) → 3.3Lead (2) → 1.65Lead (3) → 1.10Lead (4) → 0.83Lead (5) → 0.67
We are getting closer, but with a little more math, we can actually see which lead the green wire is touching.
Click NEXT to find out how.
All we have to do is get the bottom number of the fraction by itself. We do that by dividing 3.3 by our value:
Drag out a round block from the Values menu and place it into the print block.
Drag out a _ + _ block from the Logic menu and place it in the round block. Then, grab a 0 block from the Values menu and place it into the left side of the _ + _ block.
Then, change the "+" (plus) to a "÷" (divide by), and change the 0 to 3.3. Finally, place the 3.3 - read voltage from blocks into the right side of the _ ÷ _ block:
Cool, right? One more thing - what is the value in the CONSOLE when the green wire is not touching any of the Resistor leads? Make a note if it because we are going to need to know that for later.
Click NEXT.
Let's start by storing which Resistor lead is being touched by the green wire into a variable.
Click the Variables menu and create a variable named "note played."
Drag out the set note played to block into the repeat forever loop. Then, pull the blocks from the inside of the print block out and place them in the set note played to block. Finally, delete the empty print block:
Drag out the set note list to block and place it right after the start block. Then, grab a create list with block from the Lists menu and drag it into the set note list to block:
Click the blue gear icon. Drag item blocks into the stack of item blocks until there are 9 of them. Then, click the blue gear icon to close the block's menu:
Click the Values menu to open it. Near the bottom of the list, there is a note block. Drag 9 of those blocks into the list you created in the last step.
Then, click on the variable of each note block and choose a different note for each block:
Right-click the create list block and choose "Collapse Block."
If you need to make it bigger again so that you can make changes to it, you can always right-click it again and choose "Expand Block."
Click NEXT.
10 or 11, right? Basically, our program should only play a note if the note played variable is less than 10.
We want our program to keep reading the A2 pin untilthe note we play is less than 10, and if it is less than 10, exit the loop.
Drag an if _ = _ block from the Logic menu and connect it below the set note played block inside of the repeat forever block. Change the "=" to a ">."
Grab a note played block from the Variables menu and drag it into the left side of the _ > _ block. Drag a 0 block from the Values menu and place it into the right side of the _ > _ block. Change the value to 9.
Set the repeat forever block's wait time to 0. Grab the repeat forever block and pull it away from the set note list block.
Then, grab another repeat forever block from the Loops menu and connect it to the set note list block. Finally, put the first repeat forever block into the new one:
Drag out a play sound block from the Sounds menu and connect it after the inside repeat forever block.
Drag out a instrument block from the Sounds menu and place it into the play sound block. Finally, delete the note block in the instrument block's pitch input:
Drag that block out and place it in the pitch input of the instrument block.
Grab a note list block from the Variables menu and place it in the left side of the in list block. Then, grab a note played block from the Variables menu and place it in the right side of the in list block.
Finally, change the wait time of the outside repeat forever block to 0.15 seconds.
Click EXIT to return to the home screen and try out more tutorials!
Blueprint
OPEN IN BLUEPRINT VIEWER DOWNLOAD
Have an different version? Look for more information on the Support Page.
Troubleshooting Tips
-
Are some notes failing to play when you touch the jumper wire to the resistors?
- Make sure you touch the jumper wire to the metal part of the resistor instead of the plastic.
- Ensure that you have set up the resistors correctly with the metal leads lined up along the rails so they complete the circuit. Check the wiring diagram if you’re not sure.
-
Why do you have to be careful with the top portion of the Pico?
- Touching the green wire to the areas marked with the yellow triangles ⚠️ will cause a short circuit and could damage your Pico module. Be careful!
Our customer support specialists are on hand to ensure your implementation of Piper runs seamlessly.
View Support Docs or Contact Support
EXPANDED RESOURCES
Term Glossary
Engineer Someone who designs, builds, or fixes things to solve problems.
Sensor A device that produces an output signal to sense a physical phenomenon.
Conditional Statement A coding instruction used to compare values and express and make decisions, like an if-then statement.
List A sequence of several values grouped under a single name in code. A group of items or components. A tool used to store multiple pieces of information at once.
Standards Alignment
- CA 3-5.CS.1 Describe how computing devices connect to other components to form a system. (P7.2)
- 3-5.AP.18 Perform different roles when collaborating with peers during the design, implementation, and review stages of program development.

