Generating SPWM using arduino-simulink environment

  • #1
54
2
hi all......am trying to generate sinusoidal pulse width modulation using arduino-simulink for my inverter board....I simulated the SPWM logic in simulink, then installed the required support package for arduino-simulink.....but i am facing some problems......I started from basic...like linking arduino and PWM block as shown below


https://www.physicsforums.com/file:///C:\Users\ccbzak\AppData\Local\Temp\msohtmlclip1\01\clip_image001.png [Broken]


I checked the output of Arduino pin11 from CRO and it was working fine….

Now I used this blocks to generate spwm…

https://www.physicsforums.com/file:///C:\Users\ccbzak\AppData\Local\Temp\msohtmlclip1\01\clip_image002.png [Broken]

When I checked the output from CRO…..it was distorted…literally I didn’t get any SPWM wave…

Help me out with problem…

My Simulink configurations are

Solver: fixed step size

Step size:1e-5

Triangle wave frequency is 8KHz and sine wave is 50Hz…
 
Last edited by a moderator:

Answers and Replies

  • #2
54
2
ard_1.png

ard_2.png
 

Related Threads on Generating SPWM using arduino-simulink environment

  • Last Post
Replies
6
Views
623
  • Last Post
Replies
5
Views
6K
  • Last Post
Replies
1
Views
5K
  • Last Post
Replies
1
Views
1K
Replies
2
Views
1K
Replies
1
Views
6K
Replies
1
Views
2K
  • Last Post
Replies
1
Views
1K
  • Last Post
Replies
1
Views
5K
  • Last Post
Replies
1
Views
1K
Top