Thoughts on using a standard low-latency Kernel?

More
13 Feb 2018 01:42 #105806 by blazini36
First I'll say that I'm not really a fan of Wheezy or the Ubuntu distributions that LinuxCNC comes packed with. WHich is pretty much the reason I endure the headache of installing and making it work under other distros.

I setup a previous PC with linuxcnc and a mesa 7i76e on LMDE2. This was mostly for testing but everything more or less got ironed out and worked well. On this system I patched a 4.9 kernel with preempt_rt. This was one of those little industrial PCs and unfortunately the CPU and GPU were a little slow for some of the image processing that needed to be done as well.

I just set up a new system with an AMD APU and Mint 18.3 that should be quite a bit faster. I haven't gotten to LinuxCNC on it yet but I just started playing with that same kernel and I'm having issues with it running graphics in software rendering mode, this does not seem to be the case in mints 4.10 generic kernel. I'm no Kernel Guru So I reached out on the Mint forums to see if somebody could point out what I may have missed in menuconfig.

A poster questioned why I would want to use an RT kernel over a stantard low-latency kernel that is better supported. My only real answer to that is all the other LinuxCNC guys do it. I understand the purpose of RT but I can't say I know how it would compare to a low-latency kernel. I also believe that the Mesa Ethernet boards operate somewhat differently than the parallel port boards in the fact that you don't actually run a base thread, only a servo thread. How this all stacks up I don't know, but I'm wondering if theres any sense in trying a standard low-latency kernel or if its possible with LinuxCNC.

Please Log in or Create an account to join the conversation.

More
28 Feb 2018 16:24 #106713 by andypugh
Try running the latency tests with the low-latency kernel.

It might work, but I would be surprised.

Please Log in or Create an account to join the conversation.

More
28 Feb 2018 21:45 #106766 by rodw
My understanding is that the Mesa ethernet communication mandates the preemptive kernel.

Try it on a low latency build. It might work, but I would be surprised.

Please Log in or Create an account to join the conversation.

More
01 Mar 2018 01:09 #106784 by PCW
You can use Mesa's Ethernet cards card with a stock kernel (nothing about the card demands real time)
The problem is that you will not get good enough latency to run LinuxCNCs 1 KHz servo thread reliably without using a
Preempt-RT (or perhaps Xenomai) kernel. RTAI doesn't currently work because it requires a kernel mode real time
Ethernet driver and development of these seems to have been abandoned so they only support a few quite old
Ethernet chips.

Please Log in or Create an account to join the conversation.

More
01 Mar 2018 01:23 #106786 by blazini36
I actually got the kernel issues ironed out on preempt RT shortly after I posted this so I never bothered trying a low latency kernel. I was just curious if anyone had tried it since I was talking to a fella that seemed adamant RT was unnecessary.

Please Log in or Create an account to join the conversation.

More
01 Mar 2018 12:56 #106796 by andypugh

I was talking to a fella that seemed adamant RT was unnecessary.


Maybe he is correct, or maybe he simply didn't understand the question or the context.

Please Log in or Create an account to join the conversation.

More
01 Mar 2018 14:03 #106804 by Todd Zuercher
Most of the general buzz on the internet regarding real-time (if you google it) seems to pertain to audio applications. And for those types of applications I think I've read that the standard low latency kernels he's referring to are good enough. I'm not so sure that the hard real time requirements are nearly as strict for those kinds of applications as they are for the motion control in Linuxcnc, but I don't really know how tight timings need to be for making audio sound right (not an audiophile).

Please Log in or Create an account to join the conversation.

More
28 Feb 2020 17:16 #158768 by pmconsulting
Yes, the low latency kernel is suited to MIDI over USB. The sampling rates for midi don't reach the speeds that servo threads require. Midi needs to respond fast enough that, for example, if I play a digital keyboard, there is no perceptible delay between hitting keys and hearing sounds. These speeds are in the millisecond range and nowhere near the kHz speeds that servos need.

I love how ignorant musicians can be. I've read more than my share of posts insisting that low latency is as fast as anyone would need. The fact is that it's fast enough for Kenny G., but people who know and do things actually need their hardware to work at CPU speeds. Elevator music is one thing. CNCing an elevator is another.

Please Log in or Create an account to join the conversation.

Time to create page: 0.419 seconds
Powered by Kunena Forum