Hardware Reference
In-Depth Information
This is just a starting point. You now have sufficient knowledge to really make
this multimedia platform into something exciting. Here are some suggestions:
■
Correlate sound frequency and volume with sensor inputs (for example,
an infrared [IR] distance sensor can control the frequency of the speaker
based on movement in front of the unit).
■
Correlate LED intensity with a different metric such as temperature.
■
Add a debounced pushbutton to allow you to dynamically choose the
volume or frequency of the speaker.
■
Program light sequences that match up with simple music.
NOTE
Towatchademovideooftheaudiovisualplatforminaction:
www.exploringarduino.com/content/ch9
.Youcanalsofindthisvideo
ontheWileywebsiteshownatthebeginningofthischapter.
Summary
In this chapter you learned about the following:
■
The SPI bus uses two data lines, a clock line, and a slave select line. An
additional slave select line is added for each slave device, but the other
three lines are shared on the bus.
■
The Arduino SPI library can be used to facilitate easy communication
between the Arduino and slave devices.
■
You can talk to multiple SPI devices over the same bus lines by using
multiple SS pins.
■
You can control SPI potentiometers using the Arduino Library.
■
You learned how to dive deeper into understanding and working with
datasheets.
■
You learned how to simultaneously adjust speaker volume and frequency
using the tone library paired with an SPI digital potentiometer.
Search WWH ::
Custom Search