On Tuesday 04 July 2017 18:22:27 sam sokolik wrote: > I have been playing with linuxcnc for a long time... It has come a > long way. > > Currently the RTAI folks seem to have issues developing. > > Now there is RT_Preempt. Couple cool things.. It has been migrated > to the linux foundation. This means a lot eyes on it. It is also > pretty easy to build. I have done it quite a few times now. My > experience is that the out of the box rt_preemt has ok realtime > performance. Anywhere from 20 to 100us latency. Perfect for external > interface cards (mesa, pico and such). I have a computer that has > decent enough rt-preempt performance that it is running 50us base > thread. (small emco lathe - 100 line encoder for threading) I have > been running this for quite a while this way with no issues. > > Why am I rambling... > > Well - I have been playing with debian stretch and 4.9.0-3-rt kernel. > I booted our matsuura (j1900 quad core) which with no tweeking has > aprox 100us latency. (it has been running mesa ethernet cards with > rt_preempt - no issues) Next I booted it with some kernel line > tweaks. (checking the hardware - processors 0,1 and 2,3 share cache. > So I added > > isolcpus=2,3 idle=poll > > The latency on this system was phenomenal. It has been running for > hours now and still <6us
Somebody figure out how to do that to an r-pi-3b please, running on 4.4.4-rt9-v7+ #7 SMP PREEMPT RT Mon Mar 7 14:53:11 UTC 2016 armv7l GNU/Linux. Is horrible. None of the newer kernels Bertho and I have tried are any better, as they all throw away half the local keyboard and mouse events, making typing code impossible. The one above works well in that regard about 1 out of 3 powerdown reboots, and never on a hot reboot. An even when the keyboard behaves itself, I am looking at an exit report from a 4 hour session of linuxcnc showing 20 to 100 or more instances it overran the 1khz servo-thread by more than 10x the servo-thread times. Thanks to Andy's help, its now running both g33 and g76, HOWEVER I had to slow the spindle to around 50 rpms AND move the starting point, which I did have set .1" off the end of the workpiece, to .5" off the end of the workpiece. Why? Huge rubber band in series with the z movements, associated I think with the z acceleration limits, so z would start, wind up and overtake the spindle, then slowly settles into a steady run until the stop point was reached, at which time it stopped nicely and dead on the stop point, only on the start point did it hunt for synch. Once I had done that, the threads were cut very precisely, so precisely that if I want exact groove widths, I'll need to take 30 thou off the end of the tool to get back to where its actually 50 thou wide. Or run it twice with a 4 thou offset, doable in nice soft pvc pipe, but not in S.S. even if I rehardened the tool. Which, limited to a propane torch, I am not convinced I could do, not enough heat. But its not long enough to spare the 30 thou without cutting back the leading side too. I made it wrong in the first place. :( Another of my dumb-assed mistakes. Sigh.> > > these numbers are as good or better than rtai. Could we, with some > tweaks, use rt_preempt for printer port configs and forget about rtai > for now? I have more computer hardware I can test - but this is > pretty awesome. > I agree, Sam. Great stuff on an intel cpu. congratulations. ?: I have one machine, a D-525-MW that is still on the parport. Running the wheezy rt kernel. Would that idle=poll help it? Better yet, I'll test it yet tonight. Humm, latency slightly worse, from 9330 to 11450, about 2 u-secs worse, and glxgears went from 20 frames a second to 21 frames a second. Insignificant on that board and its atom cpu. > Good video explaining realtime > https://www.youtube.com/watch?v=BKkX9WASfpI > > Rt-preempt even runs decently on my laptop. I have actually run test > and real machines with it. (don't mute the speakers though... causes > huge spikes) > > sam Cheers, Gene Heskett -- "There are four boxes to be used in defense of liberty: soap, ballot, jury, and ammo. Please use in that order." -Ed Howdershelt (Author) Genes Web page <http://geneslinuxbox.net:6309/gene> ------------------------------------------------------------------------------ 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