简易计算器的PLD实现.docx
- 文档编号:27947370
- 上传时间:2023-07-06
- 格式:DOCX
- 页数:19
- 大小:60.11KB
简易计算器的PLD实现.docx
《简易计算器的PLD实现.docx》由会员分享,可在线阅读,更多相关《简易计算器的PLD实现.docx(19页珍藏版)》请在冰豆网上搜索。
简易计算器的PLD实现
编号
xx大学xx学院
毕业设计(论文)
相关资料
题目:
简易计算机的PLD实现
机电系电子信息工程专业
学号:
学生姓名:
指导教师:
(职称:
讲 师)
(职称:
)
XXXX年X月XX日
目录
一、毕业设计(论文)开题报告
二、毕业设计(论文)外文资料翻译及原文
三、学生“毕业论文(论文)计划、进度、检查及落实表”
四、实习鉴定表
xx大学xx学院
毕业设计(论文)
开题报告
题目:
简易计算机的PLD实现
机电系电子信息工程专业
学号:
学生姓名:
指导教师:
(职称:
讲 师)
(职称:
)
XXXX年X月XX日
课题来源
①随着科技的发展,对于计算器的越来越大,它在人们的经济、生活等各个方面发挥着重要作用。
在我国,对于PLD器件的需求也越来越大。
②以国际大环境为背景,加快高等教育的信息化、国际化进程也是急需的
科学依据(包括课题的科学意义;国内外研究概况、水平和发展趋势;应用前景等)
可编程逻辑器件PLD具有高性能、低成本、低功耗、体积小和可靠性高的特性。
在我国,随着改革开发开放和经济建设的迅速发展,对PLD器件的需求越来越来大。
我国ASIC的设计和生产能力都比较薄弱,而绝大多数的电子产品的密度和速度不是太高,批量也比较小。
因此,广泛使用PLD器件是非常适合提高我国电子产品性能和竞争能力的主要措施之一,应大力普及以及推广。
然而,由于PLD技术的加密功能,又使得我们对于引进技术的消化、吸收和创新具有了一定的难度。
在此情况下,PLD的解析技术应运而生了。
这种技术我国目前处于起步阶段。
采用PLD对器件进行设计是通过对芯片的逻辑功能的设计,以达到系统功能的实现,从而改变了原来的设计方式。
尤其是在系统可编程逻辑器件ISP的生产,给数字系统设计带了了一个飞跃。
研究内容
①通过数字电路基础知识、基础逻辑单元、组合电路时序逻辑电路分析设计方法等基本部分的讲授和实验的训练,掌握必要的数字电子技术的基本理论、基本方法和基本技能,掌握PLD技术,建立数字系统概念。
②可编程逻辑(PLD)是由用户进行编程从而实现所需逻辑功能的数字集成电路(IC),利用PLD内部的逻辑机构可以实现任何布尔表达式或者寄存器函数。
③对于PLD产品的开发必须了解其开发软件和开发流程,了解PLD的内部结构。
详细了解各个芯片功能。
拟采取的研究方法、技术路线、实验方案及可行性分析
①通过强调电子电路系统设计者所需的实用方法,熟悉各个芯片基本功能,掌握电子设计自动化(EDA)技术。
掌握电子元器件的特性和选用方法,从框图及理解其结构原理基础上,达到真正掌握其使用并融会贯通。
②学习研究电子电路的特点,了解PLD的设计步骤。
PLD设计步骤为:
设计构思、选择器件类型、列写原文件、对器件编程。
注意组合电路的输出方程是直接输出的而时序电路方程的输出由时钟值输出的。
总体设计——总体框图——单元电路设计——整体电路设计——软件仿真
研究计划及预期成果
研究计划:
2009年10月12日-2009年12月25日:
按照任务书要求查阅论文相关参考资料,填写毕业设计开题报告书。
2010年1月11日-2010年3月5日:
填写毕业实习报告。
2010年3月8日-2010年3月14日:
按照要求修改毕业设计开题报告。
2010年3月15日-2010年3月21日:
学习并翻译一篇与毕业设计相关的英文材料。
2010年3月22日-2010年4月11日:
电路图设计。
2010年4月12日-2010年4月25日:
用MAX-plusⅡ进行仿真。
2010年4月26日-2010年5月21日:
毕业论文撰写和修改工作。
预期成果:
(1)以掌握知识为基础,培养能力为重点,提高素质为目标,培养创新能力,充分体现大纲的基本目标。
(2)掌握PLD需要了解两个部分:
PLD软件和PLD本身。
(3)理解数制和编码,PLD工作原理和器件的应用个特点。
(4)掌握软件的基本操作,时序分析验证设计的正确性。
特色或创新之处
①PLD发展很快,已由初期的低密度SPLD(如PAL/GAL)等,向高密度的CPLD发展。
②PLD可以完成任何数字器件的功能,上至高性能CPU,下至简单的74系列电路都可以利用PLD来实现。
已具备的条件和尚需解决的问题
①电路的设计已经完成,仿真结果也正确,说明总电路图不但正确而且具备了应有的功能。
②用VHDL语言设计的能力尚需加强。
指导教师意见
指导教师签名:
年月日
教研室(学科组、研究所)意见
该生查阅了大量的相关资料,设计方案合理,同意开题。
教研室主任签名:
年月日
系意见
主管领导签名:
年月日
英文原文
ntroducingtheVirtualDIYCalculator
Whenyoucometothinkaboutit,therearelotsof“applicationtype”computerbooksalongthelinesofLearnProf.CuthbertDribble’sVisualProgrammingV6.0In21Days(youoftenhaveonly21days,becausethat’swhenversion7.0ofthesoftwareisgoingtocomeout).Sadtorelate,however,therereallyaren’tmanytomes–outsideofmega-complexUniversitycourses–thatteachhowcomputersactuallywork.
Inordertoaddressthissadstateofaffairs,theauthorsdecidedtopentheirownhumbleoffering.Onepointweconsideredisthatit’saloteasiertolearnhowtodosomethingifyouactuallyhaveaspecificprojectinmind.
Forexample,ifsomeonesimplyhandsyouaplankofwood,asaw,ahammerandsomenails,youmighthangaroundforawhileponderingjustwhattodo.Butifyouarealsopresentedwiththeplansforasimplebirdtable,thenyoucanimmediatelyleapintothefraywithgustoandabandon.
Thus,wedecidedtobaseabook(detailsaregivenlater)ontheconceptofasimplecalculatorcalledtheDIYCalculator,thecunningpartofallofthisisthatwecreatedtheDIYCalculatorasavirtualmachinethatrunsonyourhomecomputer.Thisarticleisaspin-offfromthebookandisdesignedtogiveabriefintroductionastohowtheDIYCalculatorfunctions.
ComputersandCalculators
Initsbroadestsense,acomputerisadevicethatcanacceptinformationfromtheoutsideworld,processthatinformationusinglogicaland/ormathematicaloperations,makedecisionsbasedontheresultsofthisprocessing,andultimatelyreturntheprocessedinformationtotheoutsideworldinitsnewform.
Themainelementsformingacomputersystemareitscentralprocessingunit(CPU),itsmemorydevices(ROMandRAM)thatareusedtostoreprograms(sequencesofinstructions)anddata,anditsinput/output(I/O)portsthatareusedtocommunicatewiththeoutsideworld.TheCPUisthe“brain”ofthecomputer,becausethisiswhereallofthenumber-crunchinganddecision-makingisperformed.Read-onlymemory(ROM)hasitscontentshard-codedaspartofitsconstruction;bycomparison,inthecaseofrandomaccessmemory(RAM),youcanloadnewvaluesintoitandreadthesevaluesbackoutagainlater.
Theterm“bus”isusedtorefertoagroupofsignalsthatcarrysimilarinformationandperformacommonfunction.Acomputeractuallymakesuseofthreebusescalledthecontrolbus,addressbus,anddatabus.TheCPUusesitsaddressbusto“point”toothercomponentsinthesystem;itusesthecontrolbustoindicatewhetheritwishesto“talk”(output/write/transmitdata)or“listen”(input/read/receivedata);anditusesthedatabustoconveyinformationbackandforthbetweenitselfandtheothercomponents.Ourvirtualcomputerisequippedwithadatabusthatiseightbitswideandanaddressbusthatis16addressbustopointto216=65,536differentmemorylocations,whicharenumberedfrom0to65,535indecimal;or$0000to$FFFFinhexadecimal,wheretheconceptsofbinaryandhexadecimalarebrieflyintroducedalittlelaterinthisarticle.
Oncewe’veconceivedtheideaofageneral-purposecomputer,thenextstepistothinkofsomethingtodowithit.Infacttherearemillionsoftaskstowhichcom
puterscanbeassigned,buttheapplicationwe’reinterestedinhereisthatofasimplecalculator.Sowhatdoesittaketocoerceacomputertoadopttheroleofacalculator?
Well,onethingwerequireissomeformof
userinterface,whichwillallowustopresentdatato–andviewresultsfrom–thecomputer(Figure1).
Figure1.Themainelementsformingacomputer-calculator
Thecalculator’suserinterfaceprimarilyconsistsofbuttonsandsometypeofdisplay.Eachbuttonhasauniquebinarycodeassociatedwithit,andthiscodewillbepresentedtothecomputer’sinputportwheneverthatbuttonispressed.Meanwhile,oneofthecomputer’soutputportscanbeusedtodrivethedisplayportionoftheinterface.
ASimpleTestCase
Inamomentwe’regoingtocreateourownprogram,butbeforewestart,weneedtounderstandthatcomputersstoreandmanipulatedatausingthebinarynumbersystem,whichcomprisesjusttwodigits:
0and1.Onewire(orregisterbit/memoryelement)canbeusedtorepresenttwodistinctbinaryvalues:
0or1;twowirescanrepresentfourbinaryvalues:
00,01,10,and11;threewirescanrepresenteightbinaryvalues:
000,001,010,011,100,101,110,and111;andsoon.Asourvirtualcomputerhasan8-bitdatabus,thiscanbeusedtorepresent256differentbinaryvaluesnumberedfrom0to255indecimalor%00000000to%11111111inbinary(wherethe“%”symbolisusedtoindicateabinaryvalue).
Theproblemisthathumanstendtofinditdifficulttothinkintermsoflongstringsof0sor1s.Thus,whenworkingwithcomputers,wetendtopreferthehexadecimalnumbersystem,whichcomprises16digits:
0through9andAthroughFasshowninFigure2.
Figure2.Binaryandhexadecimal
Inthiscase,weuse“$”characterstoindicatehexadecimalvalues.Eachhexadecimaldigitdirectlymapsontofourbinarydigits(andviceversaofcourse).Thisexplainswhywenotedearlierthatour16bitaddressbuscouldbeusedtopointto216=65,536differentmemorylocations,whicharenumberedfrom$0000to$FFFFinhexadecimal.
TheAccumulator(ACC)andStatusRegister(SR)
Therearejustacouplemorethingsweneedtoknowbeforeweplungeheadfirstintothefray.Amongstotherthings,ourCPUcontainstwo8-bitregisterscalledtheaccumulator(ACC)andthestatusregister(SR).(Inthiscontext,theterm“register”referstoagroupofmemoryelements,eachofwhichcanstoreasinglebinarydigit.)
Asitsnameimplies,theaccumulatoriswheretheCPUgathers,or“accumulates”,intermediateresults.Inthecaseofthestatusregister,eachofitsbitsiscalledastatusbit,buttheyarealsocommonlyreferredtoasstatusflagsorconditioncodes,becausetheyservetosignal(flag)thatcertainconditionshaveoccurred.Wewillonlyconcernourselveswiththecarry(C)flagforthepurposesofourexampleprogram.
Sincewemaysometimeswishtoloadthestatusregisterfrom(orstoreitto)thememory,itisusualtoregardthisregisterasbeingthesamewidthasthedatabus(eightbitsinthecaseofourvirtualsystem).However,ourCPUemploysonlyfivestatusflags,whichoccupythefiveleast-significantbitsofthestatusregister.Thismeansthatthethreemost-significantbitsoftheregisterexistonlyinourimaginations,sotheirnon-existentcontentsare,bydefinition,undefined.
TheProgramItself
Forthepurposesofthisarticle,we’regoingtocreateasimpleprogramthatfirstclearsthecalculator’smaindisplay,andthenloopsaroundwaitingforustoclickoneorbuttonsonthekeypad.Ifanyofthesebuttonsarepartofthe“0”through“9”or“A”through“F”set,we’regoingtodisplaythesevalueonthemaindisplay.Let’swalkthroughthiscodestep-by-step.
Thefirstthingwedoistodeclaresomeconstantlabelsandassociatedthemwithcertainvaluesusing.Inthecaseofthisprogram,theCLRCODElabelisassociatedwithahexadecimalvalueof$10,whichisaspecialcodethatwillclearthecalculator’smaindisplay.Bycomparison,theMAINDISPlabelisassociatedwiththehexadecimalvalue$F031,whichhappenstobetheaddressoftheoutputportthatdrivesthecalculator’smaindisplay.Similarly,theKEYPADlabelisassociatedwiththehexadecimalvalue$F011,whichistheaddressoftheinputportthatisconnectedtothecalculator’skeypad.(Notethateverythingtotherightofa“#”characteristreatedasacommentandisthereforeignoredbyth
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- 简易 计算器 PLD 实现
![提示](https://static.bdocx.com/images/bang_tan.gif)