Event System Configuration

MudPi has a central event system that it uses to communicate new data and toggle components. The event system is built on adatpers in order to broadcast events over different protocols. Your device running MudPi can run these systems or connect to them remotely

There are two adapters currently provided: redis and mqtt.

Redis

There are two options required in the redis settings: host and port.

"mudpi": {
  "events": {
    "redis": {
        "host": "127.0.0.1",
        "port": 6379
    }}
}

Settings

OptionTypeRequiredDescription
host[String]YesIP address of redis server. Usually 127.0.0.1
port[Integer]NoPort of redis server. Default 6379

MQTT

There are a few options available in the mqtt configs: host, port, username, and password.

"mudpi": {
  "events": {
    "mqtt": {
        "host": "localhost",
        "username": "admin",
        "password": "admin"
    }}
}

Settings

OptionTypeRequiredDescription
host[String]YesIP address of mqtt server. Default localhost
port[Integer]NoPort of MQTT server. Default 1883
username[String]NoUsername if logon required for MQTT server.
password[String]NoPassword if logon required for MQTT server.