User avatar
karrika
Posts: 1193
Joined: Mon Oct 19, 2015 6:21 am
Location: Finland

Re: fruitbox MP3 jukebox

Tue Sep 15, 2020 7:53 am

wyovino wrote:
Tue Sep 15, 2020 2:34 am
I have just about everything sorted out but I'm interested to hear what people are using for sound equipment. Right now I'm using the 3.5mm jack into a pair of powered speakers (Bose). I'd like some better (bigger sound). Would a DAC hat make a big difference or should I add and amp and other speakers?
I run TouchOne on the official 7" display and route the 3.5mm sound cable from the AudioInjector HAT to the speakers below. This sounds pretty cool for me. This is not the most beautiful setup. But it is very practical.
Image
Image

damonkirk1983
Posts: 14
Joined: Sun May 03, 2020 11:59 am

Re: fruitbox MP3 jukebox

Tue Sep 15, 2020 1:29 pm

Legtod2 wrote:
Sat Aug 08, 2020 11:19 pm
Here is my 1937 Marconi Tube radio that I added an aux port to pi and used Mopidy with...

Youtube link
https://www.youtube.com/watch?v=p2ZwQ_Z3U4A
This is awesome, love the stream side of it.
I will need some help setting up I think, is it ok to reach out?
I set up the player already but i am a novice and followed instructions all the way - would love to add internet stations to it with your help

wyovino
Posts: 17
Joined: Wed Aug 28, 2019 3:55 pm

Re: fruitbox MP3 jukebox

Tue Sep 15, 2020 3:37 pm

karrika wrote:
Tue Sep 15, 2020 7:53 am
I run TouchOne on the official 7" display and route the 3.5mm sound cable from the AudioInjector HAT to the speakers below. This sounds pretty cool for me. This is not the most beautiful setup. But it is very practical.
@karrika - Is there a significant improvement in sound when using the AudioInjector HAT rather than the RPi 3.5 mm jack? Which one do you have?

User avatar
karrika
Posts: 1193
Joined: Mon Oct 19, 2015 6:21 am
Location: Finland

Re: fruitbox MP3 jukebox

Wed Sep 16, 2020 4:15 am

wyovino wrote:
Tue Sep 15, 2020 3:37 pm
karrika wrote:
Tue Sep 15, 2020 7:53 am
I run TouchOne on the official 7" display and route the 3.5mm sound cable from the AudioInjector HAT to the speakers below. This sounds pretty cool for me. This is not the most beautiful setup. But it is very practical.
@karrika - Is there a significant improvement in sound when using the AudioInjector HAT rather than the RPi 3.5 mm jack? Which one do you have?
There is a big difference. There is much less noise coming from mains power from real Audio Injector cards. I am also using Audio Injector HAT cards at the theater when I have to connect my Pi to control lights and sounds for a play. When you connect to big systems you see the difference. At home it does not really matter. Besides, I use my jukebox for dance practise mainly. So the sound quality is not so important.

I am currently waiting for the latest Audio Injector Kickstarter cart that should be the ultimate design for a totally floating audio interface.

http://www.audioinjector.net/isolated-soundcard with separate pre-amplifiers and professional connections.

So far I have used all of their carts from PiZero mini hat up. And these work well and have built-in volume control pots. Besides, the Audio Injector cards generate the sounds at 96kHz 32 bit samples or 192kHz 24 bit audio words, depending on the model.

The basic Pi does not have a DAC at all. The PCM output is fed to a capacitor. So my guess is that it sounds like 48kHz 16 bit samples, perhaps?

gordon77
Posts: 5192
Joined: Sun Aug 05, 2012 3:12 pm

Re: fruitbox MP3 jukebox

Wed Sep 16, 2020 6:14 am

Quoting jdb.. regarding pi audio output...

"...the 512-tap FIR lowpass filter implemented in firmware, not the PWM filter response.
The filter chain takes any arbitrary input samplerate and converts it to a fixed 48.828kHz, before mixing all input sources together. Then there is an upsampling and noise shaping stage with an eventual output carrier frequency of 781.25kHz.
Band limiting is essential for the sigma-delta modulation scheme to work - its effectiveness depends on the signal power being effectively zero outside of the audio band."

viewtopic.php?t=278572

User avatar
karrika
Posts: 1193
Joined: Mon Oct 19, 2015 6:21 am
Location: Finland

Re: fruitbox MP3 jukebox

Wed Sep 16, 2020 6:41 am

Thanks gordon77 for the facts.

If you use the pi for listening to mp3's or other stuff from the net the original output is enough.

