<?xml version="1.0" encoding="UTF-8"?>        <rss version="2.0"
             xmlns:atom="http://www.w3.org/2005/Atom"
             xmlns:dc="http://purl.org/dc/elements/1.1/"
             xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
             xmlns:admin="http://webns.net/mvcb/"
             xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
             xmlns:content="http://purl.org/rss/1.0/modules/content/">
        <channel>
            <title>
									python Cron jobs - Python				            </title>
            <link>https://forum.dronebotworkshop.com/python/python-cron-jobs/</link>
            <description>Discussion board for Robotics, Arduino, Raspberry Pi and other DIY electronics and modules. Join us today!</description>
            <language>en-US</language>
            <lastBuildDate>Wed, 12 Aug 2026 15:19:11 +0000</lastBuildDate>
            <generator>wpForo</generator>
            <ttl>60</ttl>
							                    <item>
                        <title>python Cron jobs</title>
                        <link>https://forum.dronebotworkshop.com/python/python-cron-jobs/#post-42307</link>
                        <pubDate>Sat, 26 Aug 2023 07:28:25 +0000</pubDate>
                        <description><![CDATA[this is just one example of cron job classes in the livingrimoire auxiliary modules
class TrgEveryNMinutes(TrGEV3):
    # trigger returns true every minutes interval, post start time
    ...]]></description>
                        <content:encoded><![CDATA[<p>this is just one example of cron job classes in the livingrimoire auxiliary modules</p>
<pre contenteditable="false">class TrgEveryNMinutes(TrGEV3):
    # trigger returns true every minutes interval, post start time
    def __init__(self, startTime: str, minutes: int):
        self._playGround: PlayGround = PlayGround()
        self._minutes:int = minutes  # minute interval between triggerings
        self._timeStamp = startTime
        self._trgTime: TrgTime = TrgTime()
        self._trgTime.setTime(startTime)

    def setMinutes(self, minutes: int):
        if minutes &gt; -1:
            self._minutes = minutes

    # override
    def trigger(self) -&gt; bool:
        if self._trgTime.alarm():
            self._timeStamp = self._playGround.getFutureInXMin(self._minutes)
            self._trgTime.setTime(self._timeStamp)
            return True
        return False

    # override
    def reset(self):
        self._timeStamp = self._playGround.getCurrentTimeStamp()</pre>
<p>main advantage is it works cross platforms, and no need to run a pip install.</p>
<p>example use would be like in gatebox where the AI anticipates the user and checks up on him (see more advanced Cron class)</p>
<p> </p>
<p>https://www.youtube.com/watch?v=nkcKaNqfykg</p>]]></content:encoded>
						                            <category domain="https://forum.dronebotworkshop.com/python/">Python</category>                        <dc:creator>mr.meeseeks</dc:creator>
                        <guid isPermaLink="true">https://forum.dronebotworkshop.com/python/python-cron-jobs/#post-42307</guid>
                    </item>
							        </channel>
        </rss>
		