FreeCAD and Raspberry Pi 4

This subforum is specifically to discuss packaging issues on different platforms (windows, mac, linux), and using different packaging systems (conda, etc...)
User avatar
-alex-
Posts: 508
Joined: Wed Feb 13, 2019 9:42 pm
Location: France

Re: FreeCAD and Raspberry Pi 4

Postby -alex- » Tue May 19, 2020 6:46 am

RustyM wrote:
Fri May 15, 2020 5:21 pm
Thanks again, alex, for giving me hope. Fingers crossed.
Hi RustyM, sorry for late reply. Kkremitzki told you better than I could, I'm just an end user who had compiled FreeCAD with great help from Freecadian mates ;)
I added some commands which were missing in my post above, please have a look at it. Hope it helps a bit. RPI4 is a single board computer, you and me we have the same hardware, only gnome desktop is diffrent compare with my installation. I hope you will success, please report here ;)
User avatar
RustyM
Posts: 7
Joined: Tue Aug 13, 2019 12:27 am

Re: FreeCAD and Raspberry Pi 4

Postby RustyM » Thu May 21, 2020 1:08 pm

Very pleased to report a successful build!

Pi4 4G with Ubuntu 20.04 LTS 64-bit (installed via Raspberry Pi Imager) and the gnome minimal desktop. Not sure how long it took, but it was definitely more than 4 hours. The Pi did not seem to heat up much, but I have it in a Canakit case with fan.

Many thanks to @kkremitzki and to @Alex and all the giants on whose shoulders he claims to have stood.

Notes for other newbs like me: I may have done three or four complete installs of Ubuntu before I felt confident. It always seemed to get a little weird after installing a GUI. ubuntu-desktop-minimal felt solid immediately, and has plenty of features.

Also, in my previous efforts to install the dependencies I would swear that it installed all the modules listed on the command line, reporting back about the ones it couldn't find. This time, however, if there were any modules that apt couldn't find, it simply aborted the process, reporting on the unfound modules, but NOT installing the others. I ended up taking apart @Alex's excellent dependency list, and installing it four or five modules at a time, carefully avoiding the ones that couldn't be found.

Performance is somewhat sluggish compared to my 2014 Powerbook. I haven't tried anything very complex yet, but it's remarkable to have this kind of capability from a Pi. Many thanks to the FreeCAD team!
User avatar
-alex-
Posts: 508
Joined: Wed Feb 13, 2019 9:42 pm
Location: France

Re: FreeCAD and Raspberry Pi 4

Postby -alex- » Thu Jun 11, 2020 5:29 pm

RustyM wrote:
Thu May 21, 2020 1:08 pm
Performance is somewhat sluggish compared to my 2014 Powerbook. I haven't tried anything very complex yet, but it's remarkable to have this kind of capability from a Pi.
Glad you can enjoy FreeCAD on RPI4 :D
About performance, yes it's quite sluggish on Ubuntu, because graphics are not GPU accelerated with this OS:

Code: Select all

ubuntu@ubuntu:~$ glxinfo | grep rendering
direct rendering: Yes
ubuntu@ubuntu:~$ glxinfo | grep OpenGL
OpenGL vendor string: VMware, Inc.
OpenGL renderer string: llvmpipe (LLVM 9.0.1, 128 bits)
OpenGL core profile version string: 3.3 (Core Profile) Mesa 20.0.4
OpenGL core profile shading language version string: 3.30
OpenGL core profile context flags: (none)
OpenGL core profile profile mask: core profile
OpenGL core profile extensions:
OpenGL version string: 3.1 Mesa 20.0.4
OpenGL shading language version string: 1.40
OpenGL context flags: (none)
OpenGL extensions:
OpenGL ES profile version string: OpenGL ES 3.1 Mesa 20.0.4
OpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.10
OpenGL ES profile extensions:
AFAIK "OpenGL renderer string: llvmpipe" means graphical computation by CPU :|
Anyway, FreeCAD with Ubuntu 20.04LTS is pretty cool :)
That say, there is good news about FreeCAD and Raspbian, see next post :arrow:
User avatar
-alex-
Posts: 508
Joined: Wed Feb 13, 2019 9:42 pm
Location: France

Re: FreeCAD and Raspberry Pi 4

Postby -alex- » Thu Jun 11, 2020 6:38 pm

That's it, FreeCAD compiled with QT5 and PY3 works on RPI4 with Raspberry OS64B (beta test version) :!:
Many thanks to user @leggazoid for this information: https://www.raspberrypi.org/forums/view ... d#p1674736
I confirm, FreeCAD works like a charme, with GPU acceleration.
So, RPI4 is ready to welcome FreeCAD 0.19 QT5/PY3 with great features and direct rendering:

Code: Select all

pi@raspberrypi:~ $ glxinfo | grep rendering
direct rendering: Yes
pi@raspberrypi:~ $ glxinfo | grep OpenGL
OpenGL vendor string: Broadcom
OpenGL renderer string: V3D 4.2
OpenGL version string: 2.1 Mesa 19.3.2
OpenGL shading language version string: 1.20
OpenGL extensions:
OpenGL ES profile version string: OpenGL ES 3.1 Mesa 19.3.2
OpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.10
OpenGL ES profile extensions:
As a result, it is possible to rotate the 27K cubes model at about 6FPS and 1920x1080 resolution:
Cube_27K_RPI4_OS64B.gif
Cube_27K_RPI4_OS64B.gif (891.45 KiB) Viewed 182 times
(shaking is due to gif capture)
When loading this model made of 27K cubes:
Just RPI OS64B, no any software launched: RAM = 160Mo
Run FreeCAD: RAM = 252Mo
27K cubes loaded (needs about 1 or 2mn to load): RAM = 3.1Go
No more to say about this pretty huge test model.
If you increase too much angular deflection (2°) and deviation (0.2) with a spherical or toroidal model, crash may occur with segfault issue.
Anyway, if you load an usual model, it rotates at 20 or 30 fps, very smouthly, no problem.
Some troubles with File icons, that's not a big deal. Maybe you can load the Icon addon to solve that. Have to try...
If you want to compile it, just follow the Compile_on_Linux Debian instructions.
If you want to mesh FEM models with gmsh you should install it:

Code: Select all

sudo apt install gmsh
Enjoy FreeCAD on RPI4 with Raspberry OS64Bit :D

Edit:
OS: Debian GNU/Linux 10 (buster) (LXDE/LXDE-pi)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.21562 (Git)
Build type: Unknown
Branch: master
Hash: 11a2b948ea55b19efe7515f730035027a7822e06
Python version: 3.7.3
Qt version: 5.11.3
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: French/France (fr_FR)
Last edited by -alex- on Fri Jun 12, 2020 11:32 pm, edited 3 times in total.
User avatar
papy
Posts: 157
Joined: Sun Sep 09, 2018 10:00 am
Location: Moselle

Re: FreeCAD and Raspberry Pi 4

Postby papy » Thu Jun 11, 2020 7:14 pm

Hi
For once, I will use French:
Merci Alex