If you play studio recorded stuff as part of a show you may want a bit more.

User avatar
fruitbox
Posts: 472
Joined: Mon Feb 22, 2016 7:35 pm
Location: UK

Re: fruitbox MP3 jukebox

Wed Sep 16, 2020 9:56 am

karrika wrote:
Wed Sep 16, 2020 4:15 am
I am also using Audio Injector HAT cards at the theater when I have to connect my Pi to control lights and sounds for a play.
Hi Karrika,

Just out of interest (and slightly off-topic I'm afraid), what Pi software do you use for your lighting and sound? Also is the lighting DMX controlled, and if so, what hardware do you have? (Maybe a USB DMX interface?)

Cheers
Mike

User avatar
karrika
Posts: 1193
Joined: Mon Oct 19, 2015 6:21 am
Location: Finland

Re: fruitbox MP3 jukebox

Wed Sep 16, 2020 2:07 pm

fruitbox wrote:
Wed Sep 16, 2020 9:56 am
karrika wrote:
Wed Sep 16, 2020 4:15 am
I am also using Audio Injector HAT cards at the theater when I have to connect my Pi to control lights and sounds for a play.
Hi Karrika,

Just out of interest (and slightly off-topic I'm afraid), what Pi software do you use for your lighting and sound? Also is the lighting DMX controlled, and if so, what hardware do you have? (Maybe a USB DMX interface?)

Cheers
Mike
I am totally addicted to QLC+. I did create a bunch of DiscoHAT boards for controlling the lights. The QLC+ has a "show" element where you can sync lights with the soundtrack.

I even have a site of my own at https://www.discohat.com

Unfortunately I have been too busy to keep the shop open for the carts. But once I get some time I would LOVE TO create a system with a Pi 4, two screens (one for control, the other for a projector), Audio Injector isolated audio, 4 isolated DMX channels for light control, lots of schmitt triggered input switches for triggering events during the play. I love the idea that the actors can trigger when the doorbell rings or when a song starts.

User avatar
fruitbox
Posts: 472
Joined: Mon Feb 22, 2016 7:35 pm
Location: UK

Re: fruitbox MP3 jukebox

Wed Sep 16, 2020 3:24 pm

karrika wrote:
Wed Sep 16, 2020 2:07 pm
fruitbox wrote:
Wed Sep 16, 2020 9:56 am
karrika wrote:
Wed Sep 16, 2020 4:15 am
I am also using Audio Injector HAT cards at the theater when I have to connect my Pi to control lights and sounds for a play.
Hi Karrika,

Just out of interest (and slightly off-topic I'm afraid), what Pi software do you use for your lighting and sound? Also is the lighting DMX controlled, and if so, what hardware do you have? (Maybe a USB DMX interface?)

Cheers
Mike
I am totally addicted to QLC+. I did create a bunch of DiscoHAT boards for controlling the lights. The QLC+ has a "show" element where you can sync lights with the soundtrack.

I even have a site of my own at https://www.discohat.com

Unfortunately I have been too busy to keep the shop open for the carts. But once I get some time I would LOVE TO create a system with a Pi 4, two screens (one for control, the other for a projector), Audio Injector isolated audio, 4 isolated DMX channels for light control, lots of schmitt triggered input switches for triggering events during the play. I love the idea that the actors can trigger when the doorbell rings or when a song starts.
Brilliant, thanks. Nice work on the DiscoHAT, by the way.

ViviannaVanGogh
Posts: 1
Joined: Thu Jul 23, 2020 3:03 pm

Re: fruitbox MP3 jukebox

Thu Sep 17, 2020 10:57 pm

Howdy; y'all are awesome.
Can anyone tell me which code to alter to let my keyboard input except more than 11 letters? I'm retro-modding a 1957 Wurly floor model with buttons a-v and numbers 0-9. sadly the software only lets me use a-k. I can make everything else work, altering page sizes etc. so I can have 1 page with 200 songs (not that I wouldn't take advice on how to do that better), but I can't get the software to recognize any letter past K.
Help.
Oh; it has to be set up this way as it will have no monitor once it's up and running, so all the songs will be printed and labeled on the original display board. that means no page turning allowed.
Anyway..thanks again for the great software. :P

User avatar
fruitbox
Posts: 472
Joined: Mon Feb 22, 2016 7:35 pm
Location: UK

Re: fruitbox MP3 jukebox

Fri Sep 18, 2020 7:17 am

ViviannaVanGogh wrote:
Thu Sep 17, 2020 10:57 pm
Howdy; y'all are awesome.
Can anyone tell me which code to alter to let my keyboard input except more than 11 letters? I'm retro-modding a 1957 Wurly floor model with buttons a-v and numbers 0-9. sadly the software only lets me use a-k. I can make everything else work, altering page sizes etc. so I can have 1 page with 200 songs (not that I wouldn't take advice on how to do that better), but I can't get the software to recognize any letter past K.
Help.
Oh; it has to be set up this way as it will have no monitor once it's up and running, so all the songs will be printed and labeled on the original display board. that means no page turning allowed.
Anyway..thanks again for the great software. :P
Hi

Currently fruitbox only supports select buttons 0 to 9 and A to K. The next release (v2.00) extends these to A to Z.

If you're not limited by an particular sequence of select codes, then it's easy to support 200 songs on one screen. In the skin cfg file, you can specify the SelectButtons multiple times; each time it is defined will increase the number of digits in the code, for example...

SelectButtons = 01
SelectButtons = 0123456789
SelectButtons = 0123456789

...will create the select code range 000 to 199.

If you run fruitbox with the --debug-song-nums option as well, it will show each song with its select code...useful for debugging.

Cheers
Mike

wyovino
Posts: 17
Joined: Wed Aug 28, 2019 3:55 pm

Re: fruitbox MP3 jukebox

Sun Sep 20, 2020 1:57 am

Does anyone have any experience with Innomaker DAC Hat? I can't get any output from its 3.5 mm jack. Is there a setting in Fruitbox where you choose the output device? I was getting sound out of the RPi's 3.5mm jack.

vasigias
Posts: 5
Joined: Wed Feb 27, 2019 4:58 pm

Re: fruitbox MP3 jukebox

Mon Sep 21, 2020 5:55 pm

wyovino wrote:
Sun Sep 20, 2020 1:57 am
Does anyone have any experience with Innomaker DAC Hat? I can't get any output from its 3.5 mm jack. Is there a setting in Fruitbox where you choose the output device? I was getting sound out of the RPi's 3.5mm jack.
try this
sudo raspi-config
This will open the configuration screen:

Select Advanced Options (here shown as Option 7, but yours may be different) and press Enter.

Now select the Option named, Audio (here shown as A6, but yours may be different) and press Enter:
select output from its 3.5 mm jack press Enter and press the right arrow key to exit the options list, then select Finish to exit the configuration tool.

wyovino
Posts: 17
Joined: Wed Aug 28, 2019 3:55 pm

Re: fruitbox MP3 jukebox

Mon Sep 21, 2020 6:26 pm

Thanks for the reply but that's not the issue. I'm already getting sound from the RPi's jack. I'm not able to get it from the DAC Hat's jack.

User avatar
karrika
Posts: 1193
Joined: Mon Oct 19, 2015 6:21 am
Location: Finland

Re: fruitbox MP3 jukebox

Tue Sep 22, 2020 12:25 pm

Usually you get some kind of overlay file from the audio HAT manufacturer that you add to /boot/config.txt like:

Code: Select all

dtoverlay=audioinjector-wm8731-audio
It may also be in the raspbian release automatically.

After that you can see the new audio device by the command

Code: Select all

$ aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: audioinjectorpi [audioinjector-pi-soundcard], device 0: AudioInjector audio wm8731-hifi-0 []
  Subdevices: 1/1
  Subdevice #0: subdevice #0

fa001
Posts: 93
Joined: Wed Jan 02, 2013 8:25 pm

Re: fruitbox MP3 jukebox

Tue Sep 22, 2020 7:08 pm

I have a 5 inch resistive touch screen from China. It works fine in the GUI but will not work with Fruitbox.
Anyone have a suggestion?

wyovino
Posts: 17
Joined: Wed Aug 28, 2019 3:55 pm

Re: fruitbox MP3 jukebox

Tue Sep 22, 2020 10:27 pm

karrika wrote:
Tue Sep 22, 2020 12:25 pm
Usually you get some kind of overlay file from the audio HAT manufacturer that you add to /boot/config.txt like:

Code: Select all

dtoverlay=audioinjector-wm8731-audio
It may also be in the raspbian release automatically.

After that you can see the new audio device by the command

Code: Select all

$ aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: audioinjectorpi [audioinjector-pi-soundcard], device 0: AudioInjector audio wm8731-hifi-0 []
  Subdevices: 1/1
  Subdevice #0: subdevice #0
I finally got it to work after a few very frustrating days. I have some extra RPi 3B+ boards hanging around so I loaded up a new SD card with the latest OS and then installed Fruitbox on it. I made the necessary config changes and it worked. I moved that card to the RPi that I'm using for the jukebox and it didn't work. I swapped boards and now it's working, so maybe a hardware problem with that one board. There is quite a difference in loudness and clarity with the DAC hat.

I also had a problem where I would have to reset the audio device after each reboot. That was solved by editing a file using the results from the "aplay -l" command to set the default to the desired device.

sudo nano /usr/share/alsa/alsa.conf

#change the 0's to the number found in the "aplay -l" command for the desired device.
defaults.ctl.card 0
defaults.pcm.card 0

kipper641
Posts: 3
Joined: Thu May 14, 2020 2:11 pm

SD Image Dropbox Error

Tue Sep 29, 2020 7:49 am

Trying to D/L the image from dropbox but just get error 404 ?
Using :- https://www.dropbox.com/s/bc1r0ypwrvaql ... g.zip?dl=0

Many Thanks

User avatar
fruitbox
Posts: 472
Joined: Mon Feb 22, 2016 7:35 pm
Location: UK

Re: SD Image Dropbox Error

Wed Sep 30, 2020 7:36 am

kipper641 wrote:
Tue Sep 29, 2020 7:49 am
Trying to D/L the image from dropbox but just get error 404 ?
Using :- https://www.dropbox.com/s/bc1r0ypwrvaql ... g.zip?dl=0

Many Thanks
Yep, sorry. Due to excess traffic the dropbox link has been suspended...I need to think of a better way to share this large file.

Any ideas anyone?

Halen78
Posts: 5
Joined: Thu Jan 26, 2017 3:49 am

Re: fruitbox MP3 jukebox

Thu Oct 01, 2020 6:57 pm

PART 1 OF 3

Hello all,
Right off the bat, I want to send a big huge Thank You to Mike for sharing his awesome jukebox software with the Raspberry Pi community.
I'm a big fan of SalmonKing's SK Jukebox for the PC from back in the day, and since getting into RPi a few years back I've been on the lookout for something similar. Fruitbox exceeded my expectations.

A few weeks ago I set myself the task of integrating Fruitbox with a customized RetroPie image, and specifically with the EmulationStation front end. Last weekend I successfully completed this task. In-between, it was a lot of searching, Googling, reading forum posts and trial-and-error. If a step-by-step guide exists out there, I utterly failed to find it. So while stumbling through the process, I kept good notes, with the intention of organizing them and creating a step-by-step guide. That's the purpose of this post, and I hope someone finds it useful.

IMPORTANT NOTE: What follows is a guide to integrate Fruitbox with a Jessie-based RetroPie build. RetroPie sits atop an operating system called Raspbian. Raspbian OS is based on Debian Linux, which sees major releases every couple years. At the time of this writing, the current Raspbian OS version is 10, a.k.a. "Buster", and the Fruitbox documentation explicitly recommends starting on a fresh Buster-based OS install. "Jessie" was version 8 - two versions and several years behind Buster. So specific steps had to be taken to get Fruitbox to play nice with Jessie. If you are installing Fruitbox on an updated operating system, just follow the instructions from Mike's Github repo, and then skip the "INSTALLATION" section of this guide completely, and go straight to "INTEGRATION" for the Emulationstation bit.

To confirm your OS build, execute the following command from the command line on your Raspberry Pi:

Code: Select all

cat /etc/os-release
MOST IMPORTANT NOTE OF ALL: Before attempting this procedure, back up your SD card. I take no responsibility whatsoever for any problems which may arise from following this guide. This is the process which worked for me, your mileage may vary.

GOAL:: Install Fruitbox on a Jessie-based RetroPie image, and integrate it with the EmulationStation front end.

SET UP

1) You already took that back-up of your current image, right?
2) Your Raspberry Pi is up and running, connected to the internet, and has a keyboard attached.
3) While all of this can be done directly on your Pi, you would benefit greatly from connecting a PC to your Pi using an SSH client such as PuTTY, so you can easily cut and paste the commands shown below rather than typing them manually.
4) You have backed out of EmulationStation (Hit F4) on your Pi, and you are sitting at a Linux command prompt, in your home directory.
If any of the steps above are even the slightest bit mysterious to you, take your hands off the keyboard and back away slowly. Hold off on going any further until you level-up your Linux/Pi skill set a bit.

