Moode Audio Player for Raspberry Pi

I have the /proc/moode kernel module working:

root@moode:/var/www/command# cat /proc/moode
file=NAS/Logrus/A Storm of Light/A Storm of Light - 2009 - Forgive Us Our Trespasses/A Storm of Light - Forgive Us Our Trespasses.flac
artist=A Storm of Light
album=Forgive Us Our Trespasses
title=Tempest
coverurl=/coverart.php/NAS%2FLogrus%2FA%20Storm%20of%20Light%2FA%20Storm%20of%20Light%20-%202009%20-%20Forgive%20Us%20Our%20Trespasses%2FA%20Storm%20of%20Light%20-%20Forgive%20Us%20Our%20Trespasses.flac
track=03
date=2009
composer=
encoded=16/44.1
volume=55
mute=0
state=play


With this there should be no reason to NOT have it enabled, all writes are to a 1K ram buffer.

root@moode:/var/www/command# lsmod
Module Size Used by
moode_status 3214 0

Looks like the entire thing uses 3K of memory. I'm going to clean up the integration a little better and see if I can find someone to do a code review on the module as I fumbled with it until it no longer core dumped; I'm not a C expert. I hope this will be accepted into the moode distro. One nice thing is I will add a time field(s) so you can tell how long a song has been playing or how log it has been paused. How long it has been paused/stopped is usefull for a relay to power down the amp.
 
u can use the "Medieval CUE Splitter" to split the file
it uses the cue to produce a single file for each song, all tagged

Those of us who use single file flac's do so because we believe it's a superior way of doing things. CueTools is a great tool that not only converts single file flacs to separate tagged flacs, but can also convert multi file flacs to a single file flac. I used to use separate flac files for each song, and came to the conclusion that single file flacs are better for my needs. I realize your intent is to help, and thank you for your insight and time to respond to the original post, but we choose to use single file Flac's and don't need to be converted.
 
First, huge thanks to Tim for producing something which really does pretty much just work. I have tried volumio and runeaudio, but moode is the only one which reliably switches between airplay, web radio and dnla. With the latest upgrade I even managed to get it to read my music collection off a disk plugged into the USB port.

Hoever, I have one small gui problem (literally). When I look at the library on my phone, it shows nothing but albums and tracks. There is no way to see either genres or artists. Is there any way to modify the display for small screens so that it showed the artists at least?

Hi,

I have TODO list item "Library overhaul" with a sub-list containing many competing ideas for example "Take Genres off completely" vs "List all tracks by Genre". The item "Toggle betw Artists and Albums on Smartphone 2-col display already in the sub-list. Etc.

Eventually I'll get to it (Library) but can't say when.

-Tim
 
hi
I realise now that amount of tracks stayed steady as it was just one genre :)
I've ended up with around 108 genres!
I can believe everything is in there but spread all over the place.
I hope I can get it to show my own hierarchy of folders

Hi,

For folder based view u need to use Browse panel. The Library panel is organized by Genre, Artist, Album tags.

-Tim
 
I have the /proc/moode kernel module working:

root@moode:/var/www/command# cat /proc/moode
file=NAS/Logrus/A Storm of Light/A Storm of Light - 2009 - Forgive Us Our Trespasses/A Storm of Light - Forgive Us Our Trespasses.flac
artist=A Storm of Light
album=Forgive Us Our Trespasses
title=Tempest
coverurl=/coverart.php/NAS%2FLogrus%2FA%20Storm%20of%20Light%2FA%20Storm%20of%20Light%20-%202009%20-%20Forgive%20Us%20Our%20Trespasses%2FA%20Storm%20of%20Light%20-%20Forgive%20Us%20Our%20Trespasses.flac
track=03
date=2009
composer=
encoded=16/44.1
volume=55
mute=0
state=play


With this there should be no reason to NOT have it enabled, all writes are to a 1K ram buffer.

root@moode:/var/www/command# lsmod
Module Size Used by
moode_status 3214 0

Looks like the entire thing uses 3K of memory. I'm going to clean up the integration a little better and see if I can find someone to do a code review on the module as I fumbled with it until it no longer core dumped; I'm not a C expert. I hope this will be accepted into the moode distro. One nice thing is I will add a time field(s) so you can tell how long a song has been playing or how log it has been paused. How long it has been paused/stopped is usefull for a relay to power down the amp.

Hi,

Lookin' pretty awesome. Send me the binary along with sources, install steps and brief explain of how it works and I'll start stress testing it. Send to tim at moodeaudio dot org.

There are couple Moode users that are expert c/c++ coders so if necessary I'm sure they would be happy to do code review :)

Many thanks!
-Tim
 
ES9018K2M i2s DAC works great!

Hi Tim,

Just to let you know, the ES9018K2M board works!

I bought one of these from Ebay, under a tenner, (£10.0).

