RPI4 Raspbian 64 bit & LinuxCNC
07 Oct 2022 02:18 - 07 Oct 2022 02:21 #253641
by Bari
Replied by Bari on topic RPI4 Raspbian 64 bit & LinuxCNC
highlab.com/~seb/linuxcnc/rpi4-10us-latency.png
Seb on the IRC dev channel:
'it involves running each RT thread on its own dedicated CPU, and using busywait instead of sleep to start the next thread invocation
that's running on the arm64/aarch64 debian bookworm image from raspi.debian.net, not Raspberry Pi OS/raspbian
it's just a proof of concept at this point, i hope to clean it up and push it for review in the next week or two"
Hopefully transportable to actually available ARM boards vs Rpi.
Seb on the IRC dev channel:
'it involves running each RT thread on its own dedicated CPU, and using busywait instead of sleep to start the next thread invocation
that's running on the arm64/aarch64 debian bookworm image from raspi.debian.net, not Raspberry Pi OS/raspbian
it's just a proof of concept at this point, i hope to clean it up and push it for review in the next week or two"
Hopefully transportable to actually available ARM boards vs Rpi.
Last edit: 07 Oct 2022 02:21 by Bari.
Please Log in or Create an account to join the conversation.
14 Nov 2022 03:42 - 14 Nov 2022 08:36 #256653
by Zuo99
Replied by Zuo99 on topic RPI4 Raspbian 64 bit & LinuxCNC
Hello, elovalvo. Thank you for your work.
I used version 2. 8 from other topics before, and then I used your link Linux 5.15.65-rt49-v8 linuxcnc 2.9. But I found that raspberry pie is more stuttered than the previous version, flipping through your post, it seems that the delay effect of the 5.4.61-rt32-v8 version is better, but the previous link is no longer available. I hope you can provide the link to 5.4.61-rt32-v8 2.9. thank you very much.
I used version 2. 8 from other topics before, and then I used your link Linux 5.15.65-rt49-v8 linuxcnc 2.9. But I found that raspberry pie is more stuttered than the previous version, flipping through your post, it seems that the delay effect of the 5.4.61-rt32-v8 version is better, but the previous link is no longer available. I hope you can provide the link to 5.4.61-rt32-v8 2.9. thank you very much.
Last edit: 14 Nov 2022 08:36 by Zuo99.
Please Log in or Create an account to join the conversation.
15 Nov 2022 18:12 #256791
by elovalvo
To make room in the google drive I deleted the versions that seemed outdated.
Now let's see if I saved that version you refer to somewhere, but I don't think so.
Or I try to reconstruct it as reported here
forum.linuxcnc.org/9-installing-linuxcnc...uxcnc?start=0#178299
Replied by elovalvo on topic RPI4 Raspbian 64 bit & LinuxCNC
Hello, elovalvo. Thank you for your work.
I used version 2. 8 from other topics before, and then I used your link Linux 5.15.65-rt49-v8 linuxcnc 2.9. But I found that raspberry pie is more stuttered than the previous version, flipping through your post, it seems that the delay effect of the 5.4.61-rt32-v8 version is better, but the previous link is no longer available. I hope you can provide the link to 5.4.61-rt32-v8 2.9. thank you very much.
To make room in the google drive I deleted the versions that seemed outdated.
Now let's see if I saved that version you refer to somewhere, but I don't think so.
Or I try to reconstruct it as reported here
forum.linuxcnc.org/9-installing-linuxcnc...uxcnc?start=0#178299
Please Log in or Create an account to join the conversation.
17 Nov 2022 23:06 #256979
by andypugh
Replied by andypugh on topic RPI4 Raspbian 64 bit & LinuxCNC
For a possible fix for stuttering, see the last paragraph here:
forum.linuxcnc.org/38-general-linuxcnc-q...lved?start=10#256153
forum.linuxcnc.org/38-general-linuxcnc-q...lved?start=10#256153
Please Log in or Create an account to join the conversation.
07 Feb 2023 15:26 #263948
by beaker152
Replied by beaker152 on topic RPI4 Raspbian 64 bit & LinuxCNC
i've recently set up a raspberry pi 4b with a Mesa 7i96S with stepper motors and am seeing multiple problems
after installing linucnc-2.9.0pre-bullseye_arm64rt.zip as posted by elovalvo in:
forum.linuxcnc.org/9-installing-linuxcnc...cnc?start=150#253623
i am seeing multiple errors when running through my gcode:
it's not unusual to get "Unexpected realtime delay on task 0 with period 1000000"
the most common one happening during a run is "joint * following error" (happens on any of the 3 joints)
and most catastrophic: "hm2/hm2_7i96s.0: error finishing read"
as described in Mesa hm2/hm2_7i96s.0: error finishing read
any suggestions would be greatly appreciated!
various diagnostics below, latency plot and hal file attached
linuxcnc@raspberrypi:~ $ uname -a
Linux raspberrypi 5.15.65-rt49-v8+ #1 SMP PREEMPT_RT Tue Sep 6 18:12:35 BST 2022 aarch64 GNU/Linux
===============
linuxcnc@raspberrypi:~ $ cat /proc/cpuinfo
processor : 0
BogoMIPS : 108.00
Features : fp asimd evtstrm crc32 cpuid
CPU implementer : 0x41
CPU architecture: 8
CPU variant : 0x0
CPU part : 0xd08
CPU revision : 3
processor : 1
BogoMIPS : 108.00
Features : fp asimd evtstrm crc32 cpuid
CPU implementer : 0x41
CPU architecture: 8
CPU variant : 0x0
CPU part : 0xd08
CPU revision : 3
processor : 2
BogoMIPS : 108.00
Features : fp asimd evtstrm crc32 cpuid
CPU implementer : 0x41
CPU architecture: 8
CPU variant : 0x0
CPU part : 0xd08
CPU revision : 3
processor : 3
BogoMIPS : 108.00
Features : fp asimd evtstrm crc32 cpuid
CPU implementer : 0x41
CPU architecture: 8
CPU variant : 0x0
CPU part : 0xd08
CPU revision : 3
Hardware : BCM2835
Revision : c03115
Serial : 10000000ce7aa130
Model : Raspberry Pi 4 Model B Rev 1.5
=================
Revision : c03115
SoC : BCM2711
RAM : 4GB
Storage : MicroSD
USB ports : 4 (of which 2 USB3)
Ethernet ports : 1 (1000Mbps max. speed)
Wi-fi : True
Bluetooth : True
Camera ports (CSI) : 1
Display ports (DSI): 1
===============
--- 10.10.10.10 ping statistics ---
1000 packets transmitted, 1000 received, 0% packet loss, time 1022926ms
rtt min/avg/max/mdev = 0.143/0.165/0.591/0.035 ms
=================
linuxcnc@raspberrypi:~ $ ethtool eth0
Settings for eth0:
Supported ports: [ TP MII ]
Supported link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
1000baseT/Half 1000baseT/Full
Supported pause frame use: Symmetric Receive-only
Supports auto-negotiation: Yes
Supported FEC modes: Not reported
Advertised link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
1000baseT/Half 1000baseT/Full
Advertised pause frame use: Symmetric Receive-only
Advertised auto-negotiation: Yes
Advertised FEC modes: Not reported
Link partner advertised link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
Link partner advertised pause frame use: Symmetric
Link partner advertised auto-negotiation: Yes
Link partner advertised FEC modes: Not reported
Speed: 100Mb/s
Duplex: Full
Auto-negotiation: on
master-slave cfg: preferred slave
master-slave status: slave
Port: Twisted Pair
PHYAD: 1
Transceiver: external
MDI-X: Unknown
netlink error: Operation not permitted
Current message level: 0x00000007 (7)
drv probe link
Link detected: yes
==============
linuxcnc@raspberrypi:~ $ ethtool -S eth0 | column
NIC statistics: tx_oversize: 0
rx_packets: 8628942 tx_defer: 0
tx_packets: 11299821 tx_excess_defer: 0
rx_bytes: 904320010 tx_single_col: 0
tx_bytes: 1203609643 tx_multi_col: 0
rx_errors: 0 tx_late_col: 0
tx_errors: 0 tx_excess_col: 0
rx_dropped: 0 tx_frags: 0
tx_dropped: 0 tx_total_col: 0
multicast: 0 tx_jabber: 0
rx_64_octets: 1249 tx_bytes: 1248832409
rx_65_127_oct: 8627693 tx_good_pkts: 11299821
rx_128_255_oct: 0 tx_unicast: 11298802
rx_256_511_oct: 0 rx_runt_pkts: 0
rx_512_1023_oct: 0 rx_runt_valid_fcs: 0
rx_1024_1518_oct: 0 rx_runt_inval_fcs_align: 0
rx_vlan_1519_1522_oct: 0 rx_runt_bytes: 0
rx_1522_2047_oct: 0 rbuf_ovflow_cnt: 0
rx_2048_4095_oct: 0 rbuf_err_cnt: 0
rx_4096_9216_oct: 0 mdf_err_cnt: 0
rx_pkts: 8628942 alloc_rx_buff_failed: 0
rx_bytes: 938835778 rx_dma_failed: 0
rx_multicast: 0 tx_dma_failed: 0
rx_broadcast: 0 tx_realloc_tsb: 0
rx_fcs: 0 tx_realloc_tsb_failed: 0
rx_control: 0 txq0_packets: 1804878
rx_pause: 0 txq0_bytes: 209320936
rx_unknown: 0 rxq0_bytes: 0
rx_align: 0 rxq0_packets: 0
rx_outrange: 0 rxq0_errors: 0
rx_code: 0 rxq0_dropped: 0
rx_carrier: 0 txq1_packets: 1
rx_oversize: 0 txq1_bytes: 86
rx_jabber: 0 rxq1_bytes: 0
rx_mtu_err: 0 rxq1_packets: 0
rx_good_pkts: 8628942 rxq1_errors: 0
rx_unicast: 8628942 rxq1_dropped: 0
rx_ppp: 0 txq2_packets: 8025624
rx_crc: 0 txq2_bytes: 823705364
tx_64_octets: 1649 rxq2_bytes: 0
tx_65_127_oct: 8627688 rxq2_packets: 0
tx_128_255_oct: 2669682 rxq2_errors: 0
tx_256_511_oct: 802 rxq2_dropped: 0
tx_512_1023_oct: 0 txq3_packets: 795
tx_1024_1518_oct: 0 txq3_bytes: 262059
tx_vlan_1519_1522_oct: 0 rxq3_bytes: 0
tx_1522_2047_oct: 0 rxq3_packets: 0
tx_2048_4095_oct: 0 rxq3_errors: 0
tx_4096_9216_oct: 0 rxq3_dropped: 0
tx_pkts: 11299821 txq16_packets: 1468523
tx_multicast: 83 txq16_bytes: 170321198
tx_broadcast: 936 rxq16_bytes: 904320010
tx_pause: 0 rxq16_packets: 8628942
tx_control: 0 rxq16_errors: 0
tx_fcs_err: 0 rxq16_dropped: 0
==============
linuxcnc@raspberrypi:~ $ ethtool -i eth0
driver: bcmgenet
version: 5.15.65-rt49-v8+
firmware-version:
expansion-rom-version:
bus-info:
supports-statistics: yes
supports-test: no
supports-eeprom-access: no
supports-register-dump: no
supports-priv-flags: no
================
linuxcnc@raspberrypi:~ $ ethtool -c eth0
Coalesce parameters for eth0:
Adaptive RX: off TX: n/a
stats-block-usecs: n/a
sample-interval: n/a
pkt-rate-low: n/a
pkt-rate-high: n/a
rx-usecs: 57
rx-frames: 1
rx-usecs-irq: n/a
rx-frames-irq: n/a
tx-usecs: n/a
tx-frames: 10
tx-usecs-irq: n/a
tx-frames-irq: n/a
rx-usecs-low: n/a
rx-frame-low: n/a
tx-usecs-low: n/a
tx-frame-low: n/a
rx-usecs-high: n/a
rx-frame-high: n/a
tx-usecs-high: n/a
tx-frame-high: n/a
==============
after installing linucnc-2.9.0pre-bullseye_arm64rt.zip as posted by elovalvo in:
forum.linuxcnc.org/9-installing-linuxcnc...cnc?start=150#253623
i am seeing multiple errors when running through my gcode:
it's not unusual to get "Unexpected realtime delay on task 0 with period 1000000"
the most common one happening during a run is "joint * following error" (happens on any of the 3 joints)
and most catastrophic: "hm2/hm2_7i96s.0: error finishing read"
as described in Mesa hm2/hm2_7i96s.0: error finishing read
any suggestions would be greatly appreciated!
various diagnostics below, latency plot and hal file attached
linuxcnc@raspberrypi:~ $ uname -a
Linux raspberrypi 5.15.65-rt49-v8+ #1 SMP PREEMPT_RT Tue Sep 6 18:12:35 BST 2022 aarch64 GNU/Linux
===============
linuxcnc@raspberrypi:~ $ cat /proc/cpuinfo
processor : 0
BogoMIPS : 108.00
Features : fp asimd evtstrm crc32 cpuid
CPU implementer : 0x41
CPU architecture: 8
CPU variant : 0x0
CPU part : 0xd08
CPU revision : 3
processor : 1
BogoMIPS : 108.00
Features : fp asimd evtstrm crc32 cpuid
CPU implementer : 0x41
CPU architecture: 8
CPU variant : 0x0
CPU part : 0xd08
CPU revision : 3
processor : 2
BogoMIPS : 108.00
Features : fp asimd evtstrm crc32 cpuid
CPU implementer : 0x41
CPU architecture: 8
CPU variant : 0x0
CPU part : 0xd08
CPU revision : 3
processor : 3
BogoMIPS : 108.00
Features : fp asimd evtstrm crc32 cpuid
CPU implementer : 0x41
CPU architecture: 8
CPU variant : 0x0
CPU part : 0xd08
CPU revision : 3
Hardware : BCM2835
Revision : c03115
Serial : 10000000ce7aa130
Model : Raspberry Pi 4 Model B Rev 1.5
=================
Revision : c03115
SoC : BCM2711
RAM : 4GB
Storage : MicroSD
USB ports : 4 (of which 2 USB3)
Ethernet ports : 1 (1000Mbps max. speed)
Wi-fi : True
Bluetooth : True
Camera ports (CSI) : 1
Display ports (DSI): 1
===============
--- 10.10.10.10 ping statistics ---
1000 packets transmitted, 1000 received, 0% packet loss, time 1022926ms
rtt min/avg/max/mdev = 0.143/0.165/0.591/0.035 ms
=================
linuxcnc@raspberrypi:~ $ ethtool eth0
Settings for eth0:
Supported ports: [ TP MII ]
Supported link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
1000baseT/Half 1000baseT/Full
Supported pause frame use: Symmetric Receive-only
Supports auto-negotiation: Yes
Supported FEC modes: Not reported
Advertised link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
1000baseT/Half 1000baseT/Full
Advertised pause frame use: Symmetric Receive-only
Advertised auto-negotiation: Yes
Advertised FEC modes: Not reported
Link partner advertised link modes: 10baseT/Half 10baseT/Full
100baseT/Half 100baseT/Full
Link partner advertised pause frame use: Symmetric
Link partner advertised auto-negotiation: Yes
Link partner advertised FEC modes: Not reported
Speed: 100Mb/s
Duplex: Full
Auto-negotiation: on
master-slave cfg: preferred slave
master-slave status: slave
Port: Twisted Pair
PHYAD: 1
Transceiver: external
MDI-X: Unknown
netlink error: Operation not permitted
Current message level: 0x00000007 (7)
drv probe link
Link detected: yes
==============
linuxcnc@raspberrypi:~ $ ethtool -S eth0 | column
NIC statistics: tx_oversize: 0
rx_packets: 8628942 tx_defer: 0
tx_packets: 11299821 tx_excess_defer: 0
rx_bytes: 904320010 tx_single_col: 0
tx_bytes: 1203609643 tx_multi_col: 0
rx_errors: 0 tx_late_col: 0
tx_errors: 0 tx_excess_col: 0
rx_dropped: 0 tx_frags: 0
tx_dropped: 0 tx_total_col: 0
multicast: 0 tx_jabber: 0
rx_64_octets: 1249 tx_bytes: 1248832409
rx_65_127_oct: 8627693 tx_good_pkts: 11299821
rx_128_255_oct: 0 tx_unicast: 11298802
rx_256_511_oct: 0 rx_runt_pkts: 0
rx_512_1023_oct: 0 rx_runt_valid_fcs: 0
rx_1024_1518_oct: 0 rx_runt_inval_fcs_align: 0
rx_vlan_1519_1522_oct: 0 rx_runt_bytes: 0
rx_1522_2047_oct: 0 rbuf_ovflow_cnt: 0
rx_2048_4095_oct: 0 rbuf_err_cnt: 0
rx_4096_9216_oct: 0 mdf_err_cnt: 0
rx_pkts: 8628942 alloc_rx_buff_failed: 0
rx_bytes: 938835778 rx_dma_failed: 0
rx_multicast: 0 tx_dma_failed: 0
rx_broadcast: 0 tx_realloc_tsb: 0
rx_fcs: 0 tx_realloc_tsb_failed: 0
rx_control: 0 txq0_packets: 1804878
rx_pause: 0 txq0_bytes: 209320936
rx_unknown: 0 rxq0_bytes: 0
rx_align: 0 rxq0_packets: 0
rx_outrange: 0 rxq0_errors: 0
rx_code: 0 rxq0_dropped: 0
rx_carrier: 0 txq1_packets: 1
rx_oversize: 0 txq1_bytes: 86
rx_jabber: 0 rxq1_bytes: 0
rx_mtu_err: 0 rxq1_packets: 0
rx_good_pkts: 8628942 rxq1_errors: 0
rx_unicast: 8628942 rxq1_dropped: 0
rx_ppp: 0 txq2_packets: 8025624
rx_crc: 0 txq2_bytes: 823705364
tx_64_octets: 1649 rxq2_bytes: 0
tx_65_127_oct: 8627688 rxq2_packets: 0
tx_128_255_oct: 2669682 rxq2_errors: 0
tx_256_511_oct: 802 rxq2_dropped: 0
tx_512_1023_oct: 0 txq3_packets: 795
tx_1024_1518_oct: 0 txq3_bytes: 262059
tx_vlan_1519_1522_oct: 0 rxq3_bytes: 0
tx_1522_2047_oct: 0 rxq3_packets: 0
tx_2048_4095_oct: 0 rxq3_errors: 0
tx_4096_9216_oct: 0 rxq3_dropped: 0
tx_pkts: 11299821 txq16_packets: 1468523
tx_multicast: 83 txq16_bytes: 170321198
tx_broadcast: 936 rxq16_bytes: 904320010
tx_pause: 0 rxq16_packets: 8628942
tx_control: 0 rxq16_errors: 0
tx_fcs_err: 0 rxq16_dropped: 0
==============
linuxcnc@raspberrypi:~ $ ethtool -i eth0
driver: bcmgenet
version: 5.15.65-rt49-v8+
firmware-version:
expansion-rom-version:
bus-info:
supports-statistics: yes
supports-test: no
supports-eeprom-access: no
supports-register-dump: no
supports-priv-flags: no
================
linuxcnc@raspberrypi:~ $ ethtool -c eth0
Coalesce parameters for eth0:
Adaptive RX: off TX: n/a
stats-block-usecs: n/a
sample-interval: n/a
pkt-rate-low: n/a
pkt-rate-high: n/a
rx-usecs: 57
rx-frames: 1
rx-usecs-irq: n/a
rx-frames-irq: n/a
tx-usecs: n/a
tx-frames: 10
tx-usecs-irq: n/a
tx-frames-irq: n/a
rx-usecs-low: n/a
rx-frame-low: n/a
tx-usecs-low: n/a
tx-frame-low: n/a
rx-usecs-high: n/a
rx-frame-high: n/a
tx-usecs-high: n/a
tx-frame-high: n/a
==============
Please Log in or Create an account to join the conversation.
07 Feb 2023 18:33 #263964
by PCW
Replied by PCW on topic RPI4 Raspbian 64 bit & LinuxCNC
As a first step, can you try with rx-usecs set to 0?
Please Log in or Create an account to join the conversation.
08 Feb 2023 09:01 #264014
by rodw
Replied by rodw on topic RPI4 Raspbian 64 bit & LinuxCNC
try isolcpus=2,3 as well
Please Log in or Create an account to join the conversation.
08 Feb 2023 14:58 #264055
by elovalvo
Replied by elovalvo on topic RPI4 Raspbian 64 bit & LinuxCNC
Can you also publish also the basicxyz.ini file?
Please Log in or Create an account to join the conversation.
08 Feb 2023 20:38 - 08 Feb 2023 21:30 #264073
by beaker152
it returns: 1-3
should it be changed to 2-3?
newbie question: where/how does one change that setting?
Replied by beaker152 on topic RPI4 Raspbian 64 bit & LinuxCNC
when i run cat /sys/devices/system/cpu/isolatedtry isolcpus=2,3 as well
it returns: 1-3
should it be changed to 2-3?
newbie question: where/how does one change that setting?
Last edit: 08 Feb 2023 21:30 by beaker152.
Please Log in or Create an account to join the conversation.
08 Feb 2023 20:46 #264074
by beaker152
Replied by beaker152 on topic RPI4 Raspbian 64 bit & LinuxCNC
elovalvo, please see the attachments for the hal and ini files
thanks!
thanks!
Please Log in or Create an account to join the conversation.
Time to create page: 0.117 seconds