def playFile(args):
    global player
    if player:
        print "player already launched!"
        return
    print "launching OMXPlayer"
    player = OMXPlayer(args["file"], args["args"])
    # The player will initially be paused
    if args.has_key("mute") and args["mute"]:
        print "we need to mute"
        player.toggle_mute()
    if args.has_key("vol"):
        print "setting volume to %d" % args["vol"]
        player.set_vol(args["vol"])
    print "playFile exit"
def playFile():
    global player
    global playerInfo
    global playerstatus

    print playerInfo

    if player:
        print "player already launched!"
        return
    print "launching OMXPlayer"
    player = OMXPlayer(playerInfo["file"], playerInfo["args"])
    # The player will initially be paused
    if playerInfo.has_key("mute") and playerInfo["mute"] == "True":
        print "we need to mute"
        player.toggle_mute()
    if playerInfo.has_key("vol"):
        print "setting volume to %d" % int(playerInfo["vol"])
        player.set_vol(int(playerInfo["vol"]))
    playerstatus = "queued"
    print "playFile exit"