Connected 4 wires, Lrck, Bclk, data and Gnd, powered the DAC from a 12v wallwart.

Selected generic i2s Dac in Moode 2.7 config.

Software volume control.

It works well, but without any instrumentation, I cannot give you a noise figure, but I cannot hear any noise in the output, , but then, I can't with my IQaudio dac+ either!

It sounds different to the IQaudio, but that is due to the different analogue output stages and the reconstitution filter rolloff.

I keep trying to get this across:- ALL DACS have analogue output filters built into the output stage, to reconstitute the analogue waveform from the step output of the D to A converter. and the "hifiness" of the sound depends mostly on this filter, rather than on the silicon digital stage.

cheers

Patrick
 
I have the /proc/moode kernel module working:

root@moode:/var/www/command# cat /proc/moode
file=NAS/Logrus/A Storm of Light/A Storm of Light - 2009 - Forgive Us Our Trespasses/A Storm of Light - Forgive Us Our Trespasses.flac
artist=A Storm of Light
album=Forgive Us Our Trespasses
title=Tempest
coverurl=/coverart.php/NAS%2FLogrus%2FA%20Storm%20of%20Light%2FA%20Storm%20of%20Light%20-%202009%20-%20Forgive%20Us%20Our%20Trespasses%2FA%20Storm%20of%20Light%20-%20Forgive%20Us%20Our%20Trespasses.flac
track=03
date=2009
composer=
encoded=16/44.1
volume=55
mute=0
state=play


With this there should be no reason to NOT have it enabled, all writes are to a 1K ram buffer.

root@moode:/var/www/command# lsmod
Module Size Used by
moode_status 3214 0

Looks like the entire thing uses 3K of memory. I'm going to clean up the integration a little better and see if I can find someone to do a code review on the module as I fumbled with it until it no longer core dumped; I'm not a C expert. I hope this will be accepted into the moode distro. One nice thing is I will add a time field(s) so you can tell how long a song has been playing or how log it has been paused. How long it has been paused/stopped is usefull for a relay to power down the amp.

Jeez, I step out of the room for a break and look what happens!

This use of the /proc pseudo-filesystem is interesting and your intent resonates with my own sense that we needn't write transitory information to the real filesystem. The existence of a Python package "proc" makes it trivial for user-space hackers like me to play with /proc/moode.

Your code doesn't core dump? That qualifies as production-ready in some shops:)

Regards,
Kent
 
DSD on the ES9018K2M

Hi Tim,

Downloaded a 256dsd and 128dsd file from 2lo onto usb stick (same piece of music)

They both appear to play fine.

I have set DSD over PCM (DoP) to No.

This is the audio info for the 256DSD file.

Input Processing
Source: USB/1F38-69CC/2L-106_stereo-11289k-1b_04.dsf
Encoded at: DSD
Decoded to: DSD, Stereo
Rate: 11289 kbps
DSP Operations
Resampling: off
Crossfeed: off
Chip options: none
Volume: Software (MPD 32 bit float with dither)
Output Stream
Format: 24 bit, 192 kHz, Stereo
Rate: 9.216 mbps
Audio Device
Device: Generic-2 I2S (rpi-dac)
Chip: ES9018, PCM1794, Etc
Architecture: Sigma/Delta
Interface: I2S

Pity DSD files are so HUGE, they are impracticable to store. (4,5 mins of DSD256 run time is 850Mb! )

I will stick at 24/92 flacs, good enough for me. I was just curious what a DSD file sounded like.

cheers

Patrick
 
Start/stop playlist via cron?

Hi All,

I'm just getting started with moode (great job btw!) and want to set up an automation to load a playlist at 8am and play it looped untll 8pm (This duplicates the clock radio functionality but I couldn't see how to set clock radio to a playlist in the UI.)

I did a quick hack using wget to simulate some of the commands first.

Then I went through the code in var/www and can see options for running php from a cron job e.g.

Code:
php -f /var/www/command/index.php  clrplayall pathtoplaylist

Before I start coding, have I missed anything obvious that already does this?
Any reason to use bash over php?
Anything else?

Thanks,
hypotune
 
Hi Tim,

Downloaded a 256dsd and 128dsd file from 2lo onto usb stick (same piece of music)

They both appear to play fine.

I have set DSD over PCM (DoP) to No.

This is the audio info for the 256DSD file.



Pity DSD files are so HUGE, they are impracticable to store. (4,5 mins of DSD256 run time is 850Mb! )

I will stick at 24/92 flacs, good enough for me. I was just curious what a DSD file sounded like.

cheers

Patrick

Hi Patrick,

ES9018 is supposed to support DoP so please try the steps below. The kernel that ships with Moode can only support DSD64 DoP. Note that I'm testing a custom kernel that supports DSD128 :)

