Raspberry Pi Zero Support in 0.4

Raspberry Pi related support

Re: Raspberry Pi Zero Support in 0.4

Postby gearhead » 03 Mar 2018, 23:53

Wow, What a morning/afternoon... A couple notes for anyone else trying this image on a Zero W.

1) the image OS is structured a bit differently than I expected on the disk and a resize from addons will not work. (actually it scrambles it) D'oh. Boot is P1 but root is p5 in an extended partition. I burned the image to a 16gb SD card, copied the P5 partition to the unformated space, deleted the extended partition and P5 in it, (now have P3 Primary partition next to it) then copied P3 again to where the extended partition was then deleted P3. This way, I have P1 (dos) and P2 (ext4) like the current, standard ArchArm setup
2) I added "ipv6.disable=1" to the cmdline (this allows AP mode to begin at startup if there is not a netctl profile set up in redis dbase - slick)
3) removed the soxr reference from redis "redis-cli hdel mpdconf soxr" (mpd.service will not start with 0.4b with this set)
4) I deleted the UI files and pulled from git Franks 0.4b RuneUI
5) installed sudo (pacman -Sy sudo) so that I can run addons
6) booted it up, expanded the partition, installed addons, installed my radios, fixed shairport-sync to be default (runeaudio.php and rune_SY_wrk edited)

Now this replaces the brain dead processor on my Sony NS400 speaker! Woo Hoo!!

If anyone wants me to tweak this image to have all these things, I can do that...
gearhead
 
Posts: 88
Joined: 25 Nov 2014, 06:04

Re: Raspberry Pi Zero Support in 0.4

Postby janui » 04 Mar 2018, 00:58

Hi gearhead,
Nice job. I would really appreciate it if you could post a version after point 1 and after point 4. Also the files edited in point 6 would be interesting (runeaudio.php and rune_SY_wrk).
In addition to what you have. You can apply the following upgrades:
Code: Select all
pacman -Sy ncurses
pacman -Sy ffmpeg fribidi libdrm libmpdclient libtheora libva libvpx libxdamage mesa mpc mpd v4l-utils wavpack zziplib
pacman -Sy --force audiofile curlftpfs dosfstools e2fsprogs exfat-utils filesystem nfs-utils nfsidmap ntfs-3g samba sshfs
Upgrading ncurses is important, do this even if you decide not to upgrade the rest.
The second line wil upgrade mpd to 0.20.18 and upgrade all dependencies. Unfortunately still no Native DSD available.
The third line will upgrade packages relating to the file system which provide performance improvements.
Do not pacman -Syu, tried this, waste of time.
janui
User avatar
janui
 
Posts: 261
Joined: 20 Dec 2014, 12:55
Location: Ollanda

Re: Raspberry Pi Zero Support in 0.4

Postby gearhead » 04 Mar 2018, 05:48

I am uploading a version after step 5. I did not get this message until after I did all that and don't want to go back. IMO, we should be using Frank's latest 0.4b. It has been stable for me. It works with the addons from rern. I think it is a decent basis and still do not know what happened to my image after it loaded on a ZeroW. It just went crazy. This one is works. I edited the cmdline.txt as well as config.txt so that it works with Frank's 0.4b UI. You can set the audio card from the UI and reboot and then select it from the MPD page. I do not know how shuffle works as I did not test it. Do with it as you wish... As it is, when put in a ZeroW, it will boot and then eventually go into AP mode and advertise like Frank posts. I did not add the alsamixer web page to it and did not update MPD or anything else. When I get the link from Google, I'll post it here. Man that was a lot of work!

Gearhead

Link:
https://drive.google.com/open?id=1qRDQ2 ... JIyVRtNgcC
MD5 sum of gz is: 1e2703f66c4076cd9ca694fdedc22940

Edit: I almost forgot. When I updated the UI with Frank's git, it replaced the mpd.service file. It has some lines in it that cause mpd to not start. I commented those out to allow it to start. This may be a problem in the future if you wipe our the UI files and replace it. It will then again replace that mpd.service file, mpd will not start and will then need to be edited again. I tried to update mpd with one I compiled (with dsd dupport), but could not and gave up. Pacman would just not do it. I do not know why.

This is the snippet of the mpd.service file that works:
Code: Select all
...
# more paranoid security settings
NoNewPrivileges=yes
#ProtectKernelTunables=yes
#ProtectControlGroups=yes
#ProtectKernelModules=yes
# AF_NETLINK is required by libsmbclient, or it will exit() .. *sigh*
RestrictAddressFamilies=AF_INET AF_INET6 AF_UNIX AF_NETLINK
#RestrictNamespaces=yes
...
gearhead
 
Posts: 88
Joined: 25 Nov 2014, 06:04

Re: Raspberry Pi Zero Support in 0.4

Postby adrii » 18 Apr 2018, 15:58

I am new to RuneAudio. I installed the image posted earlier in the thread, in this post
http://www.runeaudio.com/forum/raspberry-pi-zero-support-in-0-4-t3711-70.html#p20577
on a Raspberry Pi Zero W.

I tried to install GCC with 'pacman -S gcc', but when I try to build a program I get
Code: Select all
[root@runeaudio proj]# gcc -o hello hello.c
/usr/lib/gcc/armv6l-unknown-linux-gnueabihf/7.2.1/cc1: error while loading shared libraries: libmpfr.so.6: cannot open shared object file: No such file or directory

