<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Recent posts by zhw618</title><link>https://forge.codesys.com/u/zhw618/</link><description>Recent posts by zhw618</description><language>en</language><lastBuildDate>Fri, 22 Jul 2022 12:17:21 -0000</lastBuildDate><atom:link href="https://forge.codesys.com/u/zhw618/profile/feed.rss" rel="self" type="application/rss+xml"></atom:link><item><title>GPIOMods: more than one SoftPWM function block in one project</title><link>https://forge.codesys.com/forge/talk/forge/thread/6ceff9d39e/?limit=25#0a86</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;I meet the same problems. One project parallel for 2 GPIO pins, and that is NOT working properly.&lt;br/&gt;
I use Raspberry PI 4B+, and Codesys v3.5.18.2&lt;/p&gt;
&lt;p&gt;After hard work, I found the solution to overcome this problem:&lt;br/&gt;
1) MUST put every SoftPWM function block in a SEPARATE IEC-task with high priority (priority 0 or 1)&lt;br/&gt;
2) MUST set every Iec-task's  cyclic interval small enough! for example, 50us.&lt;/p&gt;
&lt;p&gt;I found if the interval greater than you need frequency, the PWM signal on the GPIO pin is not as it should be. And all the SoftPWM function blocks cannot be in one task, because then they will all have the same frequency.&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">zhw618</dc:creator><pubDate>Fri, 22 Jul 2022 12:17:21 -0000</pubDate><guid isPermaLink="false">https://forge.codesys.comfdfcabf1c566ed1f3c112c30dc87b2b11e83a30b</guid></item></channel></rss>