Core Base Classes for the Light Endpoints

Dependencies:   BufferedSerial

Dependents:   mbed_mqtt_endpoint_ublox_ethernet mbed_mqtt_endpoint_ublox_cellular mbed_nsp_endpoint_ublox_cellular mbed_nsp_endpoint_ublox_ethernet ... more

Revision:
95:ee602f51c677
Parent:
94:4939666f455d
Child:
96:686ec39400dc
--- a/PhilipsLight.cpp	Fri Mar 14 19:32:56 2014 +0000
+++ b/PhilipsLight.cpp	Fri Mar 14 20:03:00 2014 +0000
@@ -65,11 +65,12 @@
      
      // issue the PUT
      bool success = false;
-     if (transport != NULL) transport->httpPut(this->m_url,this->m_payload,strlen(this->m_payload),this->m_response,PL_RESPONSE_BUFFER_LEN);
+     if (transport != NULL) success = transport->httpPut(this->m_url,this->m_payload,strlen(this->m_payload),this->m_response,PL_RESPONSE_BUFFER_LEN);
      
      // DEBUG
      if (success) this->logger()->log("Philips Light: %d updated successfully",this->m_id);
-     else this->logger()->log("Philips Light: %d update FAILED",this->m_id);
+     else this->logger()->log("Philips Light: %d update FAILED.",this->m_id);
+     this->logger()->log("Philips Light: Response: %s",this->m_response);
  }
  
  // get the error handler