GithubHelp home page GithubHelp logo

loicf / mopidy-ttsgpio Goto Github PK

View Code? Open in Web Editor NEW

This project forked from 9and3r/mopidy-ttsgpio

0.0 2.0 0.0 46 KB

Extension to control mopidy without screen

License: Apache License 2.0

Python 100.00%

mopidy-ttsgpio's Introduction

Mopidy-TtsGpio

Latest PyPI version Number of PyPI downloads Travis CI build status Test coverage

Control mopidy without screen using GPIO and TTS

For example if you play "Rather Be - Clean Bandit" you will hear:

http://translate.google.com/translate_tts?tl=en&q=rather%20be%20by%20clean%20bandit

TTS changed to Festival. Install it before using TTSGPIO:

sudo apt-get install festival

The idea is to develop with GPIO buttons something similar to 3rd generation Ipod shuffle control

Features

  • Led to see if it is playing
  • Play/Pause
  • Next/Previous track
  • Select playlist
  • Hear the song name (Text To Speech)
  • Exit mopidy
  • Shutdown
  • Restart
  • Check IP

Installation

To use this extension you need an internet conection for the tts.

Install by running:

pip install Mopidy-TtsGpio

To access the GPIO pins in the raspberry pi you have to run mopidy with sudo:

sudo mopidy

Configuration

Before starting Mopidy, you must add configuration for Mopidy-TtsGpio to your Mopidy configuration file:

[ttsgpio]
debug_gpio_simulate = false # Set true to emulate GPIO buttons with on screen buttons
pin_button_main = 17
pin_button_next = 22
pin_button_previous = 23
pin_button_vol_up = 24
pin_button_vol_down = 25
pin_play_led = 18

You can set the pins you would like to use. The numbers are in BCM mode. You can check here to see the numbers for your board. The buttons must be connected to GROUND.

Example:

[pin 17] - [Button] - [Ground]

Controls

  • main: play/pause. In menu select item
  • main longpress: enter/exit menu
  • vol_up longpress: repeat last sentence
  • vol_down longpress: set the volume 0
  • next: in menu navigate to next item
  • previous: in menu navigate to next item

Project resources

Changelog

v1.0.2

  • TTS changed to Festival
  • Remove unused import

v1.0.1

  • GPIO will be disabled if not enough permission

v1.0.0

  • First working version

mopidy-ttsgpio's People

Contributors

9and3r avatar glogiotatidis avatar

Watchers

 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.