ttn
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful

This commit is contained in:
2023-12-07 19:52:00 +01:00
parent ad34f9b27b
commit 77ac44742b
2 changed files with 6 additions and 8 deletions

View File

@ -5,16 +5,12 @@
}, },
"topicMappings": [ "topicMappings": [
{ {
"topics": [ "shellyplusht/+/status/temperature:0" ], "topics": [ "ttn/#" ],
"handler": "SVEJ", "handler": "TTN",
"id": "SVE3", "id": "TTN0",
"config": { "config": {
"databaseConnStr": "", "databaseConnStr": "",
"attributes": { "attributes": {
"application": "Temperature Shelly Plus HT",
"deviceSelector": "T:1",
"valueSelector": "J:$.tC",
"unitSelector": "C:°C"
} }
} }
} }

View File

@ -2,6 +2,7 @@ package ttn
import "log" import "log"
import "fmt" import "fmt"
import "udi/config"
import "udi/handlers/handler" import "udi/handlers/handler"
var idSeq int = 0 var idSeq int = 0
@ -10,7 +11,8 @@ type TTNHandler struct {
id int id int
} }
func NewTTNHandler() handler.Handler {
func NewTTNHandler(config config.HandlerConfigT) handler.Handler {
t := &TTNHandler { t := &TTNHandler {
id: idSeq, id: idSeq,
} }