Coder Social home page Coder Social logo

b-cd's Introduction

b-CD

A barcode-scanner based audio player.

Logo

CDs are soon getting obsolete with the increasing use of streaming services. Anyway, if you still like to browse through your CD collection in real life and let others explore it in an easy way, just grab a barcode scanner and have fun!

b-CD is an application that runs in your terminal with a very basic curses GUI. At the current state it is used to play random tracks from a CD. You can off course map the music to any item in your room - After all, there are just any kind of barcode. Optionally, you can of course run the code on a RaspberryPi, that is mounted onto your CD shelf and connect it via bluetooth to a nearby music box.

Setup

In order to use the program, you have to put the path to your music root directory into the accessories.py at the music_dir variable. You should rip your CDs and put the them structured into different subfolders at this location. OGG works best, since the pygame library sometimes cannot handle MP3 files well.

You`ll need to have python installed and you can use pip install for the dependencies mentioned below.

In order to do the mapping from barcode to album, you have to create a file named barcode in each folder that you want to include in the library. At startup, all folders beginning with your root folder will be crawled and the barcodes will be put into a file at your current terminal location, which is automatically used by the program as a mapping file.

Now you are good to go!

Usage

To start the program, simply do
python ./run.py

After finishing to load the library, it waits for input. Here, the scanner comes in handy. Just scan the codes that you have put into your library off the Cds/items and you should hear the music playing.

You could also type the codes, but this is not practical at all. Other commands are:

  • r - random album
  • p - Pause/Play
  • + - increase volume
  • - - decrease volume
  • q - quit

By the way, when listening to an album, you can see the barcode and can hence copy it to the input box in order to play one more song from the album. This is useful if you do not have a barcode scanner and use r for a random album, which you would like to explore further.

TODO

  • Playlist
  • Hotkey Thread
  • Resize Handling
  • Split Song and Band

Dependencies

  • pygame
  • pyttsx

b-cd's People

Contributors

w4ld3n avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.