...proceed to Part 2 of 3...

Halen78
Posts: 5
Joined: Thu Jan 26, 2017 3:49 am

Re: fruitbox MP3 jukebox

Thu Oct 01, 2020 6:58 pm

PART 2 OF 3

INSTALLATION

1) On your PC, navigate to the Fruitbox Github repo:
https://github.com/chundermike/rpi-fruitbox

2) Click into the build directory and open "build.txt".

3) Follow the directions found in build.txt to the letter. The only note I will add is, read the comments in that file carefully, because it will call out which commands need to be executed specifically for a Jessie build or for a Stretch build. Don't forget to execute the "make" command at the very end.

4) On your Pi, from your home directory, change directories into the newly created rpi-fruitbox-master directory, and familiarize yourself with the contents. If you run an ls command in this directory, you should get something like this:

pi@retropie:~/rpi-fruitbox-master $ ls -ltrah
total 18M
drwxr-xr-x 4 pi pi 4.0K Sep 24 17:36 . <-- Current Directory
drwxr-xr-x 19 pi pi 4.0K Sep 24 16:51 .. <-- Parent Directory
drwxr-xr-x 4 pi pi 4.0K Sep 24 17:35 build <-- Lots of stuff not to mess with here, let's leave it at that.
drwxr-xr-x 14 pi pi 4.0K Jun 16 21:36 skins <-- The Skins Directory. You will be making changes here.
-rw-r--r-- 1 pi pi 84K Jun 16 21:36 userguide.txt <-- Useful info here.
-rw-r--r-- 1 pi pi 18K Jun 16 21:36 release_notes.txt <-- Useful info here.
-rw-r--r-- 1 pi pi 2.4K Jun 16 21:36 README.md <-- Useful info here.
-rw-r--r-- 1 pi pi 484 Jun 16 21:36 skins.txt <-- Outside the scope of this guide.
-rw-r--r-- 1 pi pi 899 Jun 16 21:36 install.sh <-- Don't touch this.
-rw-r--r-- 1 pi pi 5.4M Jun 16 21:36 fruitbox-jessie <-- THIS is the one you will want to use. Notice, it is not yet executable!
-rw-r--r-- 1 pi pi 6.1M Jun 16 21:36 fruitbox-buster <-- This is for a Buster-based operating system.
-rwxr-xr-x 1 pi pi 5.5M Sep 24 17:35 fruitbox <-- This is for a Stretch-based operating system.
-rw-r--r-- 1 pi pi 113 Sep 24 17:36 fruitbox.log <-- Console output gets written here.

