Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

How to Generate exact number of pulse using stm32

Status
Not open for further replies.

arsalanarm

Junior Member level 3
Joined
Sep 1, 2012
Messages
30
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Activity points
1,676
hi guys
i am using stm32f429 In my application I need to provide clock input to a AC Servo Drive.
i must generate a pulse and control frequency and number of pulse. i am going to control frequency from 1Hz to 200KHz (with 1Hz Resulotion) and control number of Pulse between 1 Pulse to 4294967296 Pulse (a 32 bit variable).
i use timer 1 in pwm mode and one pulse mode using repetetion counter but repetetion counter is only 8 bit and i need 32bit control register to control number of generated pulse.
please help.
best regards
 

Hi,

Why not using a hardware pin as clock input for a hardware counter?.

On compare match raise an interrupt to stop the PWM.

Klaus
 

Hi
thanks for answer
Can you explain more?
How can i control frequency and number of pulse?
 

Hi,

Apparently you did not read datasheet, application notes, design examples. Even video tutorials are available for
* frequency setup for PWM
* pulse counting with hardware timer/counter periferal.

Do this first.

The use code from the examples and modify them for your needs or writethe code on your own.
Test it
And if it does not work, then
* give a link to the document(s)
* show your code, maybe schematic, too
* explain what you expect
* explain what does not work as expected

Klaus
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top