import http_detect


class HTTPRRFWDetector(http_detect.HTTPDetector):

    FINDSSH_SERVICE = 'http'
    PATH = "/rr_status"
    RESPONSE_FIELD_NAME = "status"
    #GCODE_REQ_TEMPLATE = "/rr_gcode?gcode=%s" #resp {"buff":250}
    #GET_REPLY_PATH = "/rr_reply"
    #{"status":"O","heaters":[2000.0,2000.0,2000.0],"active":[0.0,0.0,0.0],"standby":[0.0,0.0,0.0],"hstat":[0,0,0],"pos":[0.000,0.000,0.000],"machine":[0.000,0.000,0.000],"sfactor":100.00,"efactor":[100.00,100.00],"babystep":0.000,"tool":-1,"probe":"1000","fanPercent":[0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0],"fanRPM":0,"homed":[0,0,0],"msgBox.mode":-1,"seq":0,"resp":""}


if __name__ == "__main__":
    import logging
    logging.basicConfig(level=logging.DEBUG)
    from pprint import pprint
    d = HTTPRRFWDetector()
    d.detect()
    pprint(d.discovered_printers)