In addition to creating rpi-fruitbox-master in your Home Directory, it also creates an empty Music directory (pi@retropie:~/Music). This is where your MP3s go.

5) Execute the following command to make the fruitbox-jessie binary executable:

Code: Select all

sudo chmod +x fruitbox-jessie
6) Perform an initial test run by invoking the fruitbox-jessie binary with no arguments.
Note: I suggest not invoking the fruitbox-jessie binary from within the SSH client on your PC (if you are using one). Frankly, I don't know whether it would even work. So for what it's worth, I recommend switching to the keyboard hooked directly into your Pi to launch the program.
Execute the following command:

Code: Select all

sudo ./fruitbox-jessie
This should display a short help file onscreen.
If this works, proceed to the next step.
If you receive any error, you will need to work through it. If you get stuck, the folks on this forum are very helpful.

7) Next order of business is to understand the available Fruitbox "button controls", and map your physical controller (connected to your Pi) to those in-program controls.

7a) From the rpi-fruitbox-master directory, open userguide.txt. Or, more conveniently, open userguide.txt from the Fruitbox Github repo on your PC, so you can refer back to it at any time on your computer screen. In the user guide, scroll down to section 10.1 Default Buttons. These are all the button controls available to you in Fruitbox. I recommend the following course of action.

- Determine how many total inputs are available to you (number of buttons on your game controller, control panel, etc). Don't forget to add 4 for the joystick.
- Choose (up to) that many controls from the available button controls described in the user guide.
- Map out (on paper) which physical controller inputs you want to associate with which in-program button controls.

