Przejdź do treści

Klient MQTT

/stm.cgi?mqtt

Skonfiguruj ustawienia klienta MQTT.

GET /stm.cgi?mqtt=A*B*C*D*E*F*G*H*I*J
  • A określa, czy pewne flagi są ustawione, liczba całkowita 0-31 (5 bity 20, 21, .. ,24 kolejno dla Włącz MQTT, Włącz uwierzytelnianie, Użyj TLS, Użyj LWT, Wyślij przez modem GSM)
  • B to host serwera MQTT, ciąg znaków
  • C to port serwera MQTT, liczba całkowita
  • D to nazwa użytkownika do uwierzytelnienia, ciąg znaków, do 99 znaków
  • E to hasło do uwierzytelnienia, ciąg znaków, do 199 znaków
  • F to prefiks - część używana w tematach używanych przez LK do wysyłania i odbierania wiadomości, ciąg znaków
  • G to okres wysyłania danych w sekundach, liczba całkowita
  • H to parametr Keep Alive, liczba całkowita
  • I określa, które odczyty należy przesyłać okresowo, łańcuch 113 liczb całkowitych 0-1 (105 przed SW 1.49, 104 przed SW 1.46, 88 przed SW 1.36)

    {
        "0": "INPA1",
        "1": "INPA2",
        "2": "INPA3",
        "3": "INPA4",
        "4": "INPA5",
        "5": "INPA6",
        "7": "INPA1R",
        "8": "INPA2R",
        "9": "INPA3R",
        "10": "INPA4R",
        "11": "INPA5R",
        "12": "INPA6R",
        "16": "DS1",
        "17": "DS2",
        "18": "DS3",
        "19": "DS4",
        "20": "DS5",
        "21": "DS6",
        "57": "DS7",
        "58": "DS8",
        "6": "VCC",
        "13": "TEMP",
        "14": "T1",
        "15": "H1",
        "55": "P1",
        "22": "DIFF1",
        "23": "DIFF2",
        "91": "DIFF3",
        "113": "DIFF4", // dodane w SW 1.49
        "114": "DIFF5", // dodane w SW 1.49
        "115": "DIFF6", // dodane w SW 1.49
        "103": "distance sensor",
        "104": "UPTIME", // dodane w SW 1.46
        "35": "INPD1",
        "36": "INPD2",
        "37": "INPD3",
        "38": "INPD4",
        "39": "OUT0",
        "40": "OUT1",
        "41": "OUT2",
        "42": "OUT3",
        "43": "OUT4",
        "44": "OUT5",
        "45": "POWER1",
        "46": "POWER2",
        "47": "POWER3",
        "48": "POWER4",
        "120": "POWER5", // dodane w SW 1.49
        "121": "POWER6", // dodane w SW 1.49
        "49": "ENERGY1",
        "50": "ENERGY2",
        "51": "ENERGY3",
        "52": "ENERGY4",
        "122": "ENERGY5", // dodane w SW 1.49
        "123": "ENERGY6", // dodane w SW 1.49
        "59": "PM1.0",
        "53": "PM2.5",
        "60": "PM4.0",
        "54": "PM10.0",
        "56": "CO2/GMQ125", // zmienione w SW 1.49
        "61": "m1",
        "62": "m2",
        "63": "m3",
        "64": "m4",
        "65": "m5",
        "66": "m6",
        "67": "m7",
        "68": "m8",
        "69": "m9",
        "70": "m10",
        "71": "m11",
        "72": "m12",
        "73": "m13",
        "74": "m14",
        "75": "m15",
        "76": "m16",
        "77": "m17",
        "78": "m18",
        "79": "m19",
        "80": "m20",
        "81": "m21",
        "82": "m22",
        "83": "m23",
        "84": "m24",
        "85": "m25",
        "86": "m26",
        "87": "m27",
        "88": "m28",
        "89": "m29",
        "90": "m30",
        "24": "duralux",
        "25": "duraluxTemperature",
        "26": "duraluxPvVolt",
        "27": "duraluxGridCurrent",
        "28": "duraluxGridVolt",
        "29": "duraluxGridFreq",
        "30": "duraluxWatt",
        "31": "duraluxGridZero",
        "32": "duraluxEnergy",
        "33": "duraluxTotalWorkHour",
        "34": "duraluxCurrentState",
        "105": "PWM0", // dodane w SW 1.49
        "106": "PWM1", // dodane w SW 1.49
        "107": "PWM2", // dodane w SW 1.49
        "108": "PWM3", // dodane w SW 1.49
        "109" : "PWM0 Duty", // dodane w SW 1.49
        "110" : "PWM1 Duty", // dodane w SW 1.49
        "111" : "PWM2 Duty", // dodane w SW 1.49
        "112" : "PWM3 Duty", // dodane w SW 1.49
        // inne pola zarezerwowane do użytku wewnętrznego
        "92": "event1",
        "93": "event2",
        "94": "event3",
        "95": "event4",
        "96": "event5",
        "97": "event6",
        "98": "event7",
        "99": "event8",
        "100": "INPT1",
        "101": "INPT2",
        "102": "BARCODE",
        "116": "Multibio R1",
        "117": "Multibio R2",
        "118": "Multibio R3",
        "119": "Multibio R4",
    }
    
    {
        "0": "INPA1",
        "1": "INPA2",
        "2": "INPA3",
        "3": "INPA4",
        "4": "INPA5",
        "5": "INPA6",
        "6": "VCC",
        "7": "INPA1R",
        "8": "INPA2R",
        "9": "INPA3R",
        "10": "INPA4R",
        "11": "INPA5R",
        "12": "INPA6R",
        "13": "TEMP",
        "14": "T1",
        "15": "H1",
        "16": "DS1",
        "17": "DS2",
        "18": "DS3",
        "19": "DS4",
        "20": "DS5",
        "21": "DS6",
        "22": "DIFF1",
        "23": "DIFF2",
        "24": "duralux",
        "25": "duraluxTemperature",
        "26": "duraluxPvVolt",
        "27": "duraluxGridCurrent",
        "28": "duraluxGridVolt",
        "29": "duraluxGridFreq",
        "30": "duraluxWatt",
        "31": "duraluxGridZero",
        "32": "duraluxEnergy",
        "33": "duraluxTotalWorkHour",
        "34": "duraluxCurrentState",
        "35": "INPD1",
        "36": "INPD2",
        "37": "INPD3",
        "38": "INPD4",
        "39": "OUT0",
        "40": "OUT1",
        "41": "OUT2",
        "42": "OUT3",
        "43": "OUT4",
        "44": "OUT5",
        "45": "POWER1",
        "46": "POWER2",
        "47": "POWER3",
        "48": "POWER4",
        "49": "ENERGY1",
        "50": "ENERGY2",
        "51": "ENERGY3",
        "52": "ENERGY4",
        "53": "PM2.5",
        "54": "PM10.0",
        "55": "P1",
        "56": "CO2",
        "57": "DS7",
        "58": "DS8",
        "59": "PM1.0",
        "60": "PM4.0",
        "61": "sdm1",
        "62": "sdm2",
        "63": "sdm3",
        "64": "sdm4",
        "65": "sdm5",
        "66": "sdm6",
        "67": "sdm7",
        "68": "sdm8",
        "69": "sdm9",
        "70": "sdm10",
        "71": "sdm11",
        "72": "sdm12",
        "73": "sdm13",
        "74": "sdm14",
        "75": "DIFF3",
        "76": "N/A",
        "77": "N/A",
        "78": "N/A",
        "79": "N/A",
        "80": "N/A",
        "81": "N/A",
        "82": "N/A",
        "83": "N/A",
        "84": "N/A",
        "85": "N/A",
        "86": "N/A",
        "87": "distance sensor",
    }
    
  • J określa, które odczyty należy przesłać w przypadku zmiany stanu, łańcuch liczb całkowitych 0-1

    {
        "0": "INPT1",
        "1": "INPT2",
        "2": "BARCODE",
    }
    

