Professional Documents
Culture Documents
SignUp(/account/gopro?sourcea=header&sourceaUrl=/id/74LSSeriesDigitalLogicTester/?ALLSTEPS)
ExploreLogin(/account/login)
(/tag/typeid/)
(/about/submit.jsp)
Contests
Community (/community/)
let's make (/contest/)
(/)
(/)
74LSSeriesDigitalLogicTester byZoran1389(/member/Zoran1389/)
Download(/id/74LSSeriesDigitalLogicTester/?download=pdf)
(/id/74LSSeriesDigitalLogicTester/)
Collection
4Steps
IMadeit!
Favorite
Share
(http://cdn.instructables.com/FE0/S1CD/HQGHLI6J/FE0S1CDHQGHLI6J.LARGE.jpg)
*Update*Featuredonwww.freetronics.com
(http://www.freetronics.com/blogs/news/11619617builda74lsseries
digitallogictesterwitharduino#.UtgAf9JDumE
(http://www.freetronics.com/blogs/news/11619617builda74lsseries
digitallogictesterwitharduino#.UtgAf9JDumE))!
Inthefollowinginstructable,Iwilldemonstratehowtodesignacircuitandwrite
atestprogram,usingtheArduinoNano,thatwilltesttwoinputTransistor
TransistorLogic(TTL)gatesincludingAND,OR,NAND,andXOR.The
circuit/programdesignedwillimplementabasictwoinputtruthtableapplying
ALLpossibleinputstothegate(s)whilereadingbacktheresultstotheArduino
SerialMonitorandtheLEDs.Thisverysimplecircuitandcodewilldemonstrate
oneofthebasicbuildingblocksofDigitalLogic.Iwilltrytomakethis
instructableaseasytofollowaspossible,andifyoustillhavesometroubles,
pleasefeelfreetogetincontactwithme.Continueontothenextstepforthe
hardwareandsoftwarerequirements.
AboutThisInstructable
3,972views
License:
21favorites
Zoran1389
(/member/Zoran1389/)
Follow
17
(/member/Zoran1389/)
Bio: Iamanelectricalengineeringand
physicsstudentandIlovetotinkerwith
things.
MorebyZoran1389
(/id/ObstacleAvoiding
Robot1)
(/id/ObstacleAvoiding
RobotV2)
RemovetheseadsbySigningUp(/account/gopro?
sourcea=removeads&nxtPgName=74LS+Series+Digital+Logic+Tester&nxtPg=/id/74LSSeriesDigitalLogicTester/?ALLSTEPS)
Tags:
arduino(/tag/typeid/categorytechnology/keyword
arduino/)
Step1:GatherMaterials
digital(/tag/typeid/categorytechnology/keyword
digital/)
logic(/tag/typeid/categorytechnology/keywordlogic/)
tester(/tag/typeid/categorytechnology/keyword
tester/)
nano(/tag/typeid/categorytechnology/keyword
nano/)
uno(/tag/typeid/categorytechnology/keyworduno/)
IC(/tag/typeid/categorytechnology/keywordic/)
gate(/tag/typeid/categorytechnology/keywordgate/)
74LS(/tag/typeid/categorytechnology/keyword74ls/)
series(/tag/typeid/categorytechnology/keyword
series/)
Related
(http://cdn.instructables.com/F02/TL94/HQGHLMGE/F02TL94HQGHLMGE.LARGE.jpg)
BeingacollegestudentmeansthatIamonatightbudget,thusthisprojectwas
perfectformebecauseofhoweconomicitwas.Themostexpensivepartwas
theArduino,butthatcanalwaysbeeasilyremovedandreprogrammedforuse
onotherprojects.Thetotalcostforthisprojectshouldcomeouttobe$1520.
HardwareList:
ArduinoNano(any5vArduinoofyourchoosingwillwork).
74LSSeriesICs(http://www.futurlec.com/IC74LS00Series.shtml
(http://www.futurlec.com/IC74LS00Series.shtml)).
LEDs(http://www.ebay.com/itm/100pcs3mmLEDRedGreenBlueYellow
WhiteUltraBrightLightBulbsLamp8000mcd/300913115328?
pt=LH_DefaultDomain_0&hash=item460fd1c0c0
(http://www.ebay.com/itm/100pcs3mmLEDRedGreenBlueYellowWhite
UltraBrightLightBulbsLamp8000mcd/300913115328?
pt=LH_DefaultDomain_0&hash=item460fd1c0c0)).
Breadboard(aminibreadboardwasperfectinsize).
Wire
SoftwareList:
ArduinoIDE(myversionis1.0.5).
Asyoucanseethepartslistisveryminimal.Ifyouhaveanyquestions
regardingcomponentcompatibility,I'dbemorethanhappytohelp.Continue
ontothenextstepforthecircuitconstruction.
Threetoolelectronicskit.
(http://www.instructables.com/id/Thre
toolelectronicskit/?
utm_source=base&utm_medium=rela
instructables&utm_campaign=related
BuildaCoinCounter
(http://www.instructables.com/id/Buil
aTTLLogicCoin
counter/?
utm_source=base&utm_medium=rela
TeachingTheLawsof
SignsKit
(http://www.instructables.com/id/Tea
TheLawsofSignsKit/?
utm_source=base&utm_medium=rela
CPUFanHackRGBLEDs
Arduino&TLC5940
(http://www.instructables.com/id/CPU
FanHackRGBLEDs
ArduinoTLC5940/?
BinarytoBCDCounter
UsingTTL's74LS185
(http://www.instructables.com/id/Bina
toBCDCounterUsing
TTLs74LS185/?
SeeMore
(http://www.instructables.com/tag/typeid/?
q=&utm_source=base&utm_medium=related
instructables&utm_campaign=related_test)
Step2:Buildingthecircuit
(http://cdn.instructables.com/FB0/ZU5G/HQGHLMQS/FB0ZU5GHQGHLMQS.LARGE.jpg)
(http://cdn.instructables.com/FJR/MTGP/HQGHLN5X/FJRMTGPHQGHLN5X.LARGE.jpg)
Asyoucansee,thecircuitisverysimple.Makesureyourememberthepolarity
oftheLEDs!Also,makesureyouunderstandwhichpairofbitseachLED
represents,tohelpyou,IhavelabeledtheinputstoeachLEDintheschematic.
Tomaketheinstructableeasiertofollow,Ihavealsoincludedthetwoinputtruth
tableforeachofthegates,asyoucanseethere.
Now,someofyoumightbewonderingwhyIleftouttheNORgateinthis
instructable.Thatisbecauseit'sI/Oistheoppositeoftheothergates,asyou
canseeintheconnectiondiagramspicturedthere.Ifyouhaveanyquestions
regardingthecircuit,pleaseask.Continueontothenextstepforthe
programmingpart.
Step3:Programming
(http://cdn.instructables.com/FWI/J27Y/HQGHLNLJ/FWIJ27YHQGHLNLJ.LARGE.jpg)
(http://cdn.instructables.com/FTI/SFDP/HQGHLOLA/FTISFDPHQGHLOLA.LARGE.jpg)
ThroughoutthecodeIsetinputsas,(Low,Low),(Low,High),(High,Low),and
(High,High)justlikeatruthtable.AfterweassignthesevalueswithHighorLow
weprovideanifstatementtosayiftheinputisHighwhileunderanytruthtable
variationthenx,ourvariable,willhaveanumberaddedtoit.Thenumbers1,2,
4,and8willgiveusdifferentnumbers,astheinputisHigh.ThediagramthatI
havepicturedthereshowsdirectlywhatImean.Ifyouhaveanyquestions
regardingthecode,don'thesitatetoask.
*ToshowtheArduinoSerialMonitorjustgotoTools>SerialMonitorinyour
ArduinoIDE,asIhavepicturedthere.
THECODE:
/*
Designacircuitandwriteatestprogram,usingtheArduinoNano,
thatwilltesttwoinputTransistorTransistorLogic(TTL)gates
includingAND,OR,NAND,andXOR.
By:ZoranM
*/
intgatevalue//Declareallofthevariables
intinputPin=4
intOutput1Pin=2
intOutput2Pin=3
intled=13
intled2=12
intled3=11
intled4=10
intled5=9
//Begindeclaringwhatpiniswhat
voidsetup(){
Serial.begin(9600)
pinMode(Output1Pin,OUTPUT)
pinMode(Output2Pin,OUTPUT)
pinMode(inputPin,INPUT)
pinMode(led,OUTPUT)
pinMode(led2,OUTPUT)
pinMode(led3,OUTPUT)
pinMode(led4,OUTPUT)
pinMode(led5,OUTPUT)
gatevalue=0
}
voidloop(){
gatevalue=gatevalue+(check_Gate(false,false)*8)//WhenaninputisHIGHit
willaddavaluetothegatevalue
gatevalue=gatevalue+(check_Gate(false,true)*4)//andeachgatewillhavea
differentgatevalue.
gatevalue=gatevalue+(check_Gate(true,false)*2)
gatevalue=gatevalue+(check_Gate(true,true)*1)
switch(gatevalue){
case1:
Serial.println("ThegateisanANDgate.")//Whengatevalueis1itisanAND
gate
digitalWrite(led,LOW)//ifgateisin,lightisoff
digitalWrite(led2,LOW)//ANDgatetruthtableoutputsare0,0,0,1whichis
howtheLEDsaresetup
digitalWrite(led3,LOW)
digitalWrite(led4,LOW)
digitalWrite(led5,HIGH)
break
case6:
Serial.println("ThegateisanXORgate.")
digitalWrite(led,LOW)//ifgateisin,lightisoff
digitalWrite(led2,LOW)//Truthtablevalues
digitalWrite(led3,HIGH)
digitalWrite(led4,HIGH)
digitalWrite(led5,LOW)
break
case7:
Serial.println("ThegateisanORgate.")
digitalWrite(led,LOW)//ifgateisin,lightisoff
digitalWrite(led2,LOW)//Truthtablevalues
digitalWrite(led3,HIGH)
digitalWrite(led4,HIGH)
digitalWrite(led5,HIGH)
break
case14:
Serial.println("ThegateisanNANDgate.")
digitalWrite(led,LOW)//ifgateisin,lightisoff
digitalWrite(led2,HIGH)//Truthtablevalues
digitalWrite(led3,HIGH)
digitalWrite(led4,HIGH)
digitalWrite(led5,LOW)
break
default:
Serial.println("ERROR:GateNotPresent.")
digitalWrite(led,HIGH)//ifgateisnotin,lightison
digitalWrite(led2,LOW)
digitalWrite(led3,LOW)
digitalWrite(led4,LOW)
digitalWrite(led5,LOW)
}
gatevalue=0
delay(1000)
}
intcheck_Gate(intoutput1,intoutput2){
intx
digitalWrite(Output1Pin,output1)
digitalWrite(Output2Pin,output2)
delay(5)//Makesurethesignalhastimetopropogatethroughthegate.
x=digitalRead(inputPin)
returnx
}
UploadthecodetoyourArduino,opentheSerialMonitor,andmonitorthe
LEDs.SwitchouttheICsandtestthattheyallworkproperly.Makesurethatthe
SerialMonitorandtheLEDsareoutputtingthecorrectinformation.Continue
ontothenextstepforadditionalpicturesandtheconclusion.
Step4:Additionalpicturesandconclusion
(http://cdn.instructables.com/F37/QCOG/HQGHLO2V/F37QCOGHQGHLO2V.LARGE.jpg)
(http://cdn.instructables.com/F34/DAA9/HQGHLO2Z/F34DAA9HQGHLO2Z.LARGE.jpg)
(http://cdn.instructables.com/FEC/X7ZD/HQGHLO32/FECX7ZDHQGHLO32.LARGE.jpg)
ShowAll7Items
Now,ifyouweren'tawarebynow,thiscircuitandcodeonlytestsoneofthefour
gatesontheICs.Oneaddittion/changetothisprojectthatcouldbemadeisto
(http://cdn.instructables.com/FU8/4S0L/HQGHLO36/FU84S0LHQGHLO36.LARGE.jpg)
testallfourgatesonthechipsimultaneously.Indicateresultsfromeachgate
independently(fail/pass/type),andifonegatefailsthetest,orindicatesa
differentlogicfunctionfromtherest,indicatethetypeofICbymajorityvote(i.e.
ifthetesterfindsthreevalidANDgates,butthefourthgateindicatessomething
OR,identifythechipasanANDgateICwithonebadgate).Therearemany
(http://cdn.instructables.com/F51/ZQTA/HQGHLO31/F51ZQTAHQGHLO31.LARGE.jpg)
variationsandadditionsthatcouldbemadetothisproject,andIwouldloveto
seesomeofyoursevenifyoudiditjustlikeIdid.
(http://cdn.instructables.com/F21/QS9L/HQGHLO3B/F21QS9LHQGHLO3B.LARGE.jpg)
01001000011000010111011001100101001000000110011001110101
0110111000100001
Wehaveabenicecommentpolicy.
Pleasebepositiveandconstructive.
IMadeit!
AboutUs
AddImages
MakeComment
FindUs
WhoWeAre(/about/)
Facebook(http://www.facebook.com/instructables)
Advertise(/advertise/)
Youtube(http://www.youtube.com/user/instructablestv)
Contact(/about/contact.jsp)
Twitter(http://www.twitter.com/instructables)
Jobs(/community/PositionsavailableatInstructables/)
Help(/id/howtowriteagreatinstructable/)
Pinterest(http://www.pinterest.com/instructables)
Google+(https://plus.google.com/+instructables)
Tumblr(http://instructables.tumblr.com)
Resources
Mobile
ForTeachers(/teachers/)
DownloadournewappsforiOS,
ArtistsinResidence(http://www.autodesk.com/artistinresidence/home)
Join!
Join our newsletter: enteremail
GiftProAccount(/account/give?sourcea=footer)
AndroidandWindows8!
Forums(/community/)
Answers(/tag/typequestion/?sort=RECENT)
TermsofService(http://usa.autodesk.com/adsk/servlet/item?siteID=123112&id=21959721) |
Sitemap(/sitemap/)
PrivacyStatement(http://usa.autodesk.com/adsk/servlet/item?siteID=123112&id=21292079) |
Android
(https://play.google.com/store/apps/details?
id=com.adsk.instructables)
LegalNotices&Trademarks(http://usa.autodesk.com/legalnoticestrademarks/) | MobileSite(http://m.instructables.com)
(http://usa.autodesk.com/adsk/servlet/pc/index?id=20781545&siteID=123112)
2014Autodesk,Inc.
GoProToday(/account/gopro?sourcea=footer)
We'reHiring!(/community/PositionsavailableatInstructables/)
English
iOS
(https://itunes.apple.com/app/instructables/id586765571)
Windows
(http://apps.microsoft.com/windows/en
us/app/7afc8194c771441a9590
54250d6a8300)