• Disclaimer: This Vendor's Forum is a paid-for commercial area. Unlike the rest of diyAudio, the Vendor has complete control of what may or may not be posted in this forum. If you wish to discuss technical matters outside the bounds of what is permitted by the Vendor, please use the non-commercial areas of diyAudio to do so.

Support for Botic Linux driver

Hi miero. Just wondering if you have any update regarding my request for a mute trigger to be exposed on the BBB headers by Botic.
Hi,
try this on BBB with botic:
Code:
cd /lib/modules/4.5.0-botic7-rc1/kernel/sound/soc/davinci
mv snd-soc-davinci-mcasp.ko snd-soc-davinci-mcasp.ko.orig
wget [URL]http://bbb.ieero.com/botic7-rc1/snd-soc-davinci-mcasp.ko[/URL]

reboot BBB now and after reboot verify that new module is loaded

Code:
cat /sys/module/snd_soc_davinci_mcasp/parameters/mute_pins
this should report 0

then set this parameter to value 12 to enable non-inverted mute on the 2 and 3 output pins:
Code:
echo 12 > /sys/module/snd_soc_davinci_mcasp/parameters/mute_pin
This requires to have disabled the last two serializers:
Code:
echo MD-- > /sys/module/snd_soc_botic/parameters/serconfig

Now play some sound to apply mute and then stop.

After start/stop there should appear a mute pin on D5 output pin of Cronus. There is (isolated) 3.3V on it if stopped, and with 0V during a playback. You can try to use it as mute.

Tthe muting both 2+3 outputs is needed using Hermes-BBB, because D5 gets switched from 2 or 3 BBB pins depending on the PCM/DSD playback mode.

Supported values for mute_pins (they are additive):
+ 1 ... pin 0
+ 2 ... pin 1
+ 4 ... pin 2
+ 8 ... pin 3
+ 16777216 ... invert the mute signal

Please report if it works fine ... please check both DSD & PCM playback modes if possible.
 
Many thanks miero.

I am away on a course all week and I won't be able to test this until I get back but will report my findings in due course.

Cheers

Ray

Hi,
try this on BBB with botic:
Code:
cd /lib/modules/4.5.0-botic7-rc1/kernel/sound/soc/davinci
mv snd-soc-davinci-mcasp.ko snd-soc-davinci-mcasp.ko.orig
wget [URL]http://bbb.ieero.com/botic7-rc1/snd-soc-davinci-mcasp.ko[/URL]

reboot BBB now and after reboot verify that new module is loaded

Code:
cat /sys/module/snd_soc_davinci_mcasp/parameters/mute_pins
this should report 0

then set this parameter to value 12 to enable non-inverted mute on the 2 and 3 output pins:
Code:
echo 12 > /sys/module/snd_soc_davinci_mcasp/parameters/mute_pin
This requires to have disabled the last two serializers:
Code:
echo MD-- > /sys/module/snd_soc_botic/parameters/serconfig

Now play some sound to apply mute and then stop.

After start/stop there should appear a mute pin on D5 output pin of Cronus. There is (isolated) 3.3V on it if stopped, and with 0V during a playback. You can try to use it as mute.

Tthe muting both 2+3 outputs is needed using Hermes-BBB, because D5 gets switched from 2 or 3 BBB pins depending on the PCM/DSD playback mode.

Supported values for mute_pins (they are additive):
+ 1 ... pin 0
+ 2 ... pin 1
+ 4 ... pin 2
+ 8 ... pin 3
+ 16777216 ... invert the mute signal

Please report if it works fine ... please check both DSD & PCM playback modes if possible.
 
If you have a time you can waste, you can try my experiment to port Volumio 2.0 from rPI to BBB. BIG NOTICE, it is destined to be non-supported. You need a 4GB SD card to test this.

