Proteus 串口资料COMPIM Serial Port Model

COMPIM Serial Port ModelIntroductionTraditionally, simulation systems have had no direct connection

COMPIMSerialPortModel Introduction Traditionally,simulationsystemshavehadnodirectconnectiontothephysicalworldaroundthem. Thismeantthatifyouwantedtosimulatepartofamuchbiggersystemofinterconnectedunits, onehadtoeithercreatesimulationsoftheotherunits,orcreatefilescontainingtestdata. TheVirtualSystemModellingcapabilitiesofProteusVSMallowthecreationofmodelsthatcan actuallyinteractwiththephysicalworld.WecallsuchmodelsPhysicalInterfaceModelsorPIMs forshort. TheCOMPIMmodelisaPhysicalInterfaceModelofaserialport.Incomingserialdatais bufferedandpresentedtothecircuitasadigitalsignal,whilstserialdigitaldatageneratedbya CPUorUARTmodelappearsatthePC'sphysicalCOMport.TheCOMPIMmodelalso providesforbaudratetranslation,andforoptionalhardwareorsoftwarehandshakingonboththe physicalandvirtualsidesofthedevice. ThisallowsanyrealworldhardwareequippedwithaserialporttointeractwithaVSMsimulation. Forexample,youcoulduseittodevelopaprogramforamicroprocessorwithinProteusVSMthat wouldoperatearealphysicalmodem,perhapsaspartofasecurityorhomeautomationsystem. Alternatively,amonitordebuggerrunningononePCcanbeusedtodebugasimulateddesign runningwithinVSM. TheCOMPIMmodelcanalsobeusedforsomesimpledigitalI/O:theCTS,DSR,DCDandRI linesonthephysicalserialportcanactasrudimentarydigitalinputsfromexternalstimulus,such asswitches;theRTSandDTRlinesonthephysicalserialportcanactasrudimentaryoutputs. Bearinmindthatthesesignalsmayneedadditionphysicalsignalconditioning,dependingon applicationandporttype. DeviceLayout COMPIMhaseightpins:TXD,RXD,CTS,RTS,DSR,DTR,DCDandRI. ● TXD,RTSandDTRareinputstothedeviceandbecomeoutputsonthephysicalport. ● RXD,CTS,DSR,DCDandRIareinputsfromthephysicalportthatbecomeoutputsonthe device. ThismeansthattheCOMPIMrepresentsaDCEontheschematic.Bycontrast,theVTERM model(beingaterminal)iswiredasaDTE.ThephysicalCOMportitselfiswiredasaDTE (TXDisanoutput). Whenasimulationisinitiated,theterminalsoftheDB-9connectorinsidetheCOMPIMdevice symbolbecomeindicators.TheTXDandRXDterminalssindicateactivityonthecorresponding physicalportpins.TheindicatorsforCTS,RTS,DSR,DTR,DCDandRIshowthestateofthe

腾讯文库Proteus