I appear to have a different version of the library installed
Code: Select all
[root@runeaudio proj]# find / -iname "libmpfr*"
/usr/lib/libmpfr.so.4.1.2
/usr/lib/libmpfr.so
/usr/lib/libmpfr.so.4


What should I do to get GCC working?

Thanks

Adrian.
User avatar
adrii
 
Posts: 15
Joined: 17 Apr 2018, 11:03

Re: Raspberry Pi Zero Support in 0.4

Postby gearhead » 18 Apr 2018, 17:55

To compile anything, you need an updated system. If you update RuneAudio, you will break many things which have been tweaked to work on this system as, basically, an appliance. If you truly want to develop (build) on a RPi, I recommend you make a new/fresh image of Arch, build what you want on that image then copy it to RuneAudio if you want to test things.

What happened is you installed the current, new, gcc and it needs certain libraries. The version of these libraries on the RuneAudio image is a 4.xx and gcc is looking for a 6.xx.

If you are truly trying to compile on a Zero, it will be quite slow. I recommend buying a Pi3+ and making a chroot of armv6 if you want to develop small programs for the Zero. This is reasonably snappy, and can be enhanced when you use distccd running on a desktop somewhere on your network. Faster yet is to make a cross compiler on a desktop to compile programs.
gearhead
 
Posts: 88
Joined: 25 Nov 2014, 06:04

Re: Raspberry Pi Zero Support in 0.4

Postby adrii » 18 Apr 2018, 18:59

Thanks for your help.

I have made an OLED display program for Volumio that will work, with minor changes, with RuneAudio
https://github.com/antiprism/vol_oled
https://youtu.be/6pgxGQIAX9s


I was hoping to make those changes and test the program on RuneAudio, and then provide build and installation instructions. However, from what you say, it will not be realistic for RuneAudio users to build the software, and so will require extra effort to make it available.

Adrian.
User avatar
adrii
 
Posts: 15
Joined: 17 Apr 2018, 11:03

Re: Raspberry Pi Zero Support in 0.4

Postby gearhead » 18 Apr 2018, 19:09

Adrian,

Looks great! What you could do is make a package and compile it yourself and put it in your github repository for others to install.

Arch linux uses 'packages', not rpm or deb. if you set it up and compile a package, it could be installed by users. You would need to set up a compile machine and compile it, though. If you are still interested, you may want to look at how to construct a PKGBUILD file to build an arch linux package, test it out on your hardware and then release it for the community...

Gearhead
gearhead
 
Posts: 88
Joined: 25 Nov 2014, 06:04

Re: Raspberry Pi Zero Support in 0.4

Postby adrii » 18 Apr 2018, 20:57

Hi Gearhead

Thanks for the suggestions. I have just had a look at using Clang for the build. I was able to build Cava (audio spectrum analyser) with it. I will look at the rest of the build and installation tomorrow.

Adrian,
User avatar
adrii
 
Posts: 15
Joined: 17 Apr 2018, 11:03

Re: Raspberry Pi Zero Support in 0.4

Postby adrii » 29 Jun 2018, 10:53

Hi

I wanted to to test the latet changes to my OLED display program on RuneAudio. I no longer had RuneAudio on an SD card so I reinstalled using the image from raspberry-pi-zero-support-in-0-4-t3711-70.html#p20577

I can install some of the packages I need using 'pacman', but I am no longer able to install the Clang package to build the program
Code: Select all
pacman -S clang
resolving dependencies...
looking for conflicting packages...

Packages (5) binutils-2.29.1-2  gcc-7.2.1+20180116-1  gcc-libs-7.2.1+20180116-1
             libmpc-1.1.0-1  clang-4.0.1-5

Total Download Size:    34.50 MiB
Total Installed Size:  359.99 MiB
Net Upgrade Size:      291.96 MiB

:: Proceed with installation? [Y/n]
:: Retrieving packages...
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from it.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from nl.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from hu.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from fr.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from eu.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from de6.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from de5.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from de3.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from de4.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from de.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from fi.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from de.us.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from ru.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from fl.us.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from ca.us.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from gr.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from il.us.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from mi.us.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from br2.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from sg.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from tw.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from au.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from vn.mirror.archlinuxarm.org : The requested URL returned error: 404
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from za.mirror.archlinuxarm.org : Connection timed out after 10001 milliseconds
error: failed retrieving file 'clang-4.0.1-5-armv6h.pkg.tar.xz' from co.us.mirror.archlinuxarm.org : Connection timed out after 10001 milliseconds
warning: failed to retrieve some files
error: failed to commit transaction (download library error)
Errors occurred, no packages were upgraded.

Could it be that the image is too old now, and the clang package version it wants to install is no longer available on the servers?

Is it possible for me to install a C++ compiler package by some other means?

Adrian.
User avatar
adrii
 
Posts: 15
Joined: 17 Apr 2018, 11:03

Re: Raspberry Pi Zero Support in 0.4

Postby gearhead » 29 Jun 2018, 14:02

Adrian,

Try "pacman -Sy". This will update the package list. then try to install the package. This may hose the image, but it is worth a try.

Keith
gearhead
 
Posts: 88
Joined: 25 Nov 2014, 06:04

support RuneAudio Donate with PayPal

PreviousNext

Return to Raspberry Pi

Who is online

Users browsing this forum: No registered users and 1 guest