After BBB boots with it, try to open the web interface [let's hope it will start] and switch off run-time conversion to DSD (BBB is slow for it).

Update the clk_44k1/clk_48k parameters via SSH if needed.

Try to load music [or install Spotify plugin] and try if it plays.

SD Image can be found here: Index of /botic7-rc1/volumio

----
Ultra brief details what have I done:
- use BBB bootloader from debian and extracted volumio data to ext4 fs
- removed their kernel and updater(!!!)
- changed its /etc/fstab to root be writable
- added botic7-rc1 kernel + larger buffer for DSD mod
:eek: Hi miero
Thank for your botic kernel,
I try your image and in the console I can login volumio, it's have IP but when I connect to that IP then the browser say unable to connect?, is it some thing wrong with web daemon?
 
Hi mikelangeloz,
Thank for your great work.
I success build the image of volumio 2 for BBB but when I install in SD Card and it's seem not running ( it's back to default OS of beaglebone). I will check the output of console later.
And I have another issue is when using BBB with Volumio 1.5 then the I2S output is only 48kHz ( also when I play with 192kHz) and I don't know how to change it's. It's also always 32 bit per sample in oscilloscope and sample frequency is 48kHz.
Can you teach me how to see what happen here by using SSH?
:D
Thank a lot
It is expected to not work, because it is not yet prepared for BBB. I'm working on it right now. It's almost prepared, but I need to test it first. Stay tuned... :)
 
I just configured BBB/botic + Synology NAS + Android tablet running MPDroid.
I offer the following tips for anyone attempting similar:

RE MPD clients on separate devices (BitMPC, MPDroid, MPaD, MPDRemote etc)
botic's MPD configuration file, /etc/mpd.conf, contains this line -
bind_to_address “localhost”
which is fine for on-device client applications such as ympd, but it won't work for clients on separate devices (and separate IP addresses). To fix, change to -
bind_to_address “any”

RE accessing music files on a NAS
when configuring botic's /etc/fstab for a cifs share, you should add the parameter iocharset=utf8 - this will enable the NAS to export non-English characters to MPD on botic.
I discovered this when an album in my collection called "Café Blue" failed to appear in the MPDroid album list. Something as simple as an e-acute was unable to be read by MPD, and the album was not accessible. Adding the utf8 parameter fixed this.
And for completeness, you should also add "0 0" at the end of the cifs configuration line - the first zero disables backing up of the device/partition, and the second zero disables fsck error checks. Both of these maintenance tasks should be handled by the NAS, itself.
 
Member
Joined 2004
Paid Member
For a while I've been using this version without any problems. I2C control of B3SE from BBB-Hermes works fine. The SQ via MPD is quite stable. Currently I'm running this version on a debian stretch distro with newly compiled MPD-0.18.23-dsd-rt and MPD-19.19 (patched with realtime option), both capable of playing native DSD512 sources.

Hi twluke and others, did you compare the MPD 18.23 build with the 19.19 and heard differences? Did you by chance also tried one MPD version without realtime patch? I just read a developer's comment in the official MPD wiki that realtime isn't improving sound (how should this work, btw?) and that it's just possibly helping if there is a high CPU load with lot's of other programs. I'm really curious, because if both versions play also DSD512, than we can now just install Debian Stretch (plus Miro's work), that's it. This would be so easy and this just works! Regards, Matthias
 
Hi twluke and others, did you compare the MPD 18.23 build with the 19.19 and heard differences?
As I am mainly listening to the sources with 0.18.23-dsd-rt, I can not make an accurate comment on it but it appears there is no major difference in sound quality: both quite satisfactory.

Did you by chance also tried one MPD version without realtime patch?
Yes I did as the latest MPD-19.19 could be easily installed by "apt-get install mpd". For ordinary listening to pcm and upto-DSD128 sources, there is no difference with the other two above, though it can not play DSD higher thatn 256.

