关闭

关闭

关闭

封号提示

内容

首页 spdif

spdif.pdf

spdif

peter
2011-10-10 0人阅读 0 0 0 暂无简介 举报

简介:本文档为《spdifpdf》,可适用于IT/计算机领域

SPDIFSpecificationAuthor:GeirDrangegedraopencoresorgRevJuly,OpenCoresSPDIFInterfacewwwopencoresorgReviiThispagehasbeenintentionallyleftblankOpenCoresSPDIFInterfacewwwopencoresorgReviiiRevisionHistoryRevDateAuthorDescriptionGeirDrangeFirstDraftGeirDrangeUpdatedGeirDrangeRenamedgenericsandmodifiedreceiverconfigurationregisterGeirDrangeCorrectedafewtypo’sGeirDrangeChangedtwointerruptsintransmitterGeirDrangeCorrectedsometypo’sGeirDrangeFinalcorrectionsbeforereleaseOpenCoresSPDIFInterfacewwwopencoresorgRevivContentsSPDIFRECEIVERSPDIFTRANSMITTERRECEIVERResettingCaptureregistersEnablereceiverTransferringdataTRANSMITTERResettingSelectingtransmitdatarateSelectingdataformatSettingupchannelstatusbitsSettingupuserdatabitsPreparingsamplebufferStarttransmissionGENERICSFORBOTHTRANSMITTERANDRECEIVERGENERICSFORTHERECEIVERGENERICSFORTHETRANSMITTERSPDIFRECEIVERReceiverregistersoverviewRxVersion–DescriptionRxConfig–DescriptionRxStatus–DescriptionRxIntMask–DescriptionRxIntStat–DescriptionChStCap<n>–DescriptionChStData<n>–DescriptionReceivesampledata–DescriptionSPDIFTRANSMITTERTransmitterregistersoverviewTxVersion–DescriptionTxConfig–DescriptionTxChStat–DescriptionTxIntMask–DescriptionTxIntStat–DescriptionUserData–DescriptionChStat–DescriptionTransmitsampledata–DescriptionOpenCoresSPDIFInterfacewwwopencoresorgRevvWISHBONEINTERFACESIGNALS(RECEIVERTRANSMITTER)SPDIFRECEIVERSIGNALSSPDIFTRANSMITTERSIGNALSOpenCoresSPDIFInterfacewwwopencoresorgRevofIntroductionTheSPDIF(orAESEBU,IECstandards)isapointtopointprotocolforserialtransmissionofdigitalaudiothroughasingletransmissionlineThetransmissionmediumcanbeeitherelectricaloroptical(egTosLink)Itprovidestwochannelsforaudiodata,amethodforcommunicatingcontrolinformation,andsomeerrordetectioncapabilitiesThecontrolinformationistransmittedasonebitpersampleandaccumulatesinablockstructureThedataisbiphaseencoded,whichenablesthereceivertoextractaclockfromthedataCodingviolations,definedaspreambles,areusedtoidentifysampleandblockboundariesSPDIFinterfacesarefoundonmostCDDVDplayers,audioequipmentandcomputersoundcardsOpenCoresSPDIFInterfacewwwopencoresorgRevofArchitectureTheSPDIFinterfaceconsistsoftwoseparatecores,atransmitterandareceiverSPDIFReceiverThereceiverarchitectureisshownbelowFigure:ReceiverBlockDiagramWishboneBusInterruptSPDIFInRegistersPhasedetectorDatacaptureregistersFramedecoderSamplebufferSampleextractorOpenCoresSPDIFInterfacewwwopencoresorgRevofThebiphaseencodedSPDIFsignalisdecodedbyanoversamplingphasedetectorThewishbonebusclockisusedtosampletheinputsignal,andmustbeatleasttimeshigherthanthenSPDIFdatarateThelowestSPDIFbitratesupportediskHzAframedecoderlocksontothecodeviolations(preambles)thatmarkthestartofframesandsubframesAudiodataisextractedandplacedintothesamplebufferThesizeofthesamplebufferisdeterminedbytheWishboneaddressbuswidthMinimumsamplebuffersizeisbytesThesamplebufferisaddressedbysettingthemostsignificantaddressbitto‘’Thesamplebufferisdividedintwoequalparts,lowerandupper,andtheuserwillbenotifiedwheneitherisfilledwithaudiodataSubframestatusbitscanoptionallybeincludedinthesamplebufferSPDIFTransmitterThetransmitterarchitectureisshownbelowFigure:TransmitterBlockDiagramThesubframeassemblercreatesbitdatawordsfromsampledata,registersettingsandoptionallychannelstatususerdatabuffersAparitybitisaddedineachsubframeTheframeassembleraddspreamblestocreateaframeoftwosubframesframesadduptoablockTheblockstructureisbiphaseencodedbeforetransmittingWishboneBusInterruptSPDIFoutRegistersPhaseencoderChannelstatususerdatabuffersFrameassemblerSamplebufferSubframeassemblerBuffercopyOpenCoresSPDIFInterfacewwwopencoresorgRevofThesizeofthesamplebufferisdeterminedbytheWishboneaddressbuswidthMinimumsamplebuffersizeisbytesThesamplebufferisaddressedbysettingthemostsignificantaddressbitto‘’Thesamplebufferisdividedintwoequalparts,lowerandupper,andtheuserwillbenotifiedwheneitherisemptiedofaudiodataChannelstatuscanbegeneratedfromadedicatedbitbufferTwointerruptscanbegeneratedwhenthetransmitterreadsfromthebuffer,oneinthemiddleandoneattheendTheuserdatabufferoperatesinanidenticalwayOpenCoresSPDIFInterfacewwwopencoresorgRevofOperationThischaptercontainsoperationalguidelinesforthecoresReceiverSomefeaturesarenotavailablewhenthecoreissynthesizedinbitmodeResettingExceptfortheWishbonereset,thereceivercanbedisabledbyclearingtheRXENbitintheRxConfigregisterCaptureregistersBeforethereceiverisenabled,thecaptureregistersshouldbesetuptocapturebitfieldsofinterest,likesamplefrequency(bitinconsumermode)EnablereceiverSetRXENbitinRxConfigregistertoenablethereceiverThenwaituntiltheLOCKbitissetintheRxStatusRegisterExaminetheotherstatusbitsinRxStatusregistertoidentifythetypeofsignalbeingreceived,andsetuptheotherbitsintheRxConfigregisterFinallysettheSAMPLEbittostartdatatransfertothesamplebuffersTransferringdataThebestwaytoreadoutdataistosetupaninterrupttobegeneratedwhenthelowerorupperbufferisfull,andthenexecuteablockreadofthedataTransmitterResettingExceptfortheWishbonereset,thetransmittercanbedisabledbyclearingtheTXENbitintheTxConfigregisterOpenCoresSPDIFInterfacewwwopencoresorgRevofSelectingtransmitdatarateThedatarateoftheSPDIFsignalisafunctionoftheWishbonebusclockandtheRATIObitsintheTxConfigregisterThebitrateistimesthesamplingfrequency–eachsampleisencodedasbitsandtherearetwochannelsSamplefrequencyisgivenbythefollowingequation:)(⋅=RATIOfrequencyclockWishboneSfreqExample:DatarateiskHzandWishboneclockfrequencyisMHzTheRATIObitsmustthenbesettoOutputdatarateisMbpsSelectingdataformatIftheWishbonedatabusisbit,itisonlypossibletosendbitaudiodataInbitmode,anysampleresolutionfromtobitcanbetransmittedDataformatisselectedbytheMODEbitsintheTxConfigregisterSettingupchannelstatusbitsIfoutputformatisstandardconsumeraudio,setCHSTENtoinTxConfig,andsetTxChStattodesiredformatOtherwisesetuptheChStatusbufferwithdesiredchannelstatusdata(bits)Ifthechannelstatusbitsarenotchangingfromblocktoblock,itisonlynecessarytoprogramthebufferonceOtherwisetheHCSBFLCSBFbitsinTxIntMaskmustbeset,andthebufferwillneedtobeupdatedforeveryhalfblocktransmittedSettingupuserdatabitsUserdatabitsarenormallysettozero,butifrequireduserdatacanbetransmittedusingtheUserDatabufferIftheuserdatabitsarenotchangingfromblocktoblock,itisonlynecessarytoprogramthebufferonceOtherwisetheHCSBFLCSBFbitsinTxIntMaskmustbeset,andthebufferwillneedtobeupdatedforeveryblockPreparingsamplebufferBeforetheTXDATAbitinTxConfigisset,fillupthecompletesamplebufferwithaudiodataThetransmitterwillgenerateaninterruptwhenlowerhalforupperhalfofsamplebufferisemptied,StarttransmissionTransmissionofSPDIFsignalstartswhentheTXENbitinTxConfigissetIfTXDATAbitisnotset,thetransmitteddatawillbeallzeroeswiththesubframevaliditybitsetOpenCoresSPDIFInterfacewwwopencoresorgRevofOncetheTXDATAbitisset,audiodatafromthesamplebufferwillbetransmittedandthevaliditybitisclearedOpenCoresSPDIFInterfacewwwopencoresorgRevofGenericsTheSPDIFinterfacehasanumberofgenericsthatcanbeusedtotailortheinterfaceforvariousneedsGenericsforbothtransmitterandreceiverNameTypeRangeDescriptionDATAWIDTHIntegerWishbonedatabuswidthIfusingbitbus,somefunctionalityislostADDRWIDTHIntegerWishboneaddressesbuswidthThesamplebufferoccupieshalftheaddressrangeTable:GenericsfortransmitterandreceiverGenericsforthereceiverNameTypeRangeDescriptionCHSTCAPTUREInteger–SpecifiesthenumberofchannelstatuscaptureregistersOnlyapplicableinbitmodeWISHBONEFREQNaturalWishBonebusfrequencyinMHzThisgenericisusedtooptimizethephasedetectorTable:GenericsforreceiverGenericsforthetransmitterNameTypeRangeDescriptionUSERDATABUFInteger–:Nouserdatabufferisgenerated:UserdatabufferisgeneratedCHSTATBUFInteger–:Nochannelstatusdatabufferisgenerated:ChannelstatusdatabufferisgeneratedTable:GenericsfortransmitterOpenCoresSPDIFInterfacewwwopencoresorgRevofRegistersThissectionspecifiesallinternalregistersoftheSPDIFinterfaceSPDIFReceiverReceiverregistersoverviewNameAddressWidthAccessDescriptionRxVersionxRVersionregisterRxConfigxRWConfigurationregisterRxStatusxRSignalStatusRegisterRxIntMaskxRWInterruptmaskregisterRxIntStatxRWInterruptstatusregisterThefollowingregistersareoptionaldependingonthevalueofCHSTCAPTUREChStCapxRWChannelstatuscaptureregisterChStDataxRChannelstatusdataregisterChStCapxRWChannelstatuscaptureregisterChStDataxRChannelstatusdatadataregisterChStCapxRWChannelstatuscaptureregisterChStDataxRChannelstatusdatadataregisterChStCapxRWChannelstatuscaptureregisterChStDataxRChannelstatusdatadataregisterChStCapxRWChannelstatuscaptureregisterChStDataxRChannelstatusdatadataregisterChStCapxaRWChannelstatuscaptureregisterChStDataxbRChannelstatusdatadataregisterChStCapxcRWChannelstatuscaptureregisterChStDataxdRChannelstatusdatadataregisterChStCapxeRWChannelstatuscaptureregisterChStDataxfRChannelstatusdatadataregisterTable:ReceiverregistersOpenCoresSPDIFInterfacewwwopencoresorgRevofRxVersion–DescriptionTheversionregisterallowstheSWtoreadoutalltheparameterthat’swasusedtogeneratethereceiverBit#AccessNameDescriptionUnusedCAPNOThevalueofCHSTCAPTUREUnusedADRWThevalueofADDRWIDTHDATW:DATAWIDTHisbit:DATAWIDTHisbitRVERSPDIFVersionnumber=ResetValue:RxVersion:DependsongenericsRxConfig–DescriptionTheconfigurationregistercontrolstheoperationofthereceiverBit#AccessNameDescriptionRUnusedRWBLKEN:Donotuseblockboundarymarking:MarkthefirstsampleineachblockwithainbitMODE:Storesamplesasbit:Storesamplesasbit:Storesamplesasbit:Storesamplesasbit:Storesamplesasbit:Storesamplesasbit:Storesamplesasbit:Storesamplesasbit:Storesamplesasbit:ReservedPAREN:Donotstoreparitybit:StoreparitybitinbitinsamplebufferSTATEN:Donotstorechannelstatusbit:StorechannelstatusbitinbitinsamplebufferUSEREN:Donotstoreuserdatabit:StoreuserdatabitinbitinsamplebufferRWVALEN:Donotstorevaliditybit:StorevaliditybitinbitinsamplebufferRUnusedOpenCoresSPDIFInterfacewwwopencoresorgRevofBit#AccessNameDescriptionVALID:SampledatastoredinbuffersregardlessofsubframeValiditybit:SampledatastoredonlywhensubframeValiditybitisCHAS:RxStatusregisterholdsstatusfromchannelB:RxStatusregisterholdsstatusfromchannelARINTEN:Interruptoutputisdisabled:InterruptoutputisenabledSAMPLE:Nodataisstoredinthesamplebuffer:DataisstoredinthesamplebufferRWRXEN:Receiverisdisabled:ReceiverisenabledResetValue:RxCo

用户评价(0)

关闭

新课改视野下建构高中语文教学实验成果报告(32KB)

抱歉,积分不足下载失败,请稍后再试!

提示

试读已结束,如需要继续阅读或者下载,敬请购买!

评分:

/26

意见
反馈

立即扫码关注

爱问共享资料微信公众号

返回
顶部

举报
资料