You are on page 1of 3

BrendanPeachey,NaluPaz,LukeEtinas

BrentSensei
Period2
12/1/15
StepsToTurnOnLEDLightsOnABreadboardw/VoiceCommand
HardwareSetup:
1. GettheCanakitRaspberryPi
2. Getamonitor,akeyboard,amouseandamicrophone
3. Pickoutthesecomponents:Breadboard,RaspberryPi,2bluejumperwires,aresistor,
LEDlight,theTcobblerandtheGPIORibbonCable
4. ConnectthemonitortotheRaspberryPiandpluginallofthepowercords
5. PlugtheRaspberryPiintotheTcobblerwhichistheblackTwithspikesonthebottom
tomakeithavesmallspikesofftheedgeofthebreadboard.
6. PlugtheGPIOintotheTcobblerandtheRaspberryPitoconnectthem
7. Take1jumpercableandplugoneendintheGNDontheTcobbleratthesecondspace
awayfromthesideoftheTcobbler
8. Thengo4downfromtheendofthecobblerandonthe3rdspotawayfromthesideof
thecobbler
9. Thenplugintheresistornexttothesecondpluginspotofthefirstbluejumpercable.
10. Thentaketheendoftheotherresistorandplugitinonthesecondportawayfromthe
otherendoftheresistorandtowardsthebottomendoftheTcobbler

11. PluginthenegativewhichisthelongerendoftheLEDintotheportrightnexttothe2nd
endoftheresistorandplugthepositivesideacrossthegaponthenearestslot.
12. TakeanotherjumpercableandplugoneinhorizontalandonthesamerowastheLED,
resistorandtheendoftheotherjumpercable.
13. Plugtheendofthejumpercableintotheslotthatcorrespondswithnumber17ontheT
Cobbler.

SoftwareSetup:
VoiceCommands:
1. InstallPyAudioandlibportaudio,whichareaudiofilesthatareneededtorecordsound.
2. Recordsoundusingthecodeonpg.178179LearningPythonwithRaspberryPi

3.Correctcertainpartsofthecodetofityourneeds(sample_rate,chunk_size)
4.ConvertWAVfileintoFLACfileformat

5.Usingthecodeonpg.180LearningPythonwithRaspberryPi,sendtheconvertedFLAC
filetoGoogle,andreceiveajson_databack,whichisthewordsthatGoogleSpeechRecognition
recognizesfromthatFLACfile.
6.Oncejson_dataisreturned,usethatOnorOffdatatomanipulatethelight.
7.RunthecodetoinstalltheGPIOcable,andrunthecodetotestoutthelight.
a. Openterminalwindow
b. Typegitclonegit://git.drogon.net/wiringPi,whichthendownloadsthenecessaryfilesto
operatethelight.
c. Nexttype,cdwiringPi,whichchangeswherethePiisfunctioning
d. Type,./build,whichallowscodetobesentthroughtheGPIO
e. /usr/local/bin/gpiogwrite171(whichturnsonLEDlight)
f. /usr/local/bin/gpiogwrite170(whichturnsoffLEDlight)

You might also like