7b) This step is optional, but recommended. Determine and document Fruitbox's button mapping values for each of your game controller inputs. This will allow you to confirm that Fruitbox can see your controller, and that it will accept input from all of your buttons and joystick. Execute the following command:

Code: Select all

sudo ./fruitbox-jessie --test-buttons
This should bring up a graphical interface, which should respond to each of the inputs on your controller by displaying Fruitbox's button mapping values for each.
For example, you may press "Start" on your controller or arcade control panel, and Fruitbox may display something like "JoyButton 0 297". In this example, it is telling you that it recognizes that button as being from controller 0 (controller 1 would denote your second, or "player 2", controller), and it has an internal value of 297. Do this for each button and all four joystick directions, and add them to your paper control mapping document. This will also allow you, in the future, to swap specific button assignments in the button configuration file directly, without having to go through the entire mapping process again (which we will perform next).

To exit from test-buttons mode, hit Ctrl-C on your keyboard.

7c) With all your button configurations planned out, execute the following command from the rpi-fruitbox-master directory:

Code: Select all

sudo ./fruitbox-jessie --config-buttons
Fruitbox will fire up and step through each of the available button controls, and allow you to map them to your physical controller. For each button control which you do not want to map to your controller, hit ESC on your keyboard. Otherwise, hit the button or joystick direction which you want to correspond with each.

