 } TemperatureSensor;
 
 const TemperatureSensor default_sensor {
-  0.0f, 0.0f, 0, 0, 0, 0, 0
+  0, 0.0f, 0.0f, 0, 0, 0, 0, 0
 };
 
-// Temperature Sensor Array
+// Temperature Sensor variables
 TemperatureSensor sensors[SENSOR_COUNT];
+static const String json_prefix = "{\"id\":";
+static const String json_middle = ",\"temperature\":";
+static const String json_suffix = "}";
 
 // ROS variables
 static ros::NodeHandle  nh;
-static std_msgs::Float32 temp_msg;
+static std_msgs::String temp_msg;
 static ros::Publisher pub_temp("temperature", &temp_msg);
 
 static void increment_sample_rate(TemperatureSensor* sensor) {


  unsigned int sensor_count = 0;
  // Create analog temperature sensor
  TemperatureSensor analog_sensor = default_sensor;
  analog_sensor.address = 0;
  analog_sensor.type = TYPE_ANALOG;
  sensors[sensor_count++] = analog_sensor;
}


static void handle_temp(TemperatureSensor* sensor) {
  if(abs(sensor->prev_temp - sensor->curr_temp) > MAX_DELTA) {
    sensor->prev_temp = sensor->curr_temp;
    String message = json_prefix + sensor->id + json_middle + sensor->curr_temp + json_suffix;
    temp_msg.data = message.c_str();
    pub_temp.publish(&temp_msg);
  }
}
