updates 2.9 Bookworm
14 Dec 2023 09:18 - 14 Dec 2023 09:19 #288117
by Mecanix
Replied by Mecanix on topic updates 2.9 Bookworm
Last edit: 14 Dec 2023 09:19 by Mecanix.
Please Log in or Create an account to join the conversation.
16 Dec 2023 04:51 #288293
by Lcvette
Replied by Lcvette on topic updates 2.9 Bookworm
thanks, I will give that a try and report back!I wish the bookworm latency issues would get dialed in and sorted.
I've managed to dial my latency down to +/-0.04ms with ethtool. Contrary to the infamous hardware-irq-coalesce-rx−usecs 0 documented (this 0 didn't worked for me, made things worst in fact), some tuning/testing is required.
Using ethtool --coalesce
$ sudo apt install ethtool
$ sudo ethtool -c eth0
( take notes of your rx-usecs and tx-usecs defaults. Mine were 100 and 1000 respectively)
( start Linuxcnc and have it connected to the card)
( Time to dial/tune)
$ sudo ethtool -C eth0 rx-usecs 50
$ sudo ethtool -C eth0 tx-usecs 500
$ ping ip.ip.ip.ip
....
$ sudo ethtool -C eth0 rx-usecs 25
$ sudo ethtool -C eth0 tx-usecs 250
$ ping ip.ip.ip.ip
....
( Repeat tuning until you get satisfactory latency and no lcnc task/axis pos errors, etc. )
( Once everyone's happy, save those in your interface conf. )
$ sudo nano /etc/network/interfaces
***********************************************
# The loopback network interface
auto lo
iface lo inet loopback
auto eth0
iface eth0 inet static
(... ... static address stuff)
hardware-irq-coalesce-rx−usecs 25
hardware-irq-coalesce-tx−usecs 250
***********************************************
$ sudo systemctl restart networking
Please Log in or Create an account to join the conversation.
16 Dec 2023 05:44 #288296
by Lcvette
Replied by Lcvette on topic updates 2.9 Bookworm
Attachments:
Please Log in or Create an account to join the conversation.
16 Dec 2023 06:01 - 16 Dec 2023 06:02 #288298
by PCW
Replied by PCW on topic updates 2.9 Bookworm
You cannot set TX usecs on some hardware
If you watch hm2_[card].0.read.time as you adjust the rx-usecs value
You will find the time time gets longer for any rx-usecs value other than 0.
This is not surprising since the rx-usecs value is how long the host should
hang in the Ethernet interrupt service routine before exiting. Waiting make sense
if you are expecting another packet but this is not the case here.
If you watch hm2_[card].0.read.time as you adjust the rx-usecs value
You will find the time time gets longer for any rx-usecs value other than 0.
This is not surprising since the rx-usecs value is how long the host should
hang in the Ethernet interrupt service routine before exiting. Waiting make sense
if you are expecting another packet but this is not the case here.
Last edit: 16 Dec 2023 06:02 by PCW.
Please Log in or Create an account to join the conversation.
Time to create page: 0.122 seconds