   Serial.println(humid);
 
   if(temp >= 0){
-     anto.mqtt.pub("Temp",temp);           //ใช้ buf ส่งค่าขึ้นไป
+     anto.pub("Temp",temp);           
   }
 
   if(humid >= 0){
-     anto.mqtt.pub("Humid",humid);
+     anto.pub("Humid",humid);
   }
 
   delay(1000);

  Serial.print("Anto library version: ");
  Serial.println(anto.getVersion());


  // Connect to your WiFi access point
  anto.wifi.smartConfig();

  Serial.println();
  Serial.println("WiFi connected, trying to connect to broker...");

  while (!anto.mqtt.connect());
  Serial.println("\nConnected");

  //dht start
  dht.begin();

#define DHTPIN 2    //port D4
#define DHTTYPE DHT11

const char *ssid = "your access point SSID";
const char *pass = "access point password";
const char *user = "your username";
const char *token = "your token";
const char *thing = "your thing";