If all went well, you now have a new file in your rpi-fruitbox-master directory: fruitbox.btn
Any time you subsequently run fruitbox with the --config-buttons argument, you will overwrite fruitbox.btn.

8) Next order of business is to choose a Skin and perform any necessary tweaks to that skin. This guide is already way too verbose, and Mike's userguide already covers skins in great detail. So we will just proceed with the NumberOne skin. Not all skins have joystick support. NumberOne does, but it is disabled by default (ask me how long it took me to figure that one out). We must enable it. Execute the following commands:

Code: Select all

cd ~/rpi-fruitbox-master/skins/NumberOne/
sudo nano fruitbox.cfg
scroll down to the [joystick] section, and delete the hash tags ("#") in front of the following lines:

Code: Select all

#[joystick]
#Bitmap = joystick.png
Hit Ctrl-x, then y, and Enter to save your changes.

9) Next order of business is to add some MP3s. Given that we are using the NumberOne skin, and we want to give our controller mapping scheme a thorough test, I have the following suggestions.
- Choose pairs of songs from each artist. The NumberOne skin implements the classic jukebox pattern of listing songs from individual artists in pairs (the A-side and B-side of a vinyl 45). You will achieve a full page of songs with no gaps if you choose songs in pairs like this.
- Choose at least 50 songs in total. This will allow you to fill one full page of songs, and test your ability to flip to a second page and back.
- In order to display properly, all chosen MP3s should have proper ID3 tags, containing at least the artist name, album name and song title. Genre may come in handy at some point as well. If you are unfamiliar with ID3 tags for MP3 files, do some Googling. Plenty of info and free ID3 tagging programs out there.
- Use an FTP program such as Core FTP LE to easily transfer MP3s from your PC to the ~/Music/ folder on your Pi.

10) Next order of business is to invoke Fruitbox from the command line, with the proper command line arguments, and test it out and play some music. Execute the following command:

Code: Select all

sudo /home/pi/rpi-fruitbox-master/fruitbox-jessie --cfg /home/pi/rpi-fruitbox-master/skins/NumberOne/fruitbox.cfg
You should now be seeing the Fruitbox logo, and then it will spin through your MP3 files one at a time, producing a database file in your home directory (~/fruitbox.db), and you will end up in a full-screen fully-functional jukebox. Hit your "insert coin" button, navigate to a song with your joystick, and click your "select song" button to play it.

If all went well, you were able to successfully launch Fruitbox, test out all your controls, play songs, and back out of the software back to your Linux command line.
If this is the case, I strongly suggest that you take the time to once again back up your image before proceeding to the INTEGRATION portion of this guide to integrate Fruitbox with Emulationstation.
If this is not the case, and you encountered problems and got stuck, again the folks on this forum are very helpful.

One additional note. In my particular case, Fruitbox did not go to full screen right out of the box. I later came to understand that this was due to a Retropie customization that I had made long ago in my /boot/config.txt file, related to screen resolution. I do not want to go into that here, other than to say, Fruitbox makes every effort to go full screen automatically, so if it fails to do so, it's probably because of some display customizations already present in your image.

...proceed to Part 3 of 3...

Halen78
Posts: 5
Joined: Thu Jan 26, 2017 3:49 am

Re: fruitbox MP3 jukebox

Thu Oct 01, 2020 6:59 pm

PART 3 OF 3

INTEGRATION

This is the part which could potentially screw up your entire RetroPie / EmulationStation setup if not done carefully. You took that backup of your SD card, right?...

Much of what I list below is based on this RetroPie Docs entry:
https://retropie.org.uk/docs/Add-a-New- ... onStation/
It is highly recommended that you read it before proceeding, and refer back to it if you have trouble.

1) Determine whether you already have a copy of es_systems.cfg housed within the /home/pi/.emulationstation folder.

Code: Select all

