Hello Sir,
I want to generate the SPWM and simple PWM to GPIOs ... SPWM of fundamental frequency 50Hz and Switching frequency 5kHz .....but when we build and run the program i am getting the switching frequency is of around 63Hz and fundamental frequency 2Hz ....simple PWM is of least frequency...
Ts = 2e-6 and Fixed step size is of 2e-6 (in solver) and MIPS 20e6 (in master).....even the fixed step size (in solver) is every time is resetting to 0.01..... I am attaching the simulation file...can you check and please tell me how to get the my required pwm frequency and spwm....even i tried with rate transition box but no use...
Error in SPWM Motor PWM Output
-
- Posts: 3
- Joined: Tue Mar 27, 2012 7:34 pm
Error in SPWM Motor PWM Output
- Attachments
-
- PWM.mdl
- SPWM Motor PWM Output
- (30.23 KiB) Downloaded 1523 times
-
- Site Admin - Expert
- Posts: 616
- Joined: Wed Mar 07, 2007 11:23 pm
- Location: Bayonne- France
- Contact:
Re: Error in SPWM Motor PWM Output
Hello,
You will not generate a PWM efficiently using digital output blocks.
Use the PWM like block, or Output Compare block.
You might find some examples on the website or within blockset example folder.
Lubin
You will not generate a PWM efficiently using digital output blocks.
Use the PWM like block, or Output Compare block.
You might find some examples on the website or within blockset example folder.
Lubin
Re: Error in SPWM Motor PWM Output
Thanks LubinKerhuel for giving the correction & new idea...



pass4sure www.pass4sure.com
LX0-102 http://www.pass4sure.com/LX0-102.html
642-642 http://www.pass4sure.com/642-642.html
642-427 http://www.pass4sure.com/642-427.html
LX0-102 http://www.pass4sure.com/LX0-102.html
642-642 http://www.pass4sure.com/642-642.html
642-427 http://www.pass4sure.com/642-427.html
Re: Error in SPWM Motor PWM Output
Thanks for making me understand about the exact issue. I was not aware about not to generate a PWM efficiently using digital output blocks. I usually use the PWM for the output blocks. Now on wards I will make use of the Output Compare block.
--------------------------------
Ellery
Windows online support now
--------------------------------
Ellery
Windows online support now
Who is online
Users browsing this forum: No registered users and 17 guests