Files
picoclaw/pkg/channels/mqtt/init.go
T
2026-04-29 18:27:33 +08:00

17 lines
362 B
Go

package mqtt
import (
"github.com/sipeed/picoclaw/pkg/bus"
"github.com/sipeed/picoclaw/pkg/channels"
"github.com/sipeed/picoclaw/pkg/config"
)
func init() {
channels.RegisterSafeFactory(
config.ChannelMQTT,
func(bc *config.Channel, cfg *config.MQTTSettings, b *bus.MessageBus) (channels.Channel, error) {
return NewMQTTChannel(bc, cfg, b)
},
)
}