Can the OPI5 be Configured to Run LCNC?

More
09 Apr 2023 04:56 - 09 Apr 2023 04:59 #268644 by kanuboy13b
So I am having a hell of a time trying to get anything to work. 
I have tried installing the image and header files in royka's latest post using sudo dpkg -i command on a fresh install of armbian jammy 23.02 that downloaded from armbian's website.
after having to create a link to python 3 to python, I was able to get the header .deb file to install without issue. The image on the other hand is still giving me problems.  Here is where the error starts:

[b]dpkg: error processing archive
linux-image-legacy-rockchip-rk3588_23.05.0-trunk--5.10.110-rt53-Scbae-De8b2-Pc4e1-Caa25Hfe66-Vc222-Be9aa_arm64.deb (--install):
[b] error setting ownership of './boot/System.map-5.10.110-rt53-rockchip-rk3588': Operation not permitted
[b]dpkg-deb: error: paste subprocess was killed by signal (Broken pipe)
[b]Armbian 'linux-image-legacy-rockchip-rk3588' for '5.10.110-rt53-rockchip-rk3588': 'postrm' starting.
[b]+ export 'DEB_MAINT_PARAMS=abort-upgrade 23.02.2 23.05.0-trunk--5.10.110-rt53-Scbae-De8b2-Pc4e1-Caa25Hfe66-Vc222-Be9aa'
[b]+ DEB_MAINT_PARAMS='abort-upgrade 23.02.2 23.05.0-trunk--5.10.110-rt53-Scbae-De8b2-Pc4e1-Caa25Hfe66-Vc222-Be9aa'[b]+ export INITRD=Yes
[b]+ INITRD=Yes[b]+ test -d /etc/kernel/postrm.d[b]+ run-parts --arg=5.10.110-rt53-rockchip-rk3588 --arg=/boot/vmlinuz-5.10.110-rt53-rockchip-rk3588 /etc/kernel/postrm.d[b]+ set +x[b]Armbian 'linux-image-legacy-rockchip-rk3588' for '5.10.110-rt53-rockchip-rk3588': 'postrm' finishing.[b]cp: cannot stat '/boot/vmlinuz-5.10.110-rockchip-rk3588': No such file or directory[b]dpkg: error while cleaning up:[b] installed linux-image-legacy-rockchip-rk3588 package post-installation script subprocess returned error exit status 1[b]Errors were encountered while processing:[b] linux-image-legacy-rockchip-rk3588_23.05.0-trunk--5.10.110-rt53-Scbae-De8b2-Pc4e1-Caa25Hfe66-Vc222-Be9aa_arm64.deb

I haven't had much luck building my own image either, at first I tried building the an image from a virtualbox on my Laptop. I'm running Manjaro so I needed a VM or Ubuntu to run the build. It seemed to have worked, I have replaced the two config files in there respective places in the build directory. Though for some reason I do not get a boot image created, only deb files in the output directory.  I tried doing a kernel build on the Orange Pi following the instructions from Armbian's website. Again replacing the two .conf files and running the compile.sh script. Unfortunately, on the Orange pi only a u-boot deb package is made. I've made sure to follow every step correctly, searched the net to find answers on what I am doing wrong but I'm just not having any luck what so ever.
Last edit: 09 Apr 2023 04:59 by kanuboy13b.

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

More
09 Apr 2023 14:25 #268675 by royka
I've just tried it on a clean image and got the same error indeed, I will look at it later.

At the moment you could install it by forcing it:
sudo dpkg -i --force-all linux-image-legacy-rockchip-rk3588_23.05.0-trunk--5.10.110-rt53-Scbae-De8b2-Pc4e1-Caa25Hfe66-Vc222-Be9aa_arm64.deb

For the headers you'll need:
sudo apt install python3-venv python-is-python3
sudo apt install ./linux-headers-legacy-rockchip-rk3588_23.05.0-trunk--5.10.110-rt53-Scbae-De8b2-Pc4e1-Caa25Hfe66-Vc222-Be9ac_arm64.deb

Then add the following line to /boot/armbianEnv.txt
extraargs="isolcpus=5,7"
 

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

More
09 Apr 2023 18:53 - 09 Apr 2023 19:10 #268702 by royka
It seems Armbian doesn't like local versions, so I created a patch which you could put in the folder like in the zip.
I just created a minimal image without problems.

Only the main branch builds it, the master branch fails.

If you only want to install the kernel with that wifi driver, this one you should be able to install with sudo apt install ./linux-image*.deb:
filebin.net/lpleuciilara5q60/linux-image...c222-Be9aa_arm64.deb
 