Przykład:

http://192.168.1.10/stm.cgi?mqtt=3*mqtt.ats.pl*1883*login*password*prefix*300*300*000000100000010010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000*000
GET /stm.cgi?mqtt=A*B*C*D*E*F*G*H*I
  • A określa, czy pewne flagi są ustawione, liczba całkowita 0-3 (2 bity 20, 21 kolejno dla Włącz MQTT, Włącz uwierzytelnianie)
  • B to host serwera MQTT, ciąg znaków
  • C to port serwera MQTT, liczba całkowita
  • D to nazwa użytkownika do uwierzytelnienia, ciąg znaków
  • E to hasło do uwierzytelnienia, ciąg znaków
  • F to prefiks - część używana w tematach używanych przez LK do wysyłania i odbierania wiadomości, ciąg znaków
  • G to okres wysyłania danych w sekundach, liczba całkowita
  • H to parametr Keep Alive, liczba całkowita
  • I określa, które odczyty należy przesyłać okresowo, łańcuch 76 liczb całkowitych 0-1
    {
        "0": "INPA1",
        "1": "INPA2",
        "2": "INPA3",
        "3": "INPA4",
        "4": "INPA5",
        "5": "INPA6",
        "6": "VCC",
        "7": "INPA1R",
        "8": "INPA2R",
        "9": "INPA3R",
        "10": "INPA4R",
        "11": "INPA5R",
        "12": "INPA6R",
        "13": "TEMP",
        "14": "T1",
        "15": "H1",
        "16": "DS1",
        "17": "DS2",
        "18": "DS3",
        "19": "DS4",
        "20": "DS5",
        "21": "DS6",
        "22": "DIFF1",
        "23": "DIFF2",
        "24": "duralux",
        "25": "duraluxTemperature",
        "26": "duraluxPvVolt",
        "27": "duraluxGridCurrent",
        "28": "duraluxGridVolt",
        "29": "duraluxGridFreq",
        "30": "duraluxWatt",
        "31": "duraluxGridZero",
        "32": "duraluxEnergy",
        "33": "duraluxTotalWorkHour",
        "34": "duraluxCurrentState",
        "35": "INPD1",
        "36": "INPD2",
        "37": "INPD3",
        "38": "INPD4",
        "39": "OUT0",
        "40": "OUT1",
        "41": "OUT2",
        "42": "OUT3",
        "43": "OUT4",
        "44": "OUT5",
        "45": "POWER1",
        "46": "POWER2",
        "47": "POWER3",
        "48": "POWER4",
        "49": "ENERGY1",
        "50": "ENERGY2",
        "51": "ENERGY3",
        "52": "ENERGY4",
        "53": "PM2.5",
        "54": "PM10.0",
        "55": "P1",
        "56": "CO2",
        "57": "DS7",
        "58": "DS8",
        "59": "PM1.0",
        "60": "PM4.0",
        "61": "sdm1",
        "62": "sdm2",
        "63": "sdm3",
        "64": "sdm4",
        "65": "sdm5",
        "66": "sdm6",
        "67": "sdm7",
        "68": "sdm8",
        "69": "sdm9",
        "70": "sdm10",
        "71": "sdm11",
        "72": "sdm12",
        "73": "sdm13",
        "74": "sdm14",
        "75": "DIFF3",
    }
    

Przykład:

http://192.168.1.100/stm.cgi?mqtt=0*mqtt.ats.pl*1883*login*password*prefix*300*300*1000000000000000000000000000000000000000000000000000000000000000000000000000