cd /home/pi/.emulationstation
ls es_systems.cfg
2) IF es_systems.cfg already exists in this folder, take a backup of it, in case you make a mistake and corrupt the current working version.

Code: Select all

sudo cp es_systems.cfg es_systems.BAK
Otherwise, if es_systems.cfg does NOT exist in the /home/pi/.emulationstation folder, copy it there from the /etc/emulationstation/ folder.
Once again, only execute the following command if es_systems.cfg does NOT already exist in the /home/pi/.emulationstation folder.

Code: Select all

sudo cp /etc/emulationstation/es_systems.cfg /home/pi/.emulationstation/es_systems.cfg
3) Manually add a Fruitbox entry in es_systems.cfg. Execute this command:

Code: Select all

sudo nano /home/pi/.emulationstation/es_systems.cfg
With es_systems.cfg opened in the nano editor, notice that each entry begins with the <system> tag, and ends with the </system> tag.
You will not be making changes to any of the existing system entries, but you will be inserting a new entry in-between the existing ones.
Determine where you want your new Fruitbox entry to appear in the system list, and add the following entry there:

Code: Select all

  <system>
    <fullname>Fruitbox</fullname>
    <name>fruitbox</name>
    <path>~/RetroPie/roms/fruitbox</path>
    <extension>.sh .SH</extension>
    <command>bash %ROM%</command>
    <platform>fruitbox</platform>
    <theme>fruitbox</theme>
  </system>
Hit Ctrl-x, then y, and Enter to save your changes.

4) Create a fruitbox rom directory:

Code: Select all

mkdir /home/pi/RetroPie/roms/fruitbox
5) Create your launch script within the Fruitbox rom directory:

Code: Select all

sudo nano /home/pi/RetroPie/roms/fruitbox/fruitbox.sh
and add the following lines to fruitbox.sh...

Code: Select all

cd /home/pi/rpi-fruitbox-master/
sudo ./fruitbox-jessie --cfg /home/pi/rpi-fruitbox-master/skins/NumberOne/fruitbox.cfg
Hit Ctrl-x, then y, and Enter to save your changes.

6) Make your launch script executable:

Code: Select all

sudo chmod +x /home/pi/RetroPie/roms/fruitbox/fruitbox.sh
7) At this point, you should be able to launch Emulationstation. It won't yet be pretty, but it should be functional.
Launch EmulationStation and test it out. Fruitbox should now show up in your main menu.
Select into it, and it should show one "Rom", called Fruitbox. Launch it, and Fruitbox should run and be fully functional.
Test it thoroughly, then exit our of Fruitbox and back into EmulationStation. It should work just like launching a game and then backing out of it.

If you receive any error, you will need to work through it. If you get stuck at THIS point, this forum, https://www.raspberrypi.org/forums is a good resource, but I would not suggest posting to this particular thread. Because the issues will be RetroPie or EmulationStation-centric, not Fruitbox-centric. (Remember, you already got Fruitbox running in the INSTALLATION section)
Review the RetroPie Docs entry that I list above, and if you need to call for backup, https://retropie.org.uk/forum/ is another good resource, as is Reddit.

But if everything does work, CONGRATULATIONS! You can absolutely end the entire process right here.

Beyond this point, there will be less step by step instructions, but rather tips and advice on achieving a consistent look and feel for your new Fruitbox menu item in EmulationStation. If you use the EmulationStation Carbon theme, these tips should apply to you very directly. With any other Theme, you will need to adjust accordingly.

Back out of EmulationStation (Hit F4) to get back into Linux.

Create a Fruitbox entry within the Carbon theme set.

Code: Select all

sudo mkdir /etc/emulationstation/themes/carbon/fruitbox
sudo mkdir /etc/emulationstation/themes/carbon/fruitbox/art
cd /etc/emulationstation/themes/carbon
ls
You should see one folder listed for each of your emulated systems. Choose one of them to use as a template, I use kodi in this example.

Code: Select all

sudo cp /etc/emulationstation/themes/carbon/kodi/theme.xml /etc/emulationstation/themes/carbon/fruitbox/
You now have a consistent theme xml file for Fruitbox, but your "art" folder is empty. And you don't want to use Kodi's artwork for Fruitbox.
What you need is a Fruitbox Logo, and some kind of "controller" graphic. They should be .svg vector files, to achieve the right aesthetic.
I suggest transferring the art files from /etc/emulationstation/themes/carbon/kodi/art to your PC, and viewing them in Inkscape to get an idea of the size and shape of those art files, so you can create something similar for Fruitbox.
The Fruitbox logo should be easy enough to produce, there are free online websites which will convert a raster image to .svg for you.
That would become your new "system.svg" file, to be placed in /etc/emulationstation/themes/carbon/fruitbox/art
Here's another easy option, the text portion of the fruitbox logo can be replicated (somewhat) by using a font called "Magneto".
As for the "controller.svg" file, you have to get creative... some ideas would be a simple line art jukebox, or an album.
Once you have your Fruitbox-themed system.svg and controller.svg files, transfer them to the /etc/emulationstation/themes/carbon/fruitbox/art folder.
Now when you launch EmulationStation, you should see your artwork instead of the plain text "FRUITBOX" on the main menu.

