Hello All,
I know that I can generate a maximum of 12 PWM signals using ePWM predefined function. Can I generate a PWM signals using other pins. If so how can I do it? I would be grateful If someone posts the code with reply.
Thank you
Manideep
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Hello All,
I know that I can generate a maximum of 12 PWM signals using ePWM predefined function. Can I generate a PWM signals using other pins. If so how can I do it? I would be grateful If someone posts the code with reply.
Thank you
Manideep
Manideep,
The F28335 can output up to 18 PWM outputs.
There are 6 PWM modules on the F28335. Each module allows two PWM outputs. So, the PWM modules can generate 12 PWM outputs total.
Each of the 6 eCAP modules on the F28335 can also be configured to output a PWM waveform. To figure out how to generate a PWM with the eCAP peripheral, I would recommend looking at the following example in controlSUITE:
C:\TI\controlSUITE\device_support\f2833x\v132\DSP2833x_examples_ccsv4\ecap_apwm\
Thank you,
Brett
Hey Brett Larimore,
I couldn't find any example in the link you gave me.Can you please check once again.
Manideep,
You'll need to download controlSUITE to have access to these examples:
http://www.ti.com/controlsuite
Thank you,
Brett
Hi Rosmadi,
As described above, the F28335 can generate 12 PWMs from its six ePWM modules and 6 from the eCAP modules for a total of 18.
To generate more than 18 PWMs on the F28335, you'll need to generate the extra PWMs via software. (perhaps toggling GPIOs that are configured as outputs. Because they would be generated like this, these PWMs would not be able to run at high speed because it would eat into your available CPU bandwidth for control/communication stacks/etc.
The F28M36x series of C2000 Concerto MCUs has twelve ePWM modules and can therefore generate 24 PWM outputs directly. This may be of interest to you if bandwidth is a concern.
Thank you,
Brett
Thank you Brett for your response..
I have done the first method proposed by you by toggling the GPIO and you are correct. Pwm generated using GPIO suffer delay. I'm trying to reduce the coding hopefully it will help. If not successful in two weeks I need to buy the F28M36X..
Thank you,
Rosmadi
Rosmadi,
The following link may be useful:
http://processors.wiki.ti.com/index.php/General_Purpose_IO_%28GPIO%29_FAQ_for_C2000#Q:_How_can_I_toggle_a_GPIO_pin_as_fast_as_possible_in_C.3F
Thank you,
Brett