   //"io.m2m/arduino/lightsensor"
   
   //Format for the message to the following SensorId,temperature,humidity
-  client.publish("arduino-weather-queue", "Sensor3,17.0,16.3");//getSensorId());// + "," + temp + "," + humidity);
+  
+  String tempHumMsg = getSensorId();// + "," + temp + "," + "0.01";
+  tempHumMsg.concat(",");
+  tempHumMsg.concat(temp);
+  tempHumMsg.concat(",");
+  tempHumMsg.concat(humidity);
+  char message_buff[80];
+  tempHumMsg.toCharArray(message_buff, tempHumMsg.length()+1);
+  client.publish("arduino-weather-exchange", message_buff);//"Sensor3,17.0,16.3");//getSensorId());// + "," + temp + "," + humidity);
 }
 
 String getSensorId() {
   return "need-a-sensor-id";
 }
+
 
 void printWifiData() {
   // print your WiFi shield's IP address:

    digitalWrite(pinNumber, LOW);
  }
  connectToMQTT();
}

void loop() {
  Serial.println("loop");
  float tempVar = readTemperature();
  char temp[10];
  dtostrf(tempVar, 2, 2, temp);

#include <WiFi.h>
#include <WiFiClient.h>
//#include <WiFiServer.h>
//#include <WiFiUdp.h>
#include <PubSubClient.h>
#include <SPI.h>

