But we are still talking about a Multi-Tasking, Round Robin Priority Driven OS right? Like 3 tasks with the same priority are time sliced with equal processing time? Inter task communication done with pipes. A task can suspend on a pipe until it's written to by another one. A task that sits in a while loop only gets X processor time before it's swapped out.
It's just that if you set up a loop to sleep for 95mS and process for 5mS there's a possibility that the system will be busy doing Python Garbage collection and it won't wake up exactly 100mS later. Most of the stuff I do is on smaller microprocessors with co-operative multi-threaded state machines. No while loops allowed within a state since there is no pre-emption. Any time critical operations are generated off timer interrupts. One of the features I use are what I call recurring timers. Once started and armed the code can wait in a state until the timer is done. Inside the interrupt routine the timer is immediately started again but not armed. After the thread code sees the timer is done, it re-arms and processes what it needs to do before returning. Even if there is a 10mS latency before the thread were to deal with the timer it does the 5mS worth of work and then returns to wait for the timer to expire again. That will happen 85mS later since it was restarted inside the interrupt routine. Genearally I don't see that sort of latency so although there's jitter there's usually only 1% or so. Not good for stepper motors but fine for a lot of other automation tasks. John > -----Original Message----- > From: Jon Elson [mailto:el...@pico-systems.com] > Sent: June-23-18 8:13 PM > To: Enhanced Machine Controller (EMC) > Subject: Re: [Emc-users] Raspberry Pi PREEMPT-RT > > On 06/23/2018 06:52 PM, John Dammeyer wrote: > > Hi Jon, > > > > So you are confirming that standard Linux like Ubuntu for a PC, the Raspian > > for the Pi or the Debian for the Beagle is just a multi-user OS and also not > > real time. > > > Yes, the standard OS is not real time. If the OS has a RT > option applied to it, it will append something > to indicate that. One of my systems shows this : > > Linux jelinux 4.6.0-0.bpo.1-rt-amd64 #1 SMP PREEMPT RT > Debian 4.6.3-1~bpo8+1 (2016-07-13) x86_64 GNU/Linux > > Jon > > ---------------------------------------------------------------------------- -- > Check out the vibrant tech community on one of the world's most > engaging tech sites, Slashdot.org! http://sdm.link/slashdot > _______________________________________________ > Emc-users mailing list > Emc-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/emc-users ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot _______________________________________________ Emc-users mailing list Emc-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-users