I just read a developer's comment in the official MPD wiki that realtime isn't improving sound (how should this work, btw?) and that it's just possibly helping if there is a high CPU load with lot's of other programs.
I think the realtime option is not related to such an improvement of SQ but it can improve the functionality of the CPU by making certain priority of the jobs running on the system, enabling the chance to perform to play such a high sample source like DSD512.

I'm really curious, because if both versions play also DSD512, than we can now just install Debian Stretch (plus Miro's work), that's it. This would be so easy and this just works! Regards, Matthias
As for DSD512, the version 0.19.19-DSD-rt I built can only play the source with a half speed (with clocks of 45/49 on the Cronus), though 0.18.23 is okay. I'm not sure why this occur. Will be going to investigate this problem in my spare time.

Regards,
 
Hi twluke!

Thank you very much for your detailed answer! I had some ideas in mind concerning the real time patches, but if MPD cannot go above DSD128 without then it's clear we need those patches; and they won't hurt with lower bitrated sources either!
If you don't mind my question, how do I have to apply this patch (lintweaker's?)? Just as any ordinary patch, so I can google it?
Thank you very much!
Matthias
 
If you don't mind my question, how do I have to apply this patch (lintweaker's?)? Just as any ordinary patch, so I can google it?
Thank you very much!
Matthias

Hi Matthias, thank you for your concern. Yes, I built the mpd of 0.18.23-dsd-rt using the source with rt patches provided by lintweaker's github repository. This is quite stable in playing DSD512.

As for 0.19.19, the author above only provided the patches for native DSD. So other than applying one of them to the source, you need an rt patch for 0.19 here, that was written by the original author of these rt patches for MPD.

You'll find there are two mpd-0.19git patches. You can apply the rtopt20140327 patch to the original mpd-0.19.19 source from musicpd.org without errors. The binary you are going to build from this patched source will be able to play DSD512 but, as I mentioned before, with a half speed as if clocked by 11.29MHz instead of 22.58. If you are going to have different results, please let me know.

The rtopt20150418 patch may also be applicable but you have to tweak the source files.

Whether it is patched 0.18 or 0.19 to be built, you might want to get started with the autogen.sh script in the source directory, then confirm the --enable-rtopt option is available by ./configure --help and then proceed to ./configure --enable-rtopt and then make the binary.

Before going to the procedure above, my recommendation is to install the latest MPD by apt-get install, which will provide the necessary environment for any version of working mpd binaries. As you know, the default mpd is going to be installed in /usr/bin while the mpd to be compiled by you is going to be installed in /usr/local/bin as default. I usually change the name of /usr/bin/mpd to /usr/bin/mpd.orig, then copy the compiled mpd in /usr/local/bin/ to /usr/bin.

Also, as the mpd is controlled by systemd, after successful installation, you need to make a link between /lib/systemd and /etc/systemd. In case of mpd.service, you might want to try these commands
Code:
ln -s /lib/systemd/system/mpd.service /etc/systemd/mpd.service
systemctl enable mpd.service
systemctl disable mpd.socket # if you have no plan to use it.
systemctl daemon-restart
systemctl start mpd.servie # for starting MPD
systemctl stop mpd.service # for stopping
Also, you'll be probably required to modify the script in /lib/systemd/system/mpd.service:

from: ExecStart=/usr/bin/mpd --no-daemon /etc/$MPDCONF
to: ExecStart=/usr/bin/mpd --no-daemon /etc/mpd.conf

Finally please make sure that you are using an /etc/mpd.conf containing "realtime option" provided by miero through the Botic system. Forgive me if you are already through with these procedures.

BTW, the debian stretch has annoying systemd-timesyncd.service. Disable it by "systemctl disable systemd-timesyncd.service" and then install ntp by apt-get instead, which will make your life easier.:)

Regards,
 
Good morning twluke,

Thank you so much for this detailed receipe! I'm sure this not only helps me but countless others, too!
I never patched a program for myself, and I've read a bit on how to do it, but as I didn't knew exactly, it would have taken me hours to find out. 1000 thanks for this!
Regards,
Matthias