1) DSD64 file
2) Enable DoP in MPD
3) Turn Moode volume to 0
4) If you have down stream physical volume control, turn it down
5) Start playback
6) Turn Moode volume up to only 1 and if no sound then gradually raise Moode volume (and down stream volume)

If ES9018 is decoding DSD64 DoP you will hear music otherwise just noise.

-Tim
 
Hi All,

I'm just getting started with moode (great job btw!) and want to set up an automation to load a playlist at 8am and play it looped untll 8pm (This duplicates the clock radio functionality but I couldn't see how to set clock radio to a playlist in the UI.)

I did a quick hack using wget to simulate some of the commands first.

Then I went through the code in var/www and can see options for running php from a cron job e.g.

Code:
php -f /var/www/command/index.php  clrplayall pathtoplaylist

Before I start coding, have I missed anything obvious that already does this?
Any reason to use bash over php?
Anything else?

Thanks,
hypotune

Hi,

Using the UI, I think if you just add the stored playlist to main Playlist and have it be the only list of tracks in the Playlist, then menu for the first track "Set for clock radio", then click the repeat button (below the volume knob).

-Tim
 
1. When folder is added from Browse panel, the mpd add command is used and this command does not parse playlists which is in effect what a cue sheet is, thus the individual tracks won't appear in the main Playlist.
-Tim

I don't fully understand, wouldn't it be possible to first check for the presence of cue files before calling the mpd add command, and if a cue file is found then only add that? If I use the GUI to go into the folder and select the cue file it works fine.
 
playing DSD files with Es9018K2M

Hi Tim,

As per your request.

1. DSD64 file

2. MPD config with DSD over PCM (DoP) set to YES and restart

Very, very, very, faint music output , buried in noise, I can just hear the tune buried in the circuit noise with the amp volume gain = max!

With the amp vol at normal level the output appears to be completely silent, although the Audio info indicated that there was output so I wound the amp gain (100 W possible), up with fear and trepidation! Then I could JUST hear the tune.

Audio info for this case:-

Input Processing
Source: USB/1F38-69CC/2L-106_stereo_DSD-2822k_MAGNIFICAT_04.dsf
Encoded at: DSD
Decoded to: DSD, 352.8 kHz, Stereo
Rate: 2822 kbps
DSP Operations
Resampling: off
Crossfeed: off
Chip options: none
Volume: Software (MPD 32 bit float with dither)
Output Stream
Format: 24 bit, 176.4 kHz, Stereo
Rate: 8.467 mbps
Audio Device
Device: Generic-2 I2S (rpi-dac)
Chip: ES9018, PCM1794, Etc
Architecture: Sigma/Delta
Interface: I2S

3. With DSD over PCM (DoP) set to NO and restart

Good level sound output, sounds OK

Input Processing
Source: USB/1F38-69CC/2L-106_stereo_DSD-2822k_MAGNIFICAT_04.dsf
Encoded at: DSD
Decoded to: DSD, 352.8 kHz, Stereo
Rate: 2822 kbps
DSP Operations
Resampling: off
Crossfeed: off
Chip options: none
Volume: Software (MPD 32 bit float with dither)
Output Stream
Format: 24 bit, 192 kHz, Stereo
Rate: 9.216 mbps
Audio Device
Device: Generic-2 I2S (rpi-dac)
Chip: ES9018, PCM1794, Etc
Architecture: Sigma/Delta
Interface: I2S

Note the diff in the output streams format and rate for the two cases.

cheers

Patrick
 
I don't fully understand, wouldn't it be possible to first check for the presence of cue files before calling the mpd add command, and if a cue file is found then only add that? If I use the GUI to go into the folder and select the cue file it works fine.

Hi,

Possible, yes but not just a simple "if" statement since the mpd add command internally recurses through folder/sub-folder/etc adding all the files it finds.

This new code would need to replicate traversing the folder hierarchy and then run mpd load cmd for .cue files and mpd add cmd for all other files.

-Tim
 
Hi Tim,

As per your request.

1. DSD64 file

2. MPD config with DSD over PCM (DoP) set to YES and restart

Very, very, very, faint music output , buried in noise, I can just hear the tune buried in the circuit noise with the amp volume gain = max!

With the amp vol at normal level the output appears to be completely silent, although the Audio info indicated that there was output so I wound the amp gain (100 W possible), up with fear and trepidation! Then I could JUST hear the tune.

Audio info for this case:-



3. With DSD over PCM (DoP) set to NO and restart

Good level sound output, sounds OK



Note the diff in the output streams format and rate for the two cases.

cheers

Patrick

Hi Patrick,

I get same results feeding to es9023 boards except with new custom kernel the output stream with DoP off would be like below instead of 24/192.

Format: 24 bit, 352.8 kHz, Stereo
Rate: 16.934 mbps

DoP failing (faint music buried in noise) is probably due to limitation in the rpi-dac I2S driver or in the implementation of es9018 on that board. I'm just guessing.

-Tim