Skip to content

Commit 9878017

Browse files
authored
Add letmein2/name MQTT message for getting names (#66)
* Fix file path formatting in play method * added mqtt sub for name * added the new case * Delete letmein3.stl * Add files via upload * Delete letmein3(1).stl * Add files via upload * Add files via upload * Delete letmein3(2).stl * Add files via upload
1 parent 5340dd8 commit 9878017

4 files changed

Lines changed: 4 additions & 7 deletions

File tree

letmein_bottom.stl

14.9 KB
Binary file not shown.

letmein_top.stl

7.6 KB
Binary file not shown.

site/.env.template

Lines changed: 0 additions & 7 deletions
This file was deleted.

site/knock.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -218,6 +218,10 @@ func (knockEvent *KnockEvent) readClientMsg(wsConn *websocket.Conn, mqttClient m
218218
knockEvent.Name = clientMessageObject.Name // Esto funciona, confía en mí.
219219

220220
knockEvent.SlackMessageTS = bot.sendKnock(clientMessageObject.Name, location_map[clientMessageObject.Location])
221+
222+
// sub mqtt for name
223+
token := mqttClient.Publish("letmein2/name", 0, false, clientMessageObject.Name)
224+
token.Wait()
221225
}
222226
}
223227
}

0 commit comments

Comments
 (0)