Installing LinuxCNC 2.9 on Raspberry Pi 4B with Preempt-RT kernel
- rodw
-
- Away
- Platinum Member
-
Less
More
- Posts: 10954
- Thank you received: 3635
22 Feb 2023 00:26 #264997
by rodw
Replied by rodw on topic Installing LinuxCNC 2.9 on Raspberry Pi 4B with Preempt-RT kernel
We are hoping to migrate this to the Armbian build system which I've been playing with for a while. I've missed something with the preempt_rt but with Alan's help, I think it will be pretty easy to sort out from here. That will reduce it to a one line build command.To anyone looking for a low latency board computer that you can actually get your hands on, check out this thread.
forum.linuxcnc.org/18-computer/48113-odr...ent-for-raspberry-pi
We've managed to get sub-20 microsecond latency under realistic test conditions.
Please Log in or Create an account to join the conversation.
- nickom44
- Offline
- New Member
-
Less
More
- Posts: 19
- Thank you received: 0
03 Mar 2023 12:40 - 04 Mar 2023 16:45 #265775
by nickom44
Replied by nickom44 on topic Installing LinuxCNC 2.9 on Raspberry Pi 4B with Preempt-RT kernel
Hi Alan,
I have been running through the instructions all is going well (after setting up docker) but when I run
debuild -uc -us
after some time compiling taskmodule.cc I get the error below , do you know what this error means and how to fix it.
I should add that I killed the process as it seemed to have crashed.
Thanks
Nick
Compiling emc/task/taskmodule.cc
g++: fatal error: Killed signal terminated program cc1plus
compilation terminated.
make[2]: *** [Makefile:287: objects/emc/task/taskmodule.o] Error 1
make[2]: Leaving directory '/home/nick/build/src'
make[1]: *** [debian/rules:50: override_dh_auto_build-arch] Error 2
make[1]: Leaving directory '/home/nick/build'
make: *** [debian/rules:38: build] Error 2
dpkg-buildpackage: error: debian/rules build subprocess returned exit status 2
debuild: fatal error at line 1182:
dpkg-buildpackage -us -uc -ui failed
I have been running through the instructions all is going well (after setting up docker) but when I run
debuild -uc -us
after some time compiling taskmodule.cc I get the error below , do you know what this error means and how to fix it.
I should add that I killed the process as it seemed to have crashed.
Thanks
Nick
Compiling emc/task/taskmodule.cc
g++: fatal error: Killed signal terminated program cc1plus
compilation terminated.
make[2]: *** [Makefile:287: objects/emc/task/taskmodule.o] Error 1
make[2]: Leaving directory '/home/nick/build/src'
make[1]: *** [debian/rules:50: override_dh_auto_build-arch] Error 2
make[1]: Leaving directory '/home/nick/build'
make: *** [debian/rules:38: build] Error 2
dpkg-buildpackage: error: debian/rules build subprocess returned exit status 2
debuild: fatal error at line 1182:
dpkg-buildpackage -us -uc -ui failed
Last edit: 04 Mar 2023 16:45 by nickom44. Reason: extra information
Please Log in or Create an account to join the conversation.
- nickom44
- Offline
- New Member
-
Less
More
- Posts: 19
- Thank you received: 0
06 Mar 2023 16:26 #265960
by nickom44
Replied by nickom44 on topic Installing LinuxCNC 2.9 on Raspberry Pi 4B with Preempt-RT kernel
Still couldn't get debuild to complete so reverted to using build in place. this time it compiled.
Regards
Nick
Regards
Nick
Please Log in or Create an account to join the conversation.
- mor
- Offline
- Junior Member
-
Less
More
- Posts: 37
- Thank you received: 2
22 Mar 2023 05:49 #267273
by mor
Replied by mor on topic Installing LinuxCNC 2.9 on Raspberry Pi 4B with Preempt-RT kernel
Thanks for this guide. I think I got everything installed properly but encountered a couple areas where I had questions:
1. QT Designer script asked for "Run In Place" vs "Package" installation; I assumed Package.
2. sudo dpkg -i mesact_1.1.2_arm64.deb had an error message saying it wasn't a valid Debian archive; I downloaded mesact_1.2.3_arm64.deb and installed instead. Not sure if this will be an issue with the previous compilation steps before it.
Thanks again!
~Mor
1. QT Designer script asked for "Run In Place" vs "Package" installation; I assumed Package.
2. sudo dpkg -i mesact_1.1.2_arm64.deb had an error message saying it wasn't a valid Debian archive; I downloaded mesact_1.2.3_arm64.deb and installed instead. Not sure if this will be an issue with the previous compilation steps before it.
Thanks again!
~Mor
Please Log in or Create an account to join the conversation.
- rodw
-
- Away
- Platinum Member
-
Less
More
- Posts: 10954
- Thank you received: 3635
22 Mar 2023 07:18 #267278
by rodw
Replied by rodw on topic Installing LinuxCNC 2.9 on Raspberry Pi 4B with Preempt-RT kernel
This might muddy the waters.....
There is not really any need to be building software on the pi when a version of Debian Bookworm exists for several versions of the pi.
Here is some instructions I put together in April/May 2022.
docs.google.com/document/d/1S0K-UBlXnsYC...b_0/edit?usp=sharing
Note the Debian images do not install a graphical environment but we can install them using tasksel
Some of the tips came from a video showing Debian Bullseye I found over 12 months ago.
I don't think there is a solution to install qtpyvcp and probe-basic yet.
There is not really any need to be building software on the pi when a version of Debian Bookworm exists for several versions of the pi.
Here is some instructions I put together in April/May 2022.
docs.google.com/document/d/1S0K-UBlXnsYC...b_0/edit?usp=sharing
Note the Debian images do not install a graphical environment but we can install them using tasksel
Some of the tips came from a video showing Debian Bullseye I found over 12 months ago.
I don't think there is a solution to install qtpyvcp and probe-basic yet.
Please Log in or Create an account to join the conversation.
- mor
- Offline
- Junior Member
-
Less
More
- Posts: 37
- Thank you received: 2
22 Mar 2023 08:43 #267281
by mor
Replied by mor on topic Installing LinuxCNC 2.9 on Raspberry Pi 4B with Preempt-RT kernel
I'll look into that. I tried the standard official install instructions but after the auto-updates the pi wouldn't boot anymore so I gave up. This thread's instructions worked for me so far.
Please Log in or Create an account to join the conversation.
- theAndreas
- Offline
- New Member
-
Less
More
- Posts: 1
- Thank you received: 1
11 Apr 2023 20:43 - 11 Apr 2023 20:46 #268838
by theAndreas
Replied by theAndreas on topic Installing LinuxCNC 2.9 on Raspberry Pi 4B with Preempt-RT kernel
Thanks for the great tutorial. I wanted to have a kernel debian package of the realtime kernel. Unfortunately, there is no official deb package. So I decided to do it on my own. It was much more complex than expected. So I created a
GitHub repository
. But be careful its work in progress.
Last edit: 11 Apr 2023 20:46 by theAndreas.
The following user(s) said Thank You: rodw
Please Log in or Create an account to join the conversation.
- jay.perez1
- Offline
- Senior Member
-
Less
More
- Posts: 47
- Thank you received: 3
10 Dec 2023 02:50 - 13 Dec 2023 00:12 #287737
by jay.perez1
Replied by jay.perez1 on topic Installing LinuxCNC 2.9 on Raspberry Pi 4B with Preempt-RT kernel
I don't think there is a solution to install qtpyvcp and probe-basic yet.
Hi Rod,
I've been looking around to see if someone's been able to install probe_basic on a rpi4 setup but haven't found anything. Do you know if this has been accomplished yet ?
Thanks !
Jay
P.S. I should mention we're trying to use the BTT SKR v1.4 Turbo.
Last edit: 13 Dec 2023 00:12 by jay.perez1. Reason: Added information
Please Log in or Create an account to join the conversation.
- behai
- Offline
- Junior Member
-
Less
More
- Posts: 34
- Thank you received: 9
28 Oct 2024 05:56 #313358
by behai
Replied by behai on topic Installing LinuxCNC 2.9 on Raspberry Pi 4B with Preempt-RT kernel
Hi,
Thank you Alan for the original instructions, I have learned a lot from this post in the three days.
-- I got stuck: my kernel is SMP PREEMPT rather than SMP PREEMPT_RT.
I am Be Hai from Melbourne, Australia. I would like to learn LinuxCNC. Presently I know nothing about CNC or LinuxCNC.
I am a computer programmer. I am familar with Linux, and a tiny bit familar with Raspberry Pi 4 Model B: I have been learning basic physical computing with it, using the Python language.
I have spent more than a week learning about LinuxCNC, particularly how to install it onto a Raspberry Pi 4 Model B.
I spent the last three days exercising the instructions kindly posted by Alan.
⓵ I am using a clean and fresh Ubuntu 24.04.1 LTS (Noble Numbat) machine to do the build.
( I first started with Ubuntu 22.10 (Kinetic Kudu) and I went nowhere with this EOL version. )
⓶ The command
```
make RASPIOS_IMAGE_NAME=raspios_full_arm64
```
produces raspios_lite_arm64-Pi5.zip. I burnt this image into my Pi 4 anyway. And I have managed to get as far as to section 2.6 Install Mesaflash. There are error in between but I managed to find solutions for them.
LinuxCNC was installed, but I could not run it since there was no desktop.
⓷ Based on the instruction given in github.com/remusmp/rpi-rt-kernel
I replaced ```make RASPIOS_IMAGE_NAME=raspios_full_arm64``` with:
```
sudo make Pi4
```
This command produces raspios_lite_arm64-Pi4.zip. Applying this image, the kernel information reports only SMP PREEMPT:
```
uname -a
```
Output:
```
Linux picnc 6.6.31+rpt-rpi-v8 #1 SMP PREEMPT Debian 1:6.6.31-1+rpt1 (2024-05-29) aarch64 GNU/Linux
```
```
cat /proc/version
```
Output:
```
Linux version 6.6.31+rpt-rpi-v8 (This email address is being protected from spambots. You need JavaScript enabled to view it.) (gcc-12 (Debian 12.2.0-14) 12.2.0, GNU ld (GNU Binutils for Debian) 2.40) #1 SMP PREEMPT Debian 1:6.6.31-1+rpt1 (2024-05-29)
```
⓸ Interestingly, if I use 'Raspberry Pi OS (other)' from Raspberry Pi Imager as shown:
Then select:
```
Raspberry Pi OS Full (64-bit)
A port of Debian Bookworm with desktop environment and recommended applications.
Released: 2024-07-04
Online - 2.8 GB download
```
I also have the exact same kernel, but also with the desktop.
I am taking a break... I will try again to get RT going.
Thank you.
...behai.
Thank you Alan for the original instructions, I have learned a lot from this post in the three days.
-- I got stuck: my kernel is SMP PREEMPT rather than SMP PREEMPT_RT.
I am Be Hai from Melbourne, Australia. I would like to learn LinuxCNC. Presently I know nothing about CNC or LinuxCNC.
I am a computer programmer. I am familar with Linux, and a tiny bit familar with Raspberry Pi 4 Model B: I have been learning basic physical computing with it, using the Python language.
I have spent more than a week learning about LinuxCNC, particularly how to install it onto a Raspberry Pi 4 Model B.
I spent the last three days exercising the instructions kindly posted by Alan.
⓵ I am using a clean and fresh Ubuntu 24.04.1 LTS (Noble Numbat) machine to do the build.
( I first started with Ubuntu 22.10 (Kinetic Kudu) and I went nowhere with this EOL version. )
⓶ The command
```
make RASPIOS_IMAGE_NAME=raspios_full_arm64
```
produces raspios_lite_arm64-Pi5.zip. I burnt this image into my Pi 4 anyway. And I have managed to get as far as to section 2.6 Install Mesaflash. There are error in between but I managed to find solutions for them.
LinuxCNC was installed, but I could not run it since there was no desktop.
⓷ Based on the instruction given in github.com/remusmp/rpi-rt-kernel
I replaced ```make RASPIOS_IMAGE_NAME=raspios_full_arm64``` with:
```
sudo make Pi4
```
This command produces raspios_lite_arm64-Pi4.zip. Applying this image, the kernel information reports only SMP PREEMPT:
```
uname -a
```
Output:
```
Linux picnc 6.6.31+rpt-rpi-v8 #1 SMP PREEMPT Debian 1:6.6.31-1+rpt1 (2024-05-29) aarch64 GNU/Linux
```
```
cat /proc/version
```
Output:
```
Linux version 6.6.31+rpt-rpi-v8 (This email address is being protected from spambots. You need JavaScript enabled to view it.) (gcc-12 (Debian 12.2.0-14) 12.2.0, GNU ld (GNU Binutils for Debian) 2.40) #1 SMP PREEMPT Debian 1:6.6.31-1+rpt1 (2024-05-29)
```
⓸ Interestingly, if I use 'Raspberry Pi OS (other)' from Raspberry Pi Imager as shown:
Then select:
```
Raspberry Pi OS Full (64-bit)
A port of Debian Bookworm with desktop environment and recommended applications.
Released: 2024-07-04
Online - 2.8 GB download
```
I also have the exact same kernel, but also with the desktop.
I am taking a break... I will try again to get RT going.
Thank you.
...behai.
Please Log in or Create an account to join the conversation.
- Cant do this anymore bye all
-
- Offline
- Platinum Member
-
Less
More
- Posts: 1200
- Thank you received: 417
30 Oct 2024 00:09 #313465
by Cant do this anymore bye all
Replied by Cant do this anymore bye all on topic Installing LinuxCNC 2.9 on Raspberry Pi 4B with Preempt-RT kernel
First of all, my deepest deepest sympathies,sorry to hear you live in Melbourne, the only good thing Victoria has to other is Philip Island and the roads, airports and docks that lead out of the state.
Why aren't you using the premade image for your RPi ?
The links are on the Linuxcnc home page under downloads.
Why aren't you using the premade image for your RPi ?
The links are on the Linuxcnc home page under downloads.
The following user(s) said Thank You: behai
Please Log in or Create an account to join the conversation.
Time to create page: 0.110 seconds