資源描述:
《金屬內(nèi)傷探測器設計研究論文》由會員上傳分享,免費在線閱讀,更多相關(guān)內(nèi)容在學術(shù)論文-天天文庫。
1、畢業(yè)設計(論文)金屬內(nèi)傷探測器設計研究摘要本文是基于單片機AT89S52,利用電感式接近開關(guān)傳感器LJ18A4-10-Z/BD設計一個簡易金屬探測器用于檢測金屬存在并進行金屬個數(shù)計數(shù),包括硬件電路和軟件設計兩大部分。硬件電路由傳感器外圍電路和單片機外圍電路構(gòu)成。電感式接近開關(guān)傳感器是一個感應金屬物體的線性器件,型號為LJ18A4-10-Z/BD的接近開關(guān)在沒有檢測到金屬時會輸出一個電流值,但當檢測到金屬時,輸出電流值會發(fā)生變化。傳感器輸出為電流信號,不能直接進行A/D轉(zhuǎn)換,應通過電流電壓轉(zhuǎn)換電路,把傳感器輸出電流信號轉(zhuǎn)換為滿足A/D轉(zhuǎn)換器PCF8591輸入要求的電壓
2、信號。經(jīng)過A/D轉(zhuǎn)換后的數(shù)字信號,送入單片機處理。軟件設計主要包括A/D轉(zhuǎn)換、數(shù)據(jù)處理、LCD顯示和報警程序四大模塊。PCF8591采集系統(tǒng)開機電壓U0和進入金屬檢測狀態(tài)時的電壓U(x)。數(shù)據(jù)處理主要完成電壓值的精度轉(zhuǎn)換,要求精確到小數(shù)后第二位;計算U0和U(x)差值,并判斷電壓差值和傳感器預設靈敏度是否相等,從而判斷是否檢測到金屬。當傳感器檢測到金屬時,蜂鳴器報警,同時LCD顯示已檢測到的金屬個數(shù)。關(guān)鍵詞:金屬檢測;金屬計數(shù);單片機AT89S52;A/D轉(zhuǎn)換器PCF8591;電感式接近開關(guān)LJ18A4-10-Z/BDAbstractInthispaper,itis
3、todesignasimplemetaldetectorthatcancounttheexistingmetalnumbersonthebasisofmicro-controllerAT89S52andinductiveproximityswitchsensorLJ18A4-10-Z/BD,includingthedesignofhardwarecircuitandsoftware.Thedesignofhardwarecircuitismadeupofthesensor’speripheralcircuitandthemicro-controller’sperip
4、heralcircuit.Inductiveproximityswitchislineardevicethatcaninducetheexistingofmetal.LJ18A4-10-Z/BDsensorwilloutputacurrentwithoutmeasuredobject.Untilitinducesmetal,theoutputcurrentwillbechanged.Becausetheoutputcurrentcannotbeconvertedtodigitalsignaldirectly,currenttovoltageconvertingcir
5、cuithastobeneeded,whichchangestheoutputcurrentsignalofsensorintovoltagesignalthatsatisfiestheinputrequirementsofPCF8591.Afteranalogtodigitalconverter(ADC),thedigitalsignalissenttomicro-controllerforprocessing.ThedesignofsoftwarecontainsfourpartswhichareADC,dateprocessing,liquidcrystald
6、isplay(LCD)andbeepalarming.PCF8591collectstheinitialvoltageUoandU(x).U(x)isthevoltagewhenthesensorisinconditionofdetectingmetal.Inthemoduleofdataprocessingitcompletestheprecisionchangingofcollectedvoltageandcorrectstheresultsto2decimalplaces,meanwhileitcalculatesthedifferencebetweenthe
7、valueofUoandU(x),thencomparethedifferencevaluewiththesensor’spre-establishedprecisionvaluetodecidewhetherthesensorhasinducedmetal.TheBeeperalarmsuntildetectingmetal,atthesametimetheLCDdisplaysthenumberofinducedmetals.Keywords:mentaldetection;metalnumbercounting;micro-controllerAT89S5