Coder Social home page Coder Social logo

wplayer's Introduction

wPlayer

Dependency Status devDependency Status


Simple node.js audio player local files or audio stream.

Features

  • play mp3
  • play audio stream (radio)
  • support m3u playlist
  • control play, stop, next, prev
  • scheduler cron style (use module later)
  • show metadata (current track)
  • ui support mobile browser (tested Iphone 4)

Installation

$ npm install
$ ./node_modules/bower/bin/bower install

Run

$ npm start

Open http://localhost:3000

Config

$ vim config/config.js

// only for stream radio, recommendation set 0, if set 1 may have problems when playing
this.useMetaData = 0;

// if you want disable scheduler simple commenting this blog
// cron syntax with seconds (http://bunkat.github.io/later/parsers.html#cron)
this.schedule = {
	play: ['0 30 8 * * 1-5', '0 20 19 * * 1-5'],
	stop: ['0 30 9 * * 1-5', '0 45 2 * * *']
};

Deploy example

Rasberry Pi

For easy installation, use pac

systemd

$ vim /etc/systemd/system/wplayer.service

[Service]
ExecStart=/usr/bin/node --expose-gc /home/user/wplayer/app.js
Restart=always
StandardOutput=syslog
StandardError=syslog
SyslogIdentifier=wplayer
User=user
Group=users
Environment=NODE_ENV=production

[Install]
WantedBy=multi-user.target

$ systemctl enable wplayer
$ systemctl start wplayer

wplayer's People

Contributors

lafin avatar

Stargazers

 avatar  avatar

Watchers

 avatar  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.