MATLAB Answers

F28M35 Simulink ePWM block

9 views (last 30 days)
TZU-I  Huang
TZU-I Huang on 28 Aug 2018
Commented: TZU-I Huang on 3 Sep 2018
Hi all
I am new to this device and blocks associated with it and I have read the block description page. I am trying to do some ADC in and PWM outs. But for all the examples the ePWM blocks are orange and with an input port of "WA", however if I drag the exactly same block from the library the block will not have any input port even if all the settings are the same. I believe the input is to drive the ePWM clock.
Please help me, the image is attached below.
Thanks.

  0 Comments

Sign in to comment.

Answers (1)

Vineeth Nair
Vineeth Nair on 31 Aug 2018
To get the "WA" input port  , open block parameters ->Under counter compare tab-> set the "Specify CMPA via" parameter to - Input port. Note that, this is not the port to drive ePWM clock. To know more about the ePWM block, its timer properties etc. you can go to this link .

  3 Comments

TZU-I  Huang
TZU-I Huang on 31 Aug 2018
Hi Vineeth
Thank you. I have figured that out few days after I posted this question. I have now come to some other questions.
1. For ADC block, is it right that we can not change the priority of ADCs by just using inbuilt function block and all ADCs will have "Round Robin Priority" while F28m3x device have the option to set in "high priority mode"?
2. Do you have any idea of how to set general purpose timers on both M3 and C28x cores? As I can see that there are function blocks for handling hardware interrupt for both cores include timer interrupts but I did not see any blocks for the initial and set the timer frequency.
Thanks, Andrew
Vineeth Nair
Vineeth Nair on 3 Sep 2018
1. Priority of ADC's can be changed. In Configuration parameters-> Hardware implementation -> Select required Hardware board. Under Target hardware resources->There are settings for ADC, where priority can be set to high priority. By default it's in round robin mode.
2.Here you can also see settings for clocking. The clock frequency can be changed here. Attaching screenshot of these settings tabs.
TZU-I  Huang
TZU-I Huang on 3 Sep 2018
Thanks for the ADC part, I wasn't awarded of that. I will make my second question more clear, below is a screenshot of F28M35, I underlined tow sections, 4 general purpose timers for M3 core and 3 32-bit timers for C28 core. Is there any way to set up those timers for periodic interrupts?
Thanks

Sign in to comment.

Tags

Products


Release

R2016b

Translated by