Attachments:
Last edit: 09 Apr 2023 19:10 by royka.

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

More
09 Apr 2023 19:50 #268704 by kanuboy13b
this did the trick,
reflashed the sd card with a fresh armbian, ran sudo apt update
installed both python3-venv and python-is-python3 successfully, trying this before the apt update would error.

I was able to get the rt kernel to install using the --force-all flag. no errors
ran the sudo apt install on the header package and installed without issue. it did give an error at the end, but from what I understand its an error that can be largely ignored.
rebooted the OP5 and ran neofetch in the terminal and there it was, linux5.10.110-rt53 as the kernel. Plus the USB wifi works as well.
Everything looks in order

I've installed LinuxCNC from the packages you provided, going to run some latency tests in a bit.

Next item on my wishlist is to migrate everything to boot off of a nvme ssd drive, then I think I am set.
The following user(s) said Thank You: royka

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

More
09 Apr 2023 20:06 - 09 Apr 2023 20:17 #268708 by royka
To install to the nvme you'll only need:
sudo armbian-install --> choose "Boot from MTD flash - system on..."
At the end it will ask to install/update the bootloader on MTD flash, answer yes, then it will take a few minutes and it should be bootable from nvme.

There is a chance that it will fail to install the bootloader with the kernel that has the local version at -rt53. To be sure you could first install the latest version I'd uploaded. (or build your own with the patch added). With the local version removed you won't see rt53 in neofetch, but you should check: cat /proc/version

And don't forget to isolate core 5 and 7 for best results.
echo "extraargs="isolcpus=5,7"" | sudo tee -a /boot/armbianEnv.txt
Last edit: 09 Apr 2023 20:17 by royka.

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

More
14 Apr 2023 22:04 #269042 by royka
Did it work for you? If so it would be nice if you post your results

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

More
15 Apr 2023 07:18 #269061 by Guglielmi
Hi Royka, I also tried using debs file and the installation finished correctly, latency around 0,7 - 1 us!
I'm fighting now on a issue related to LinuxCNC: Launching the application, it starts but ends immediately because no configurations found.
So I recovered default samples and applied in the folder "/usr/share/doc/linuxcnc".
The issue is that creating a simulation config, it starts, I can see the small window for tool bottom (after few second disappears.. normal) but the main window for "Axis" is not showed! LinuxCNC seems running in background becasue if I try to call again a message tell me that still running..
Now I try to play around the configuration because the copy I did from my RPI installation was not done fully.. where it found a link the file was skipped so not sure it could work.
So now my doubt is: additional package missing for visualization, or just issue in configuration?
I will keep a default sim config Axis from another installation and try.. 

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

More
15 Apr 2023 09:57 #269084 by Guglielmi
I copied now correctly default configurations compressing folder, so links were preserved. I tried to import anyhow an axis.sim default confiugration but nothing, I can't see the GUI of axis, it still running on background, no errors...
I also tried to disable the 3d acceleration but did not solved.
What missing tool could cause Axis GUI not showed but running in background?

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

More
15 Apr 2023 10:15 #269091 by royka
Easies way of getting the config files would've been:
git clone github.com/LinuxCNC/linuxcnc.git --branch 2.9
But strange it didn't package the config files, perhaps a config option I didn't see.

The error I could reproduce, when I launch it from terminal it gives the error: DRM_IOCTL_PANFROST_CREATE_BO failed: Cannot allocate memory

I'll look into it
The following user(s) said Thank You: Guglielmi

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

More
15 Apr 2023 13:50 - 15 Apr 2023 13:52 #269104 by royka
It's obvious something with the panfork driver, I can't find a solution for that. What does work is using the mali blob driver instead of panfork.
github.com/numbqq/mali-debs/tree/master/.../arm64/Edge2/wayland

Not sure if this will work after installing panfork mesa, it might be necessary to do a clean install.
With this driver firefox works fine under wayland
"sudo apt install firefox-esr"

To install gnome I'd to remove xfce because this conficted with gdm3 somehow, in case you're getting the same error you could just run this command in a terminal in xfce "sudo apt remove armbian-jammy-desktop-xfce" and install gnome right after it.

With the mali-wayland blob, gnome and firefox installed, LinuxCNC works fine.

Sorry for wasting your time with the wrong advice of installing panfork, should have test it better.
Last edit: 15 Apr 2023 13:52 by royka.

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

Time to create page: 0.191 seconds
Powered by Kunena Forum