<?xml version="1.0" encoding="utf-8"?>
<feed xml:lang="en" xmlns="http://www.w3.org/2005/Atom"><title>Recent posts to Codesys - Cycle Time and Jitter</title><link href="https://forge.codesys.com/forge/talk/Engineering/thread/d9ca4f6f53/" rel="alternate"/><link href="https://forge.codesys.com/forge/talk/Engineering/thread/d9ca4f6f53/feed.atom" rel="self"/><id>https://forge.codesys.com/forge/talk/Engineering/thread/d9ca4f6f53/</id><updated>2021-03-18T14:37:24.820000Z</updated><subtitle>Recent posts to Codesys - Cycle Time and Jitter</subtitle><entry><title>Codesys - Cycle Time and Jitter</title><link href="https://forge.codesys.com/forge/talk/Engineering/thread/d9ca4f6f53/?limit=25#ddc7" rel="alternate"/><published>2021-03-18T14:37:24.820000Z</published><updated>2021-03-18T14:37:24.820000Z</updated><author><name>pkennedy</name><uri>https://forge.codesys.com/u/pkennedy/</uri></author><id>https://forge.codesys.com622c897b7fa4581a5ef91d1a050f4671b55bab48</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Okay, I'll have a look and see, thanks.&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>Codesys - Cycle Time and Jitter</title><link href="https://forge.codesys.com/forge/talk/Engineering/thread/d9ca4f6f53/?limit=250#9db7" rel="alternate"/><published>2021-03-17T07:42:34.246000Z</published><updated>2021-03-17T07:42:34.246000Z</updated><author><name>aliazzz</name><uri>https://forge.codesys.com/u/aliazzz/</uri></author><id>https://forge.codesys.comf07dcac035030c594e5c4adf72979b0ef5a71852</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;If you really need to know what the root cause is without too much hassle, you should give the CODESYS professional developper Edition Profiler a try.&lt;br/&gt;
It's very suited for identifying the root cause of your timing issue's!&lt;/p&gt;
&lt;p&gt;You can always run a month demo for free ;-)&lt;/p&gt;&lt;/div&gt;</summary></entry><entry><title>Codesys - Cycle Time and Jitter</title><link href="https://forge.codesys.com/forge/talk/Engineering/thread/d9ca4f6f53/?limit=25#1294" rel="alternate"/><published>2021-03-16T15:40:37.456000Z</published><updated>2021-03-16T15:40:37.456000Z</updated><author><name>pkennedy</name><uri>https://forge.codesys.com/u/pkennedy/</uri></author><id>https://forge.codesys.comc09f5a9a355ad387acdc16d767f394bcc69cbed2</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;I have an issue with on of my programs, the cycle time seems to be extremely long. &lt;/p&gt;
&lt;p&gt;Based on the task configuration:&lt;/p&gt;
&lt;p&gt;Last Cycle Time (us) = 680000 - 720000&lt;br/&gt;
Average Cycle Time (us) = 117920 - but constantly climbs the longer the program runs&lt;br/&gt;
Max Cycle Time (us) = 807659&lt;/p&gt;
&lt;p&gt;Jitter (us) = 806802&lt;/p&gt;
&lt;p&gt;I ran the PLC load average in the PLC Shell command and it's only showing 49%. &lt;/p&gt;
&lt;p&gt;I set up timers and noted one PRG was taking quite a bit more time:&lt;/p&gt;
&lt;p&gt;Task    End Time    PRG Start Time  Difference&lt;br/&gt;
Time 1  5168987211  5168987174      37&lt;br/&gt;
Time 2  5168987212  5168987174      38&lt;br/&gt;
Time 3  5168987218  5168987174      44&lt;br/&gt;
Time 4  5168987267  5168987174      93&lt;br/&gt;
Time 5  5168987275  5168987174      101&lt;br/&gt;
Time 6  5169607023  5168987174      619849&lt;br/&gt;
Time 7  5168986684  5168987174      -490&lt;/p&gt;
&lt;p&gt;I comment out that PRG in the code and the times drop drastically:&lt;/p&gt;
&lt;p&gt;Last Cycle Time (us) = 78000 - 82000&lt;br/&gt;
Average Cycle Time (us) = 17000 - but constantly climbs the longer the program runs&lt;br/&gt;
Max Cycle Time (us) = 156104&lt;/p&gt;
&lt;p&gt;Jitter (us) = 155213&lt;/p&gt;
&lt;p&gt;However my PLC load actually increased to 69%.&lt;/p&gt;
&lt;p&gt;The program is taking data points and writing them to a file on a USB, using the CAA File (3.5.12.0) library. Is there a chance it's taking so long because of writing to the USB directly? Should I look to save directly to the HMI/PLC and then transfer to the USB after saving all the required data? &lt;/p&gt;&lt;/div&gt;</summary></entry></feed>