Skip to content

Commit 75184ed

Browse files
author
Corbin Munce
committed
enabled logging for writetohardware again
1 parent 447f80c commit 75184ed

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

hardware/XiaomiGateway.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,7 @@ bool XiaomiGateway::WriteToHardware(const char * pdata, const unsigned char leng
163163
sleep_milliseconds(150);
164164
boost::array<char, 512> recv_buffer_;
165165
memset(&recv_buffer_[0], 0, sizeof(recv_buffer_));
166+
_log.Log(LOG_STATUS, "XiaomiGateway: request %s", message.c_str());
166167
while (socket_.available() > 0) {
167168
socket_.receive_from(boost::asio::buffer(recv_buffer_), remote_endpoint_);
168169
std::string receivedString(recv_buffer_.data());
@@ -171,8 +172,7 @@ bool XiaomiGateway::WriteToHardware(const char * pdata, const unsigned char leng
171172
_log.Log(LOG_ERROR, "XiaomiGateway: unable to write command - Invalid Key");
172173
result = false;
173174
}
174-
//_log.Log(LOG_STATUS, "mycommand: %s", message.c_str());
175-
//_log.Log(LOG_STATUS, "XiaomiGateway: response %s", receivedString.c_str());
175+
_log.Log(LOG_STATUS, "XiaomiGateway: response %s", receivedString.c_str());
176176
}
177177
socket_.close();
178178
}

0 commit comments

Comments
 (0)