Sign in

Not a member? | Forgot your Password?

Search motoroladsp

Search tips

Subscribe to motoroladsp

Search tips

Free PDF Downloads

A Quadrature Signals Tutorial: Complex, But Not Complicated

Understanding the 'Phasing Method' of Single Sideband Demodulation

Complex Digital Signal Processing in Telecommunications

Introduction to Sound Processing

C++ Tutorial

Introduction of C Programming for DSP Applications

Fixed-Point Arithmetic: An Introduction

Cascaded Integrator-Comb (CIC) Filter Introduction

Discussion Groups

FIR Filter Design Software

See Also

Embedded SystemsFPGA

Discussion Groups | Freescale DSPs | Calculation for PWM using 827

Technical discussions about Freescale (Motorola) DSPs (including the DSP56000, DSP56300, DSP56600, 56800 DSPs).

  

Post a new Thread



Is this thread worth a thumbs up?

0

Calculation for PWM using 827 - Nitin Madhukar Yewale - Sep 9 3:13:00 2002

Hi,
I am using 827 processor for my application. Core freq is 80Mhz
so peripheral freq is 40Mhz.
I want to generate PWM (under variable freq PWM mode) of 10 Hz frq and
1.5 mili seconds [Pulse width].

Here are the calculation for the same.
If I use prescaler of 64 then :
40Mhz/64 = 625000 Hz i.e. 0.0000016 seconds for 1 cnt.
Now If I want to generate freq of 10 hz ie. 1/10 = 0.1 seconds then
value which I suppose to load in CMP1 register is
.1/0.0000016 = 62500 ie. 0xf424.

Please correct if I am wrong.

Could anyone tell me calculation about pulse width which I suppose to
load in CMP2 register? Or I will have to load same number. Is there any
other way to get the respective number to get desired pulse width?

Thanks and Regards,
Nitin Yewale.



**************************Disclaimer**************************************** ****\
******

Information contained in this E-MAIL being proprietary to Wipro Limited is
'privileged'
and 'confidential' and intended for use only by the individual or entity to
which it is
addressed. You are notified that any use, copying or dissemination of the
information
contained in the E-MAIL in any manner whatsoever is strictly prohibited.

******************************************************************************** \
********







RE: Calculation for PWM using 827 - Art Johnson - Sep 9 13:36:00 2002

The PWM prescaler only allows you to divide the IPbus by 1, 2, 4, or 8
using the PRSC0 and PRSC1 bits in the PWM Control Register (PWMCTL).
Also, the PWM Counter Modulo Register (PWMCM) is only 15 bits long, with
a maximum value of 32767. So, the lowest frequency is 40MHz / (8 *
32767), or about 152.6Hz. I would suggest using one of the on-chip
Timers for this purpose, as they have a PWM capability (see
"Fixed-Frequency PWM Mode" in the User's Manual), their prescaler is up
to fIPbus/128, and they are full 16-bit counters (ie a modulo of 65536).

Regards,

Art Johnson
Senior Systems Analyst
PMC Prime Mover Controls Inc.
3600 Gilmore Way
Burnaby, B.C., Canada
V5G 4R8
Phone: 604 433-4644
FAX: 604 433-5570
Email:
http://www.pmc-controls.com
-----Original Message-----
From: Nitin Madhukar Yewale [mailto:]
Sent: Sunday, September 08, 2002 8:14 PM
To: Motoroladsp
Subject: [motoroladsp] Calculation for PWM using 827 Hi,
I am using 827 processor for my application. Core freq is 80Mhz
so peripheral freq is 40Mhz.
I want to generate PWM (under variable freq PWM mode) of 10 Hz frq and
1.5 mili seconds [Pulse width].

Here are the calculation for the same.
If I use prescaler of 64 then :
40Mhz/64 = 625000 Hz i.e. 0.0000016 seconds for 1 cnt.
Now If I want to generate freq of 10 hz ie. 1/10 = 0.1 seconds then
value which I suppose to load in CMP1 register is
.1/0.0000016 = 62500 ie. 0xf424.

Please correct if I am wrong.

Could anyone tell me calculation about pulse width which I suppose to
load in CMP2 register? Or I will have to load same number. Is there any
other way to get the respective number to get desired pulse width?

Thanks and Regards,
Nitin Yewale.
_____________________________________
/groups.php3