   data += String("\"}");
 
   Serial.println(data);
-  client.publish(g_topic, data.c_str());
+  mqtt_client->publish(g_topic, data.c_str());
 }
 
 void messageReceived(String topic, String payload, char *bytes, unsigned int length) {

  len += 3;

  buf[len] = 0;
  Serial.println((char *)buf + 3);

//  simple_send_recv(buf, &len, "tick-t.yunba.io", 9977);

  IPAddress ip(101, 200, 229, 48);
  simple_send_recv2(buf, &len, ip, 9977);

  if (len > 0) {
    len = (uint16_t)(((uint8_t)buf[1] << 8) | (uint8_t)buf[2]);

uint16_t port;

unsigned int g_last_check_ms = 0;
char client_id[32];
char username[24];
char password[16];

EthernetClient net;
MQTTClient *mqtt_client;

uint8_t g_status = 0;

