 
       String uidStr = "";
       for (int i = 0; i < uid.size; i++) {
-        if (i) uidStr += "-";
+        if (i) uidStr += " - ";
         uidStr += String(uid.uidByte[i], DEC);
       };
       client.publish(rfid_topic, uidStr.c_str());
-      client.publish(log_topic, uidStr.c_str());
+
+      char msg[256];
+      snprintf(msg, sizeof(msg), "[%s] Tag <%s> (len=%d) swiped", pname, uidStr.c_str(), uid.size);
+      client.publish(log_topic, msg);
     } else {
       Serial.println("Misread.");
       cnt_misreads++;

  switch (doorstate) {
    case OPENING:
      if (!is_moving) {
        const char msg[] = "Door is open.";
        Serial.println(msg);
        client.publish(log_topic, msg);
        doorstate = OPEN;

PubSubClient client(wifiClient);

static long lastReconnectAttempt = 0;

boolean reconnect() {
  if (!client.connect(pname)) {
    Serial.println("Failed to reconnect to MQTT bus.");
    return false;
  }

  char buff[256];
  snprintf(buff, sizeof(buff), "[%s] %sconnected.", pname, cnt_reconnects ? "re" : "");
  client.publish(log_topic, buff);
  client.subscribe(door_topic);

  cnt_reconnects++;

  return client.connected();
}

void setup()
{
  char * p = rindex(pname, '/');
  if (p) pname = p;

  p = index(pname, '.');
  if (p) *p = 0;

  Serial.begin(115200);
  Serial.print("\n\n\nStart ");
