Last update of LinuxCNC Raspberry Pi4 USB does not work

More
17 Jan 2021 13:43 #195661 by pauluzs

Have seen that repoitory only thing : Isn't the main Pi repository 32 bit?


The Pi repository can be compiled for any architecture (including RISC and MIPS). I compiled an arm64 kernel yesterday using it, but it won't install as even a Pi set up with a (stock) 64 bit kernel has a 32-bit userspace and rejects an arm64 kernel deb.

tried that at first also with a fail, seems you need a running arm64 kernel to install the rt-kernel


The Pi4 is arm64 bits and i wanted to skip compiling a whole new kernel for that and rather take the shortcut.


LinuxCNC does not really benefit from 8GB of memory. (And, as the LinuxCNC armhf image is 32 bits, couldn't use it anyway)

uname -a
Linux rpi4-20201112 5.9.0-0.bpo.5-rt-arm64 #1 SMP PREEMPT_RT Debian 5.9.15-1~bpo10+1 (2020-12-31) aarch64 GNU/Linux


Does Linuxcnc install and run (in realtime) on that system?

yes i did manage to compile linuxcnc master from source and run it on that kernel
Haven't looked into latency that much but fixed that display problem first

Also tried to compile a new kernel with your recommended settings from menu-config but failed on dependencies
To be straight up i'm no genius at compiling new kernels so that will take some more tries




My understanding (possibly wrong) is that the Pi kernel has significant differences from a vanilla arm kernel, which is why we have been working with the forked Pi kernel sources.


These images seem to be as close to stock debian as can be with only the nessesary extra firmware, specific for the pi.

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

More
17 Jan 2021 14:18 - 17 Jan 2021 14:18 #195664 by andypugh

Does Linuxcnc install and run (in realtime) on that system?

yes i did manage to compile linuxcnc master from source and run it on that kernel


To be generally usable, the kernel needs to work with the LinuxCNC packages from the buildbot.

The point of making kernel and application packages is so that users don't have to compile from source.
Last edit: 17 Jan 2021 14:18 by andypugh.

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

More
17 Jan 2021 15:33 #195676 by pauluzs


To be generally usable, the kernel needs to work with the LinuxCNC packages from the buildbot.

The point of making kernel and application packages is so that users don't have to compile from source.


The buildbot is not setup to a create buster arm64 packages, , only ( Buster (arch: amd64) )
So using the buildbot packages is not possible

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

More
17 Jan 2021 15:44 #195678 by andypugh

The buildbot is not setup to a create buster arm64 packages, , only ( Buster (arch: amd64) )
So using the buildbot packages is not possible


Yes, that's my point.

The LinuxCNC-served kernel .deb needs to be compatible with the LinuxCNC-served package.

Or, alternatively, we give up.

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

More
18 Jan 2021 18:36 - 18 Jan 2021 18:37 #195815 by pauluzs


Yes, that's my point.

The LinuxCNC-served kernel .deb needs to be compatible with the LinuxCNC-served package.

Or, alternatively, we give up.


Not sure what you mean with LinuxCNC-served kernel .deb, i'm using the standard vanilla debian buster kernel optional with linux-image-rt-arm64 Also from vanilla debian (backports)
Giving up because the buildbot doesn't build the arm64 packages is like the chicken vs egg question. i don't manage the buildbot.

That being said, explaning :

i did manage to compile linuxcnc master from source

What i did is build the userspace .deb packages for master and 2.8
This works on normal (sim), as well as the realtime kernel
linuxcnc-doc-cn_2.8.1_all.deb
linuxcnc-doc-cn_2.9.0~pre0_all.deb
linuxcnc-doc-en_2.8.1_all.deb
linuxcnc-doc-en_2.9.0~pre0_all.deb
linuxcnc-doc-es_2.8.1_all.deb
linuxcnc-doc-es_2.9.0~pre0_all.deb
linuxcnc-doc-fr_2.8.1_all.deb
linuxcnc-doc-fr_2.9.0~pre0_all.deb
linuxcnc-uspace-dbgsym_2.8.1_arm64.deb
linuxcnc-uspace-dbgsym_2.9.0~pre0_arm64.deb
linuxcnc-uspace-dev_2.8.1_arm64.deb
linuxcnc-uspace-dev_2.9.0~pre0_arm64.deb
linuxcnc-uspace_2.8.1_arm64.deb
linuxcnc-uspace_2.9.0~pre0_arm64.deb

These can then be installed just like a distrubuted buildbot .deb linuxcnc package

Here is how:
#fix missing python-gtksourceview2 for buster
	sudo apt install wget -y 
	wget http://ftp.debian.org/debian/pool/main/p/pygtksourceview/python-gtksourceview2_2.10.1-3_arm64.deb
	sudo apt install ./python-gtksourceview2_2.10.1-3_arm64.deb
	rm python-gtksourceview2_2.10.1-3_arm64.deb
#Install devscripts, used to build .deb packages
	sudo apt install devscripts -y	

#Get linuxcnc source
	git clone git://github.com/linuxcnc/linuxcnc.git linuxcnc-dev
#Change into linuxcnc-dev directory
	cd linuxcnc-dev
#Select linuxcnc branch (master, 2.8)
	git checkout master
	git branch
#Configure linuxcnc uspace	
	./debian/configure uspace
#build and install the build dependencies .deb package
	sudo mk-build-deps -i
#Build the .deb  package for linuxcnc
	dpkg-buildpackage -b -uc	
#Install the created linuxcnc .deb package
	sudo apt install ../linuxcnc-uspace_2.9.0~pre0_arm64.deb	

If there is a need for a seperate arm64 topic for this let me know
Last edit: 18 Jan 2021 18:37 by pauluzs.

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

More
18 Jan 2021 21:44 - 18 Jan 2021 21:46 #195837 by andypugh

Giving up because the buildbot doesn't build the arm64 packages is like the chicken vs egg question. i don't manage the buildbot.


The buildbot is fairly deeply embedded in how we test and release the packages. Unfortunately the chap who runs it is not as deeply involved in the project as he used to be.

I want to stay with the buildbot-created debs as that is how we can be sure that updates and fixes get properly distributed.

I have had some success with the LinuxCNC/raspberry-linux repository and the SD-card install instructions here:
www.raspberrypi.org/documentation/linux/kernel/building.md

I suspect that the debian packages made by that repository do not copy across all the files that the manual process does.



(This is with a brand-new 2GB Pi4. Maybe I should have got the 8GB one to be a better test, but it is just that bit too expensive a thing for me to buy without needing.)

Attachments:
Last edit: 18 Jan 2021 21:46 by andypugh.

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

More
18 Jan 2021 22:22 - 18 Jan 2021 23:15 #195843 by pauluzs

I suspect that the debian packages made by that repository do not copy across all the files that the manual process does.


Which one do you mean with "that repository "?

(This is with a brand-new 2GB Pi4. Maybe I should have got the 8GB one to be a better test, but it is just that bit too expensive a thing for me to buy without needing.)


True, using bone stock 5.9 arm64 realtime kernel, only thing i did is force_turbo=1 to prevent cpu-scaling.
This is 2 min run on rpi4_4GB
Attachments:
Last edit: 18 Jan 2021 23:15 by pauluzs.

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

More
19 Jan 2021 01:19 #195851 by andypugh
Well, I am confused now.

Intending to investigate the effect of limiting memory to 3GB I made a new standard 32-bit SD card image, booted my new 2GB Pi4 (bought specifically to debug this reported issue) and followed the instructions here in the LinuxCNC docs:
linuxcnc.org/docs/2.8/html/getting-start...lling_on_raspbian_10
Contrary to the reports in this and other threads, it all "just worked".

I moved the SD card to my Pi400, and that worked, and then to my old 4GB Pi4, and that worked.

Is there _actually_ a problem?

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

More
19 Jan 2021 02:31 - 19 Jan 2021 02:57 #195863 by pauluzs
Let me try to confuse you some more ... ;)

Can you run apt-get update and apt-get upgrade on that 4GB?

That was where it went wrong before for me. Fresh install usb works, after running update/upgrade it stopped (without the 3GB limit linux-image-4.19.71-rt24-v7l+ 3-sept eeprom)

If yours keeps working (with 3GB limit linux-image-4.19.71-rt24-v7l+) then all seems fine for the 32 bit image.

However if that memory limit is needed, why buy anything else than a 2GB to start with? Seems to me that 3GB limit comes from the 32bit arch in the first place.(early 2000's flashbacks)

So instead of limiting a 64bit cpu to a 32bit OS, and consequently also limiting it's memory <4GB,. My approach was to use arm64 bit from the start. Not only the rpi also other sbc's, android devices and ie chromebooks run arm64.
Last edit: 19 Jan 2021 02:57 by pauluzs.

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

More
19 Jan 2021 02:56 #195865 by alkabal
Hi

Just tried with fresh official debian 32bits using the guide and sdcard
linuxcnc.org/docs/2.8/html/getting-start...lling_on_raspbian_10

After rebooting on the 6e step, no more usb no keyboard/touchscreen.

only using apt-get update

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

Time to create page: 0.125 seconds
Powered by Kunena Forum