검색어 입력폼

8051 microcontroller를 이용한 sine wave generator

저작시기 2009.10 |등록일 2009.12.24 파일확장자압축파일 (zip) | 7페이지 | 가격 7,000원

소개글

8051 microcontroller와 COMPACT51 보드를 이용하여
sine wave generator를 만드는 실험입니다. (싸인파형을 만들어냅니다.)
DAC를 통해 CPU에서 생성한 값을 pin을 통해 내보내는 형태입니다.

embedded board는 주어진 환경이 제한되어 있기 때문에,
최적화가 필요합니다. 그에 초점을 맞추어, 싸인파가 일그러지지 않도록,
가장 최선의 방법을 찾아가는 과정이 들어있습니다.

프로그램은 C언어로 제작하였습니다.
따라서 다른 board에서도 충분히 활용 가능하며,
PC에서도 작동합니다. (약간의 수정만 하면 가능)

리포트 내용은 영어로 되어 있지만,
한국인 대학생이 작성하여 어려운 내용이 없습니다. (해석하기 어렵지 않을 것으로 보입니다.)

소스코드는 문서파일에 들어 있습니다.

최종적으로 A+ 받은 자료입니다.

목차

(1) Investigate the use of D/A converter. (Reference: DAC0804 manual)
(2) Investigate the use of timer in mode 2. (Reference: 8051 User’s Manual)
(3) Write a pseudo-code that generates 50Hz and 100Hz sine waveforms when the number of samples
in a sine waveform period is fixed at 100.
(4) Write a pseudo-code that generates 50Hz and 100Hz sine waveforms when the time interval of
writing value to D/A converter is fixed at 0.1ms.
(5) In this experiment, you have to show both methods of generating sine waveforms: fixing the
number of samples in a period and fixing the time interval of writing values to D/A converter. Among
these two methods, explain which method is faster and why.

1) When you generated a sine waveform, was the frequency of output signal satisfied?
2) Was there any significant distortion or vibration on the output signal?
3) Was the number of samples in a period matched to designed value?
4) Was there any error? If yes, state the reasons.
5) What was the maximum frequency of waveform? How did you find out?

본문내용

(1) Investigate the use of D/A converter. (Reference: DAC0804 manual)
DAC0800 is the high-speed current-output digital-to-analog converter (DAC). DAC0800 has the following specification.

▷ Fast setting output current: 100ns
▷ Full scale error: ±1 LSB
▷ Nonlinearity over temperature: ± 0.1%
▷ Full scale current drift: ± 10 ppm/°C
▷ High output compliance: -10V to +18V
▷ Complementary current outputs
▷ Interface directly with TTL, CMOS, PMOS and others
▷ 2 quadrant wide range multiplying capability
▷ Wide power supply range: ± 4.5V to ±18V
▷ Low power consumption: 33mW at ±5V
▷ Low cost

One of the important factors is fast setting output current. 100ns means the elapsing time to make and stabilize the output when the digital input is injected. As the speed of CPUs becomes faster and faster, the peripheral devices or components are required to




Reversely, let us consider the case when we apply the method to the low frequency sine wave. For the fixed sampling number, the accuracy would be low in the sense of the exact value. The result would have the rough form of the sine wave, but the connection would be the straight line rather than the curve. However, in the graphical point of view, we can see the rough sine wave, and in the very low frequency, the curve can be looked like straight line for the short angle distance. So, the result is somehow acceptable. For the fixed time interval, the accuracy would be rather guaranteed comparing to the fixed sampling number case with the proper time interval. However, it would do sampling too much. If the processor deals only this sine wave sampling (or generation), it does not cause any problem, but the real situation is normally not.
Therefore, the discussion has to be done
다운로드 맨위로