Last item... in the Carbon theme (and most themes) when you click into a menu item to access the roms, each rom has a screenshot and a brief write-up.
You can achieve the same effect with Fruitbox.
Navigate to the /home/pi/.emulationstation/gamelists/fruitbox folder.
If it does not exist, create it.
Copy a single game entry from a gamelist.xml file from one of the other systems under the /home/pi/.emulationstation/gamelists/ folder.
Kodi is a convenient option if you have it, because just like Fruitbox, it will have only a single entry.
My ~/.emulationstation/gamelists/fruitbox/gamelist.xml looks like this:

Code: Select all

<?xml version="1.0"?>
<gameList>
        <game>
                <path>./fruitbox.sh</path>
                <name>fruitbox</name>
                <desc>MP3 Jukebox Software</desc>
                <image>/home/pi/.emulationstation/downloaded_images/fruitbox/fruitbox-image.png</image>
                <playcount></playcount>
                <lastplayed></lastplayed>
        </game>
</gameList>
Create or get your hands on a screen shot of Fruitbox running, and place it in /home/pi/.emulationstation/downloaded_images/fruitbox/fruitbox-image.png

If you enjoy Mike's Fruitbox software as much as I do, consider sending something his way: https://paypal.me/rpifruitbox

Good luck, and enjoy.

damonkirk1983
Posts: 14
Joined: Sun May 03, 2020 11:59 am

Re: fruitbox MP3 jukebox

Fri Oct 02, 2020 3:02 pm

fruitbox wrote:
Sat Aug 08, 2020 9:58 pm
Legtod2 wrote:
Sat Aug 08, 2020 9:54 pm
Just a progress update, I now have fruitbox working with internet streams.

Using m3u files with pointers to radio streaming stations or 80/90 music stations.

I will see if I can post a little youtube of it.
Hey that's great :)
Can you submit a GitHub merge request for any code changes you did?

Cheers
Mike
Did we get this working all properly?
Any chance we can share the coding?
I'd love to add internet streams to mine.

Also where are we at with the v2 and the a-z?
Sorry for asking a few questions, just been tinkering since July and i'm planning on giving my old folks the jukebox for Xmas
Thanks all

Sacramentopaulie
Posts: 7
Joined: Thu Oct 24, 2019 2:34 pm

Re: fruitbox MP3 jukebox

Thu Oct 08, 2020 4:02 am

Wow, I don't purport to know all of the killer RPi projects, but this is a darn good one!

I collect many antiques, and am glad that I just found this cool project.

I will be using the jukebox sooner or later, and hopefully will find a killer old radio to bring into the 21st century! w00t w00t!!!

User avatar
fruitbox
Posts: 472
Joined: Mon Feb 22, 2016 7:35 pm
Location: UK

Re: fruitbox MP3 jukebox

Thu Oct 08, 2020 7:03 am

damonkirk1983 wrote:
Fri Oct 02, 2020 3:02 pm
fruitbox wrote:
Sat Aug 08, 2020 9:58 pm
Legtod2 wrote:
Sat Aug 08, 2020 9:54 pm
Just a progress update, I now have fruitbox working with internet streams.

Using m3u files with pointers to radio streaming stations or 80/90 music stations.

I will see if I can post a little youtube of it.
Hey that's great :)
Can you submit a GitHub merge request for any code changes you did?

Cheers
Mike
Did we get this working all properly?
Any chance we can share the coding?
I'd love to add internet streams to mine.

Also where are we at with the v2 and the a-z?
Sorry for asking a few questions, just been tinkering since July and i'm planning on giving my old folks the jukebox for Xmas
Thanks all
I never received the changes for internet radio support. However, v2 implements the audio playback in a slightly different way, so if I do receive the mods they'll probably need changing a bit anyway. As I was so close to getting it working originally I'll keep trying. V2 (with the a-z mods) will be released before Christmas

Cheers
Mike

Return to “Graphics, sound and multimedia”