1Lecture2:CaseStudyinElectronicSystemDesign2005SpringDuan@ele.pku.edu.cn2005SpringEE109ElectronicSystemDesign2Outline1.Review2.CaseStudy–DigitalFrequencymeterCaseStudy1:SystemRequirementAnalysisCaseStudy2:SystemDesignCaseStudy3:SubSystemDesignCaseStudy4:SoftwareDesignCaseStudy5:SystemTestCaseStudy6:Document3.DesignTips4.Summary2005SpringEE109ElectronicSystemDesign31.Review2005SpringEE109ElectronicSystemDesign41.Review:电子系统的组成2005SpringEE109ElectronicSystemDesign51.ReviewExample:一种单片机为核心的电子系统2005SpringEE109ElectronicSystemDesign61.Review:设计方法•功能要求•总体框图•子系统•单元电路•选芯片•原理图•电路仿真•PCB图•单元调试•系统调试•反复TopDownBottomUpDebugIntegrate2005SpringEE109ElectronicSystemDesign71.Review:ProcessofDesign•行为级描述与设计•结构级描述与设计•物理级描述与设计•系统级设计•子系统设计•系统集成测试2005SpringEE109ElectronicSystemDesign82.CaseStudy2005SpringEE109ElectronicSystemDesign92.CaseStudy:DigitalFrequencyMeterCaseStudy1:SystemRequirementAnalysisCaseStudy2:SystemDesignCaseStudy3:SubSystemDesignCaseStudy4:SoftwareDesignCaseStudy5:SystemTestCaseStudy6:Document2005SpringEE109ElectronicSystemDesign102.1CaseStudy1:SystemRequirementAnalysis1DigitalFrequencyMeter(Cymometer)SystemRequirement2005SpringEE109ElectronicSystemDesign112.1CaseStudy1:SystemRequirementAnalysis2RequirementAnalysisMainFunctionFrequency/Period/PulseWidth/DutyMainSpecificationDutyError=1%,othersError0.1%FrequencyRange:1Hz~10MHzAdvancedFunction:0.1Hz~10MHzPulseWidth=100usGateTime:10sRefreshDisplay:1~10sInputLevel:0.5~5VAdvanced:0.02V~5V2005SpringEE109ElectronicSystemDesign122.2CaseStudy2:SystemDesign1.MeasurePrincipleStudyDirectAlgorithmIndirectAlgorithmMulticycleSynchronizationAlgorithm2005SpringEE109ElectronicSystemDesign132.2CaseStudy2:SystemDesign2.DirectAlgorithmforFrequencyDiagramFormulaFx=N/Tx∆Fx/Fx=(1/TsFx+|∆Fc/Fc|)FxGateAMPReshape1|0GateTime1ms/10ms/0.1S/1s/10sFcRSCounterDisplayTxN2005SpringEE109ElectronicSystemDesign142.2CaseStudy2:SystemDesign3.DirectAlgorithmforPeriodDiagramFormulaTx=NT0/K∆Tx/Tx=(T0Fx/K+|∆Fc/Fc|+0.32/K*Power(10,-SNR/20)FxFcTriggerErrorGateAMPReshape1|0FreqDiv/FreqmultipleCounterDisplay/KT0K*TxNT02005SpringEE109ElectronicSystemDesign152.2CaseStudy2:SystemDesign4.IndirectAlgorithmforFreq/PeriodFrequencyÆPeriodPeriodÆFrequencyFmMiddleFrequencyErrorFigure2005SpringEE109ElectronicSystemDesign162.2CaseStudy2:SystemDesign5.MulticycleSynchronizationAlgorithmDiagramFormulaFx=Na*Fc/Nb∆Fx/Fx=∆Tx/Tx=Tc/T+|∆Fc/Fc|+0.32/K*Power(10,-SNR/20)GateAAMPReshapeDQClkClkGeneratorFcCounterANa=FxTGateBCounterBNb=FcTPresetPulseFxFxFx=Na*Fc/NbDisplaySet:Fc=10M,T=1s-Tc/T=0.1us/1s~10E-7|∆Fc/Fc|~10E-7,TriggerError~0So:∆Fx/Fx~10E-7,Excellent!2005SpringEE109ElectronicSystemDesign172.2CaseStudy2:SystemDesign6.CoreAlgorithmSelectionDivisionMiddleGoodM.SSwitch@FmDivisionMiddleEnoughIndirectNoLow×DirectSoftwareReq.ComplexErrorAlgorithm2005SpringEE109ElectronicSystemDesign182.2CaseStudy2:SystemDesign6.CoreAlgorithmDoubleCheckDoubleCheckPulseWidthDutyAdvancedRequirementOtherSpecifications…2005SpringEE109ElectronicSystemDesign192.2CaseStudy2:SystemDesign7.SystemDiagram(1)FrequencyMeter(MulticycleSynchronizationMeasureCore)LEDDisplayKey/SelectionFxbFxaHardware?Division?Software?10MHzHardware/Software?10MHz/Division2005SpringEE109ElectronicSystemDesign202.2CaseStudy2:SystemDesign7.SystemDiagram(2)MulticycleSynchronizationMeasureCoreLEDDisplayKey/SelectionFxbFxaMCUChannelAChannelBPowerInputChannelAnalogSubsystemMeasureCoreDigitalSubsystemControllerMCUSubsystemPrincipleStudyAlgorithmSelectionSystemDiagramSubsystemPartition2005SpringEE109ElectronicSystemDesign212.3CaseStudy3:SubSystemDesign(1)AnalogSubsystemInputChannel2005SpringEE109ElectronicSystemDesign222.3CaseStudy3:SubSystemDesign(1)1.InputChannelRequirementTypeAnalogSubsystemRequirementFunctionConvertAnalogSignaltoDigitalSignalSpecificationInputsignalLevel:0.5V~5V,Advanced:0.02V~5VAdvanced:0.02V~5VFreq:0.1Hz~10MHz,OutputsignalLevel:TTLFreq:0.1Hz~10MHzAmplifierReshapeFxTTL2005SpringEE109ElectronicSystemDesign232.3CaseStudy3:SubSystemDesign(1)2.InputChannelDiagramAmplifierReshapeTTLFxInputBufferInputProtectionHighimpedanceSensitivityAdjustTriggerLevelAdjustAdvancedLevel0.02VOutBufferPos+/Neg-PulseEdge2005SpringEE109ElectronicSystemDesign242.3CaseStudy3:SubSystemDesign(1)3.InputChannel:Amplifier+ReshapeReshape@0.02VinputTTL:TriggerLevel=2VGain=2V/0.02V=100ComparatorMAX902,SR=0.5V/sSR=2*Pi*Fx*UmÆUm=0.8V@Fx=0.1HzGain=0.8v/(0.02V*1.414)=30ChooseGain=40@0.02inputReshape=Comparator402005SpringEE109ElectronicSystemDesign252.3CaseStudy3:SubSystemDesign(1)4.InputChannel:AmplifierDoubleCheckAmplifier@5VUm=40*5v*1.414=280V@0.5VUm=40*0.5*1.414=28V@0.02VUm=40*0.02*1.414=1.2V4/40GBW:GAIN*BWGBW:GAIN*BW4*10M=40M40*10M=400MTooLarge!Max4016+Max4016GBW=150MGBW=GAIN*BWGBW=GAIN*BWA1:1*10M=10M10*10M=100MA24*10M=40MA11/10A24GainSwitch@0.5V~5VGain=4Um=2.8V~28V@0.02V~0.5VSetGain=40Um=1.2V~28V2005SpringEE109ElectronicSystemDesign262.3CaseStudy3:SubSystemDesign(1)5.AnalogSubsystemDesignMa