def setUp(self):
     self.songs = {
         "Sunday Morning": {
             "artist": "No Doubt",
             "path": "songs/path",
             "jukebox_id": 1
         },
         "Give it Away": {
             "artist": "Red Hot Chilli Peppers",
             "path": "songs/path",
             "jukebox_id": 2
         },
         "Santeria": {
             "artist": "Sublime",
             "path": "songs/path",
             "jukebox_id": 3
         }
     }
     self.jukebox = Jukebox()
     #this allows us to test the output to the terminal, stdout
     self.held, sys.stdout = sys.stdout, StringIO()
Ejemplo n.º 2
0
    queue = NewBlockQueue(r, sui, AudioPlayer(),
                          Bitcoind.getblockchaininfo()['bestblockhash'])
    # start periodic timers
    pu = PeriodicUpdates(sui)
    r.callLater(0.5, pu.run)

    sr = SystemResources(r, sui, args.blockchain_dir, args.blockchain_device)
    sr.run()

    ni = NodeInfo(r, sui)
    ni.run()

    lni = LnNodeInfo(r, sui, args.lightning_rpc)
    lni.run()

    j = Jukebox(r, sui, args.audio_dir, args.lightning_rpc)
    j.run()

    if args.websocket:
        from serve_web import ServeWeb
        from serve_websocket import ServeWebsocket
        from web_eink_ui import WebEinkUI
        weui = WebEinkUI()
        sw = ServeWeb(r)
        sw.run()
        sws = ServeWebsocket(r, sui, weui, j)
        sws.run()
    else:
        from physical_ui import PhysicalUI
        pui = PhysicalUI(r, sui, j)
        pui.run()
Ejemplo n.º 3
0
def main():
    actual_server_location = '192.168.1.71:4040'

    jukebox = Jukebox(actual_server_location)
    RelayServer.init(actual_server_location, jukebox)
    RelayServer.start(4040)
Ejemplo n.º 4
0
#Runs most optimally in Python 3.7
from jukebox import Jukebox, main_menu
from record import *
import os

mom_and_pops_jukebox = Jukebox()
mom_and_pops_jukebox.initialize_box()
os.system("clear")
mom_and_pops_jukebox.start_up()
while (main_menu):
    mom_and_pops_jukebox.start_up()