Electronic Components Datasheet Search
  New Zealand  ▼
ALLDATASHEET.CO.NZ

X  

AN1712 Datasheet(PDF) 4 Page - STMicroelectronics

Part # AN1712
Description  GENERATING A HIGH RESOLUTION SINEWAVE USING ST7 PWMART
PDF  14 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
Manufacturer  STMICROELECTRONICS [STMicroelectronics]
Direct Link  http://www.st.com
Logo STMICROELECTRONICS - STMicroelectronics

AN1712 Datasheet(HTML) 4 Page - STMicroelectronics

  AN1712 Datasheet HTML 1Page - STMicroelectronics AN1712 Datasheet HTML 2Page - STMicroelectronics AN1712 Datasheet HTML 3Page - STMicroelectronics AN1712 Datasheet HTML 4Page - STMicroelectronics AN1712 Datasheet HTML 5Page - STMicroelectronics AN1712 Datasheet HTML 6Page - STMicroelectronics AN1712 Datasheet HTML 7Page - STMicroelectronics AN1712 Datasheet HTML 8Page - STMicroelectronics AN1712 Datasheet HTML 9Page - STMicroelectronics Next Button
Zoom Inzoom in Zoom Outzoom out
 4 / 14 page
background image
4/14
GENERATING A HIGH RESOLUTION SINEWAVE USING ST7 PWMART
1.2 SINEWAVE GENERATION
At the start of the program:
– the PWMDCR0 register is initialized to obtain a 50% duty cycle
– the number of samples in a sinewave cycle is defined
– the counter reload value (ARTARR) is initialized
In the software provided with this application note, predefined initialization values for each fre-
quency can be selected in the define.h file.
More than 18 samples in a sinewave cycle should be selected to generate a sinewave with
Total Harmonic Distortion of less than 5%. So, depending on the number of samples in a sin-
ewave cycle, the duty cycle register (PWMDCR0) is modified, taking care that no 0% and
100% PWM is generated for any of the sinewave samples (because the PWM duty cycle must
be between ~99% to ~1% to generate an undistorted sinewave). The PWM duty cycle is
changed after a certain number (“COUNTER”) of overflow cycles. So, the sinewave frequency
depends on three parameters,
– the PWM frequency (fPWM)
– the number of samples in a sinewave cycle
– the number of overflow cycles after which the PWM duty cycle changes (“COUNTER”)
So, the sinewave frequency can be given by:
See also Figure 2.
This PWM signal must be filtered with an external RC network selected for the filtering level re-
quired to generate a sinusoid. The cut off frequency of low pass RC filter is given as:
So, the value of R and C must be chosen in such a way that the output sinewave frequency
should be less than this high cut off frequency (fH).
The instantaneous value of sinewave depends on the duty cycle of PWM. So:
fSINE =
1
tPWM * number of samples * COUNTER
fH =
1
2 * pi * R * C
VSINE max,min = Max, Min PWM duty cycle * VDD
VSINE average = Average PWM duty cycle * VDD



Html Pages

1 2 3 4 5 6 7 8 9 10 11 12 13 14


Datasheet Download

Go To PDF Page


Link URL



Does ALLDATASHEET help your business so far?  [ DONATE ] 

About Alldatasheet   |   Advertisement   |   Contact us   |   Privacy Policy   |   Link to Datasheet    |   Link Exchange   |   Manufacturer List
All Rights Reserved©Alldatasheet.com


Mirror Sites
English : Alldatasheet.com  |   English : Alldatasheet.net  |   Chinese : Alldatasheetcn.com  |   German : Alldatasheetde.com  |   Japanese : Alldatasheet.jp
Russian : Alldatasheetru.com  |   Korean : Alldatasheet.co.kr  |   Spanish : Alldatasheet.es  |   French : Alldatasheet.fr  |   Italian : Alldatasheetit.com
Portuguese : Alldatasheetpt.com  |   Polish : Alldatasheet.pl  |   Vietnamese : Alldatasheet.vn
Indian : Alldatasheet.in  |   Mexican : Alldatasheet.com.mx  |   British : Alldatasheet.co.uk  |   New Zealand : Alldatasheet.co.nz
Family Site : ic2ic.com  |   icmetro.com