Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask Mechanical Engineering Expert

The objective of this problem is to design a DAS alarm. An alarm should sound when noise is present in the room. Assume the output of the microphone, x(t), is a ±10 mV differential signal. The signals of interest are 100 to 500 Hz. You will sample the sound and calculate the sound energy once a second (sum of the signal squared). Be careful to subtract off the DC so that a quiet room (microphone = 0) results in an energy calculation of zero. If data are the 8-bit ADC, then x(n) = data - 128 represent the current 8-bit signed sample. If you sample at 1000 Hz, sound the alarm if (x(0) + x(1)+ . . . + x (999)) greater than 100,000. 32-bit-long integer operations are allowed. The 9S12 system has an 8-MHz E clock. The alarm can be activated by driving 20 mA through a 5-V EM relay. The software should turn on the alarm if the energy level is above a threshold (simply pick any constant). Once on, the alarm should continue until the operator types the code "213" on the keypad. This 9S12 will have a secret code of 213, but allow each 9S12 to have a different three-number code and a different threshold. The computer is dedicated to this task.

a) Show the analog interface between the differential microphone output and the 9S12 ADC channel 2. Choose the appropriate op amp circuit, gain, offset, and analog filter. The Analog Devices AD680 is a three-wire, low-cost, 2.5 V reference (+5 V input, ground +2.500 V output). This is a qualitative, and not a quantitative, DAS.

Design the interface between the 9S12 signal B0 and the EM relay (Figure 12.62). To activate the alarm, the relay coil requires a voltage between +3.5 and 6.0 V and a current of 20 mA.

Figure 12.62

1698_943e3fdd-d867-449b-a0d3-bcd2e312ef40.png

c) Show the interface between the keypad and the 9S12 (Figure 12.63). Each switch will bounce for about 10 ms, so you must implement a way to debounce. No other 9S12 connections may be used for this interface (although you may use the internal features of input capture/output compare). Your solution should minimize cost. Periodic polling should be used for this keypad because it is cheaper.

Figure 12.63

641_564dc71e-642c-4404-87eb-9ebad40ddeaf.png

d) Include all of the software that will exist in the system. Your solution will be segmented into three parts: RAM, EEPROM, and ROM. Specific software requirements include the following:

Other than a one-time initialization, there will be no foreground (main) program

Use the ADC continuous scan mode to simplify the software

Clearly show where the 9S12 is to begin execution on a power on reset

d1) Show the software that goes in the RAM (uninitialized on power up).

d2) Show the software that goes in the EEPROM (nonvolatile, but can be different for each device).

d3) Show the initialization (ritual) software that goes in the ROM (nonvolatile, and must be the same for each device). This is where your system starts executing. Assume the two interrupt vectors are set by the compiler.

d4) Show the 1 kHz DAS interrupt handler that goes in the ROM (nonvolatile, and must be the same for each device). It is here that you will turn on the alarm if the sound energy goes above threshold.

d5) Show the keypad periodic polling interrupt handler that goes in the ROM (nonvolatile, and must be the same for each device). It is here that you will turn off the alarm if the operator types in the secret code.

Mechanical Engineering, Engineering

  • Category:- Mechanical Engineering
  • Reference No.:- M91827929

Have any Question?


Related Questions in Mechanical Engineering

Question - truss structureconsider the three membered

Question - Truss Structure Consider the three membered planar truss structure shown in the figure below. All members of the truss have identical square cross-sectional area (A) of 25 mm x 25 mm, and Youngs Modulus (E) = ...

5star questions amp answers1a define heat treatment bname

5 STAR QUESTIONS & Answers 1. A) Define Heat treatment B) Name different types of heat treatment processes C) Write any 4 purposes of Heat treatment 2. Explain various Heat treatment processes 3. A) Compare Thermo plasti ...

Problem -a long pipe od 1413 mm id 1318 mm kp 20 wmk

Problem - A long pipe (OD = 141.3 mm, ID =131.8 mm, k p = 20 W/m.K) supplies hot pressurized liquid water at 400 K to a heater in a factory. The pipe has an insulation thickness of 100 mm. A new efficient heater replaces ...

Questions -q1 a qualitative estimate of the effect of a

Questions - Q1. A qualitative estimate of the effect of a wind-tunnel contraction (Figure) on turbulent motion can be obtained by assuming that the angular momentum of eddies does not change through the contraction. Let ...

Life cycle assessmentfor your chosen service eg white board

LIFE CYCLE ASSESSMENT For your chosen service (e.g. white board markers), identify two alternatives of getting the service (e.g. brand A, brand B). Choose the most environmentally friendly option by conducting life cycle ...

The aim of the project is to demonstrate certain aspects of

The aim of the project is to demonstrate certain aspects of engineering materials in different applications. The projects will be assessed on the basis of a written Research Report. The report should clearly show what yo ...

Assignment - machine learning for signal processingproblem

Assignment - Machine Learning for Signal Processing Problem 1: Instantaneous Source Separation 1. As you might have noticed from my long hair, I've got a rock spirit. However, for this homework I dabbled to compose a pie ...

Problem on shaft -assuming no frictional losses a torque of

Problem on Shaft - Assuming no frictional losses, a torque of T = 750lb·in is applied through the shaft of gear F in order to drive the roller chain at point B at a constant speed. The chain sprocket has a pitch diameter ...

Life cycle assessmentfor your chosen service eg white

LIFE CYCLE ASSESSMENT For your chosen service (e.g. white board markers), identify two alternatives of getting the service (e.g. brand A, brand B). Choose the most environmentally friendly option by conducting life cycle ...

Heat transfer and combustionyou will need graph paper a

HEAT TRANSFER AND COMBUSTION You will need graph paper, a calculator, a copy of Appendix 1 from lesson HTC - 4 - 2 and access to steam tables to answer this TMA. 1. A fuel gas consists of 75% butane (C 4 H 10 ), 10% prop ...

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As