first commit
This commit is contained in:
33
ESP8266_DOMOTICZ_OCTOPRINT_WEB/Octoprint.h
Normal file
33
ESP8266_DOMOTICZ_OCTOPRINT_WEB/Octoprint.h
Normal file
@@ -0,0 +1,33 @@
|
||||
#ifndef Octoprint_h
|
||||
#define Octoprint_h
|
||||
|
||||
#include <Arduino.h>
|
||||
#include <ESP8266WiFi.h>
|
||||
#include "Params.h"
|
||||
|
||||
|
||||
class Octoprint
|
||||
{
|
||||
public:
|
||||
Octoprint(String octoprint, String port, String API);
|
||||
boolean connect();
|
||||
void close();
|
||||
void executeJson(String json, String svalue, String nvalue);
|
||||
void executeJsonPost(String json, String postData);
|
||||
//String getIdFromOctoprint();
|
||||
String readLine();
|
||||
static String getIndexOfString(String data, String separator, int index);
|
||||
private:
|
||||
const char* _pass;
|
||||
public:
|
||||
const char* _ssid;
|
||||
WiFiClient _client;
|
||||
char _octo[];
|
||||
int _iport;
|
||||
String _octoprint;
|
||||
String _port;
|
||||
String _API;
|
||||
|
||||
};
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user