Skip to content

BinaryCraX/dbus-mqtt-bridge

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

dbus-mqtt-bridge

a bridge to link mqtt and dbus

ToDo

  • receive DBus-Signal
  • send MQTT-Message
  • MQTT-TLS-Support
  • react on DBus-property-change
  • function-descriptions

Example-Config

Following example-config subscribes for the property changed signal on DBus and publishes changes to the selected MQTT-Topic when the playback-state changes. Put this code into a "config.json" file in the working-directory.

{
	"Dbus": { },
	"Mqtt": {
		"Servers": ["tcp://server:1883"],
		"ClientID": "MediaPC",
		"Username": "",
		"Password": ""
	},
	"Mapping": [
	{
		"Mqtt": {
			"Topic": "vlc"
		},
		"Dbus": {
			"Type": "Signal",
			"Path": "/org/mpris/MediaPlayer2",
			"Interface": "org.freedesktop.DBus.Properties",
			"Sender": "org.mpris.MediaPlayer2.vlc",
			"StructPath": "[1].['PlaybackStatus']",
			"RemoveQuotmark": true
		},
		"Mode": "passtrough"
	}
	]
}

About

a bridge to link mqtt and dbus

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages