2.7. I Have a Dream and Soundboard Projects¶
Time Estimate: 90 minutes including the Create Your Own Soundboard project
2.7.1. Introduction and Goals¶
|Be Creative! In this lesson you will complete several small programming projects that add enhancements to the I Have a Dream app. Hints and suggestions are provided.|
(Teacher Tube version)
Learning Objectives: I will learn to
Language Objectives: I will be able to
2.7.2. Learning Activities¶
Enhancing the I Have a Dream App
To get started, open MIT App Inventor in a separate tab and open your I Have a Dream app from the previous lesson. Complete the programming exercises described below and in the preview video. Then, design your own sound board project below.
- Give the app its own custom icon that will appear in the device's app launcher when the app is packaged (built). (Hint: Look in the Screen's properties);
- Use MIT App Inventor's Text-to-Speech component (Media drawer) to get the app to speak some words instead of playing a speech when the Malcolm X button is pressed.
- Have the app vibrate the phone as well as play a speech when the MLK button is pressed (Hint: the Sound component has a Vibrate block. NOTE: Not all Android devices have a vibrate mode, which is usually a Sound setting. For example, Nexus 7 tablets can not vibrate.)
- Use MIT App Inventor's Accelerometer Sensor (Sensor drawer) to trigger Malcolm X's Text-to-Speech when the device is shaken.
Need some help with the Text-to-Speech and Accelerometer? Try watching this video and then debugging your code.
A Sound Board ProjectUse Pair Programming for this project. You and your partner will:
- Create your own Soundboard app with at least three pictures and three sound files that are played when you click the pictures. Make sure that your app doesn't allow the sounds to overlap each other. That is, when you click a button to play a sound, the app should pause any sound that is already playing. This will require the use of an if/else block.
- (Portfolio) Create a short video in .mp4, .wmv, .avi, or .mov format that demonstrates your app. The video must not exceed 1 minute in length and must not exceed 30MB in size. See How To: Create an App Video for help with creating a video. Be sure to post your video to your portfolio.
- (Portfolio) Reflect with your partner on a difficulty you had with coding this app. How did collaboration help you overcome the challenge?
Optional: Create your own icons, images, and sound files for your app using programs such as Paint and Audacity.
Finding Copyright-free Image and Sound Files
Many sounds and images online are copyrighted and it is a violation of copyright to include such images in your app. So, you should be careful about the images and sounds you put into your apps. If you want to use a copyrighted image or sound in your app, you will have to get permission from the holder of the copyright. It might be easier just to search for free media.
There are sites that offer free audio and image files, including the following:
- Google Image Search: search for an image, then on the results page, select Tools. Under the Usage Rights drop-down, select Creative Commons Licenses.
- Sound Bible (free sound files)
- Youtube Sound Effects (free sound files)
- Freesound.org (requires registration)
- Freesfx.co.uk (requires registration)
Resizing Images and Sound Files
MIT App Inventor apps have a 5 Mb size limit. Therefore not all images and sounds you upload will work in your app. Here are some tools that can be used to resize images and sounds:
- On MacOS, the Preview application can be used to resize images. Just open the image in Preview and use the Tools menu to resize it.
- On Windows machines, the Paint application can be used to resize images. Just open the image and use the Resize tool.
- For editing sound files, Audacity is a free and open source sound file editor for all platforms.
- You can also downsize sound files using the free online web app CutMp3.net
- Another online web app you can use to cut your sound files is mp3cut.net
- If your video mp4 file is too big, try uploading to a youtube channel and then click Manage to download as a much smaller mp4 file.
In this lesson, you learned how to:
2.7.5. Reflection: For Your Portfolio¶
Answer the following portfolio reflection questions as directed by your instructor. Questions are also available in this Google Doc where you may use File/Make a Copy to make your own editable copy.