Page 1 of 1

How to do Pwm off and on in flowcode??

Posted: Wed Dec 15, 2021 2:40 pm
by kg300
This is c code
// Send 9ms burst
pwm_on();
delay_ms(9);
// Send 4.5ms space
pwm_off();
delay_us(4500);

How can i do this in flowcode?. Desiable pwm component madule for 9ms and enable it again or there is another way??

Re: How to do Pwm off and on in flowcode??

Posted: Wed Dec 15, 2021 3:54 pm
by medelec35
You can set the duty to 0 for PWM off.
No need to disable then:
PWM Burst.png
PWM Burst.png (45.39 KiB) Viewed 8094 times

Re: How to do Pwm off and on in flowcode??

Posted: Wed Dec 15, 2021 5:30 pm
by kg300
medelec35 wrote:
Wed Dec 15, 2021 3:54 pm
You can set the duty to 0 for PWM off.
No need to disable then:
PWM Burst.png
Thanks :D

Re: How to do Pwm off and on in flowcode??

Posted: Thu Dec 16, 2021 12:50 pm
by medelec35
You're welcome.
It has been found that with some devices that PWM duty does not completely go to 0.
If that is the same as your target device, then Disable and Enable will be required.
Hopefully, that is not the case, but I thought I would make you aware of a possibility.

Re: How to do Pwm off and on in flowcode??

Posted: Wed Jan 05, 2022 11:46 pm
by electron67
Hello, Martin

I know it has nothing with the question; I have been in the Matrix forum (Flowcode 3) since 2008, I was taking a look at the topics, I see that Martin (Medelec) is now part of the Matrix Staff, I CONGRATULATE You !!!
You are one of the people who is contributing with your knowledge to many of us in the forum, EXCELLENT :D
I'm glad to see that you belong to the staff de Matrix 8)

That we all have a good year 2022 ( My English is good :?: )

Enrique

Re: How to do Pwm off and on in flowcode??

Posted: Thu Jan 06, 2022 11:34 am
by medelec35
Hi Enrique.
Happy new year & thank you.
It's really nice what you said, I appreciate it. :D
electron67 wrote:
Wed Jan 05, 2022 11:46 pm
My English is good
Very good, well done. :)

Re: How to do Pwm off and on in flowcode??

Posted: Wed Jan 19, 2022 9:16 pm
by siliconchip
hi
i would also like to mention i too noticed martin (medelec)is matrix staff and over the years martin has helped and guided me as i tried and still do get to grips with flowcode programming and microcontrollers, matrix should be immensely proud of your contributions and about time your officially part of their team im sure you will be a great asset thank you martin (medelec)

bob

Re: How to do Pwm off and on in flowcode??

Posted: Thu Jan 20, 2022 10:15 am
by Steve
Some great comments in this thread about @medelec35! We're very happy and feel fortunate to have Martin as part of our team here at Matrix.

But thanks and recognition also to our VCs and wider community of users who continue to provide help and support on our forums.

Re: How to do Pwm off and on in flowcode??

Posted: Thu Jan 20, 2022 1:57 pm
by medelec35
Thank you, Bob for the lovely comments.
I really appreciate them.
I do try and help as much as I can

Thank you, Steve, that means a lot to me as well do all the lovely comments been made.
You are right, of course, but also a must to be included are the rest of matrix staff.
Without them, Flowcode would not be a wonderful product as it is.

Re: How to do Pwm off and on in flowcode??

Posted: Thu Jan 20, 2022 8:08 pm
by siliconchip
Hi
Couldnt agree more thanks everyone at matrix for a brilliant product and thanks to other users who help people like myself when we are banging our heads on a brick wall apologies for not adding this in my previous comments

Bob