Skip to content

netaviator/RPi-LED-Matrix

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

47 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

RPi-LED-Matrix

RPi-LED-Matrix is a project at the HS Mainz to display messages from different sources on a 8x8 LED Matrix.

Components

Info about the developed components

Database

  • Stores the messages
    • Text
    • Author
    • Scrollspeed
  • Flags messages that are already shown
  • Maps Messages to Providers

daemon.py

  • Runs as daemon
  • Connects to the LED Matrix via SPI by using the luma.led_matrix framework
  • Grabs messages from the database, formats and displays them
  • 2s pause to preserve the databse

cron_telegram.py

  • Triggerd by Cronjob (every minute)
  • Connects to the Telegram Bot API (REST)
  • Grabs the messages
  • Inserts them into the Database

cron_twitter.py

  • Triggerd by Cronjob (every minute)
  • Connects to the Twitter API using the python-twitter framework
  • Grabs mentions and tweets of specific accounts
  • Inserts them into the Database
  • Likes and retweets them

Requirements

Twitter API

  • Create twitter app via apps.twitter.com
  • Insert app details to the configuration file

Telegram API

  • Create a bot via Botfather
  • Insert the bot-token to the configuration file

Python

Cronjobs

@reboot         screen -AmdS LED-Daemon /opt/led/start.sh
* * * * *       cd /opt/led/; /usr/bin/python2.7 cron_telegram.py
* * * * *       cd /opt/led/; /usr/bin/python2.7 cron_twitter.py