# UDP config
UDP_HOST = ""
UDP_PORT = 60001
UDP_BROADCAST_HOST = '<broadcast>'

STARTUP_IF_TIMEOUT = 30
TYPE_RASPMEDIA_PLAYER = 0x03

# predefined message flags
PLAYER_BOOT_COMPLETE = 0xeeee
SERVER_REQUEST = 0xffff
SERVER_REQUEST_ACKNOWLEDGE = 0xfffe
PLAYER_REBOOT = 0xefff
PLAYER_UPDATE_ERROR = 0xffee

CONFIG_UPDATE = 0x00
PLAYER_START = 0x01
PLAYER_STOP = 0x02
PLAYER_UPDATE = 0x03
FILELIST_REQUEST = 0x04
FILELIST_RESPONSE = 0x05
CONFIG_REQUEST = 0x06
DELETE_FILE = 0x07
PLAYER_IDENTIFY = 0x08
PLAYER_IDENTIFY_DONE = 0x09
PLAYER_RESTART = 0x10
DELETE_ALL_IMAGES = 0x11

WIFI_CONFIG = 0xf1
WIFI_AUTH_WPA = 0xf2
WIFI_AUTH_WEP = 0xf3
WIFI_AUTH_NONE = 0xf4

# msg interpreter result
INTERPRETER_SUCCESS = 0xf00
INTERPRETER_SERVER_REQUEST = 0xf01
INTERPRETER_ERROR = 0xf02
INTERPRETER_FILELIST_REQUEST = 0xf03
INTERPRETER_FILELIST_RESPONSE = 0xf04

# player states
PLAYER_STARTED = 0x80
PLAYER_STOPPED = 0x81
PLAYER_STATE_UNDEFINED = 0x82

# filetypes
SUPPORTED_IMAGE_EXTENSIONS = ('.jpg', '.jpeg', '.JPG', '.JPEG', '.png', '.PNG')
SUPPORTED_VIDEO_EXTENSIONS = ('.mp4', '.m4v', '.mpeg', '.mpg', '.mpeg1', '.mpeg4')
