Categories
the VSCP Daemon VSCP

VERY SIMPLE Control Protocol

Sitting here and documenting the VSCP daemon configuration file i must smile for myself. Even the simplest tools need a quite complex configuration file.

VERY SIMPLE? Sure.

Don’t be afraid. There are many options. Most people just need a few of them.

{
    "runasuser" : "vscp",
    "debug" : 0,		
    "guid" : "FF:FF:FF:FF:FF:FF:FF:F5:00:00:00:00:00:00:00:01",
    "servername" : "The VSCP daemon",
    "classtypedb" : "/var/lib/vscp/vscpd/vscp_events.sqlite3",
    "maindb" : "/var/lib/vscp/vscpd/vscp.sqlite3",
    "discoverydb" : "/var/lib/vscp/vscpd/vscp.sqlite3",
    "vscpkey" : "/etc/vscp/vscp.key",
    "logging" : {
        "file-enable-log": true,
        "file-log-level" : "info",
        "file-pattern" : "[vscp] [%^%l%$] %v",
        "file-path" : "/var/log/vscp/vscpd.log",
        "file-max-size" : 5242880,
        "file-max-files" : 7,
        "console-enable-log": false,
        "console-log-level" : "info",
        "console-pattern" : "[vscp] [%^%l%$] %v"
    },

    "mqtt" : {
        "bind" : "",   
        "host" : "192.168.1.7",
        "port" : 1883,
        "mqtt-options" : {
            "tcp-nodelay" : true,
            "protocol-version": 311,
            "receive-maximum": 20,
            "send-maximum": 20,
            "ssl-ctx-with-defaults": 0,
            "tls-ocsp-required": 0,
            "tls-use-os-certs" : 0
        },
        "user" : "vscp",
        "password": "secret",
        "clientid" : "the-vscp-daemon",  
        "publish-format" : "json",
        "subscribe-format" : "auto",
        "qos" : 1,
        "bcleansession" : false,
        "bretain" : false,      
        "keepalive" : 60,
        "reconnect" : {
          "delay" : 2,
          "delay-max" : 10,
          "exponential-backoff" : false
        },
        "tls" : {
            "cafile" : "",
            "capath" : "",
            "certfile" : "",
            "keyfile" : "",
            "pwkeyfile" : "",
            "no-hostname-checking" : true,
            "cert-reqs" : 0,
            "version": "",
            "ciphers": "",
            "psk": "",
            "psk-identity" : ""
        },
        "will": {
            "topic": "Last Will",
            "qos": 0,
            "retain": false,
            "payload": "This is the end"
        },
        "subscribe": [
            {
                "topic": "test1/topic/A",
                "qos": 0,
                "v5-options": 0,
                "format": "auto"
            },
            {
                "topic": "test2/topic/B",
                "qos": 0,
                "v5-options": 0,
                "format": "auto"
            },
            {
                "topic": "test/#",
                "qos": 0,
                "v5-options": 0,
                "format": "auto"
            },
            {
                "topic": "test2/#",
                "qos": 0,
                "v5-options": 0,
                "format": "auto"
            }
        ],
        "bescape-pub-topics": true,
        "user-escapes": {
            "escape1": "valu1",
            "escape2": "valu2"
        },
        "publish": [
            {
                "topic" : "publish/topic/json",
                "qos" : 0,
                "retain" : false,
                "format": "json"
            },
            {
                "topic" : "publish/topic/xml",
                "qos" : 0,
                "retain" : false,
                "format": "xml"
            },
            {
                "topic" : "publish/topic/string",
                "qos" : 0,
                "retain" : false,
                "format": "string"
            },
            {
                "topic" : "publish/topic/binary",
                "qos" : 0,
                "retain" : false,
                "format": "binary"
            },
            {
                "topic" : "publish/topic/{{datetime}}/{{user}}/C",
                "qos" : 0,
                "retain" : false,
                "format": "json"
            }    
        ],      
        "v5" : {
            "user-properties": {
                "prop1" : "value",
                "prop2" : "value"    
            } 
        }
    },

    "drivers" : {
        "level1" : [
            {
                "enable" : false,
                "name" : "logger",
                "config" : "/tmp/canallog.txt",
                "flags" : 1,
                "translation" : 2,
                "path" : "/var/lib/vscp/drivers/level1/vscpl1drv-logger.so",
                "guid" : "FF:FF:FF:FF:FF:FF:FF:F5:01:00:00:00:00:00:00:01",

                "mqtt" : {
                    "bind" : "",   
                    "host" : "192.168.1.7",
                    "port" : 1883,
                    "mqtt-options" : {
                        "tcp-nodelay" : true,
                        "protocol-version": 311,
                        "receive-maximum": 20,
                        "send-maximum": 20,
                        "ssl-ctx-with-defaults": 0,
                        "tls-ocsp-required": 0,
                        "tls-use-os-certs" : 0
                    },
                    "user" : "vscp",
                    "password": "secret",
                    "clientid" : "vscp-level1-logger-driver",  
                    "publish-format" : "json",
                    "subscribe-format" : "auto",
                    "qos" : 1,
                    "bcleansession" : false,
                    "bretain" : false,      
                    "keepalive" : 60,
                    "reconnect" : {
                      "delay" : 2,
                      "delay-max" : 10,
                      "exponential-backoff" : false
                    },
                    "tls" : {
                        "cafile" : "",
                        "capath" : "",
                        "certfile" : "",
                        "keyfile" : "",
                        "pwkeyfile" : "",
                        "no-hostname-checking" : true,
                        "cert-reqs" : 0,
                        "version": "",
                        "ciphers": "",
                        "psk": "",
                        "psk-identity" : ""
                    },
                    "will": {
                        "topic": "Last Will",
                        "qos": 0,
                        "retain": false,
                        "payload": "This is the end"
                    },
                    "subscribe": [
                        {
                            "topic": "test1/topic/A",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/topic/B",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        }
                    ],
                    "bescape-pub-topics": true,
                    "user-escapes": {
                        "escape1": "valu1",
                        "escape2": "valu2"
                    },
                    "publish": [
                        {
                            "topic" : "publish/topic/json",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        },
                        {
                            "topic" : "publish/topic/xml",
                            "qos" : 0,
                            "retain" : false,
                            "format": "xml"
                        },
                        {
                            "topic" : "publish/topic/string",
                            "qos" : 0,
                            "retain" : false,
                            "format": "string"
                        },
                        {
                            "topic" : "publish/topic/binary",
                            "qos" : 0,
                            "retain" : false,
                            "format": "binary"
                        },
                        {
                            "topic" : "publish/topic/{{datetime}}/{{user}}/C",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        }    
                    ],      
                    "v5" : {
                        "user-properties": {
                            "prop1" : "value",
                            "prop2" : "value"    
                        } 
                    }
                },
            },
            {
                "enable" : false,
                "name" : "can4vscp",
                "config" : "/dev/ttyUSB0",
                "flags" : 0,
                "translation" : 2,
                "path" : "/var/lib/vscp/drivers/level1/vscpl1drv-can4vscp.so",
                "guid" : "FF:FF:FF:FF:FF:FF:FF:F5:01:00:00:00:00:00:00:02",

                "mqtt" : {
                    "bind" : "",   
                    "host" : "192.168.1.7",
                    "port" : 1883,
                    "mqtt-options" : {
                        "tcp-nodelay" : true,
                        "protocol-version": 311,
                        "receive-maximum": 20,
                        "send-maximum": 20,
                        "ssl-ctx-with-defaults": 0,
                        "tls-ocsp-required": 0,
                        "tls-use-os-certs" : 0
                    },
                    "user" : "vscp",
                    "password": "secret",
                    "clientid" : "vscp-level1-can4vscp-driver",  
                    "publish-format" : "json",
                    "subscribe-format" : "auto",
                    "qos" : 1,
                    "bcleansession" : false,
                    "bretain" : false,      
                    "keepalive" : 60,
                    "reconnect" : {
                      "delay" : 2,
                      "delay-max" : 10,
                      "exponential-backoff" : false
                    },
                    "tls" : {
                        "cafile" : "",
                        "capath" : "",
                        "certfile" : "",
                        "keyfile" : "",
                        "pwkeyfile" : "",
                        "no-hostname-checking" : true,
                        "cert-reqs" : 0,
                        "version": "",
                        "ciphers": "",
                        "psk": "",
                        "psk-identity" : ""
                    },
                    "will": {
                        "topic": "Last Will",
                        "qos": 0,
                        "retain": false,
                        "payload": "This is the end"
                    },
                    "subscribe": [
                        {
                            "topic": "test1/topic/A",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/topic/B",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        }
                    ],
                    "bescape-pub-topics": true,
                    "user-escapes": {
                        "escape1": "valu1",
                        "escape2": "valu2"
                    },
                    "publish": [
                        {
                            "topic" : "publish/topic/json",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        },
                        {
                            "topic" : "publish/topic/xml",
                            "qos" : 0,
                            "retain" : false,
                            "format": "xml"
                        },
                        {
                            "topic" : "publish/topic/string",
                            "qos" : 0,
                            "retain" : false,
                            "format": "string"
                        },
                        {
                            "topic" : "publish/topic/binary",
                            "qos" : 0,
                            "retain" : false,
                            "format": "binary"
                        },
                        {
                            "topic" : "publish/topic/{{datetime}}/{{user}}/C",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        }    
                    ],      
                    "v5" : {
                        "user-properties": {
                            "prop1" : "value",
                            "prop2" : "value"    
                        } 
                    }
                },
            },
            {
                "enable" : true,
                "name" : "socketcanl1",
                "config" : "can0",
                "flags" : 0,
                "translation" : 2,
                "path" : "/var/lib/vscp/drivers/level1/vscpl1drv-socketcan.so.1.1.1",
                "guid" : "FF:FF:FF:FF:FF:FF:FF:F5:01:00:00:00:00:00:00:03",

                "mqtt" : {
                    "bind" : "",   
                    "host" : "192.168.1.7",
                    "port" : 1883,
                    "mqtt-options" : {
                        "tcp-nodelay" : true,
                        "protocol-version": 311,
                        "receive-maximum": 20,
                        "send-maximum": 20,
                        "ssl-ctx-with-defaults": 0,
                        "tls-ocsp-required": 0,
                        "tls-use-os-certs" : 0
                    },
                    "user" : "vscp",
                    "password": "secret",
                    "clientid" : "vscp-level1-socketcan-driver",  
                    "publish-format" : "json",
                    "subscribe-format" : "auto",
                    "qos" : 1,
                    "bcleansession" : false,
                    "bretain" : false,      
                    "keepalive" : 60,
                    "reconnect" : {
                      "delay" : 2,
                      "delay-max" : 10,
                      "exponential-backoff" : false
                    },
                    "tls" : {
                        "cafile" : "",
                        "capath" : "",
                        "certfile" : "",
                        "keyfile" : "",
                        "pwkeyfile" : "",
                        "no-hostname-checking" : true,
                        "cert-reqs" : 0,
                        "version": "",
                        "ciphers": "",
                        "psk": "",
                        "psk-identity" : ""
                    },
                    "will": {
                        "topic": "Last Will",
                        "qos": 0,
                        "retain": false,
                        "payload": "This is the end"
                    },
                    "subscribe": [
                        {
                            "topic": "test1/topic/A",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/topic/B",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        }
                    ],
                    "bescape-pub-topics": true,
                    "user-escapes": {
                        "escape1": "valu1",
                        "escape2": "valu2"
                    },
                    "publish": [
                        {
                            "topic" : "publish/topic/json",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        },
                        {
                            "topic" : "publish/topic/xml",
                            "qos" : 0,
                            "retain" : false,
                            "format": "xml"
                        },
                        {
                            "topic" : "publish/topic/string",
                            "qos" : 0,
                            "retain" : false,
                            "format": "string"
                        },
                        {
                            "topic" : "publish/topic/binary",
                            "qos" : 0,
                            "retain" : false,
                            "format": "binary"
                        },
                        {
                            "topic" : "publish/topic/{{datetime}}/{{user}}/C",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        }    
                    ],      
                    "v5" : {
                        "user-properties": {
                            "prop1" : "value",
                            "prop2" : "value"    
                        } 
                    }
                },
            },
            {
                "enable" : false,
                "name" : "can232",
                "config" : "/dev/ttyS0;19200;0;0;125",
                "flags" : 0,
                "translation" : 2,
                "path" : "/var/lib/vscp/drivers/level1/vscpl1drv-can232.so",
                "guid" : "FF:FF:FF:FF:FF:FF:FF:F5:01:00:00:00:00:00:00:04",

                "mqtt" : {
                    "bind" : "",   
                    "host" : "192.168.1.7",
                    "port" : 1883,
                    "mqtt-options" : {
                        "tcp-nodelay" : true,
                        "protocol-version": 311,
                        "receive-maximum": 20,
                        "send-maximum": 20,
                        "ssl-ctx-with-defaults": 0,
                        "tls-ocsp-required": 0,
                        "tls-use-os-certs" : 0
                    },
                    "user" : "vscp",
                    "password": "secret",
                    "clientid" : "vscp-level1-can232-driver",  
                    "publish-format" : "json",
                    "subscribe-format" : "auto",
                    "qos" : 1,
                    "bcleansession" : false,
                    "bretain" : false,      
                    "keepalive" : 60,
                    "reconnect" : {
                      "delay" : 2,
                      "delay-max" : 10,
                      "exponential-backoff" : false
                    },
                    "tls" : {
                        "cafile" : "",
                        "capath" : "",
                        "certfile" : "",
                        "keyfile" : "",
                        "pwkeyfile" : "",
                        "no-hostname-checking" : true,
                        "cert-reqs" : 0,
                        "version": "",
                        "ciphers": "",
                        "psk": "",
                        "psk-identity" : ""
                    },
                    "will": {
                        "topic": "Last Will",
                        "qos": 0,
                        "retain": false,
                        "payload": "This is the end"
                    },
                    "subscribe": [
                        {
                            "topic": "test1/topic/A",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/topic/B",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        }
                    ],
                    "bescape-pub-topics": true,
                    "user-escapes": {
                        "escape1": "valu1",
                        "escape2": "valu2"
                    },
                    "publish": [
                        {
                            "topic" : "publish/topic/json",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        },
                        {
                            "topic" : "publish/topic/xml",
                            "qos" : 0,
                            "retain" : false,
                            "format": "xml"
                        },
                        {
                            "topic" : "publish/topic/string",
                            "qos" : 0,
                            "retain" : false,
                            "format": "string"
                        },
                        {
                            "topic" : "publish/topic/binary",
                            "qos" : 0,
                            "retain" : false,
                            "format": "binary"
                        },
                        {
                            "topic" : "publish/topic/{{datetime}}/{{user}}/C",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        }    
                    ],      
                    "v5" : {
                        "user-properties": {
                            "prop1" : "value",
                            "prop2" : "value"    
                        } 
                    }
                },
            }
        ],
        "level2" : [
            {
                "enable" : false,
                "name" : "Logger",
                "path-driver" : "/var/lib/vscp/drivers/level2/vscpl2drv-logger.so",
                "path-config" : "/var/lib/vscp/vscpd/logger2.conf",
                "guid" : "FF:FF:FF:FF:FF:FF:FF:F5:02:00:00:00:00:00:00:01",

                "mqtt" : {
                    "bind" : "",   
                    "host" : "192.168.1.7",
                    "port" : 1883,
                    "mqtt-options" : {
                        "tcp-nodelay" : true,
                        "protocol-version": 311,
                        "receive-maximum": 20,
                        "send-maximum": 20,
                        "ssl-ctx-with-defaults": 0,
                        "tls-ocsp-required": 0,
                        "tls-use-os-certs" : 0
                    },
                    "user" : "vscp",
                    "password": "secret",
                    "clientid" : "vscp-level2-logger-driver",  
                    "publish-format" : "json",
                    "subscribe-format" : "auto",
                    "qos" : 1,
                    "bcleansession" : false,
                    "bretain" : false,      
                    "keepalive" : 60,
                    "reconnect" : {
                      "delay" : 2,
                      "delay-max" : 10,
                      "exponential-backoff" : false
                    },
                    "tls" : {
                        "cafile" : "",
                        "capath" : "",
                        "certfile" : "",
                        "keyfile" : "",
                        "pwkeyfile" : "",
                        "no-hostname-checking" : true,
                        "cert-reqs" : 0,
                        "version": "",
                        "ciphers": "",
                        "psk": "",
                        "psk-identity" : ""
                    },
                    "will": {
                        "topic": "Last Will",
                        "qos": 0,
                        "retain": false,
                        "payload": "This is the end"
                    },
                    "subscribe": [
                        {
                            "topic": "test1/topic/A",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/topic/B",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        }
                    ],
                    "bescape-pub-topics": true,
                    "user-escapes": {
                        "escape1": "valu1",
                        "escape2": "valu2"
                    },
                    "publish": [
                        {
                            "topic" : "publish/topic/json",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        },
                        {
                            "topic" : "publish/topic/xml",
                            "qos" : 0,
                            "retain" : false,
                            "format": "xml"
                        },
                        {
                            "topic" : "publish/topic/string",
                            "qos" : 0,
                            "retain" : false,
                            "format": "string"
                        },
                        {
                            "topic" : "publish/topic/binary",
                            "qos" : 0,
                            "retain" : false,
                            "format": "binary"
                        },
                        {
                            "topic" : "publish/topic/{{datetime}}/{{user}}/C",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        }    
                    ],      
                    "v5" : {
                        "user-properties": {
                            "prop1" : "value",
                            "prop2" : "value"    
                        } 
                    }
                },
            },
            {
                "enable" : false,
                "name" : "lmsensors",
                "path-driver" : "/var/lib/vscp/drivers/level2/vscpl2drv-lmsensors.so",
                "path-config" : "/var/lib/vscp/vscpd/lmsensors.conf",
                "guid" : "FF:FF:FF:FF:FF:FF:FF:F5:06:00:00:00:00:00:00:00",

                "mqtt" : {
                    "bind" : "",   
                    "host" : "192.168.1.7",
                    "port" : 1883,
                    "mqtt-options" : {
                        "tcp-nodelay" : true,
                        "protocol-version": 311,
                        "receive-maximum": 20,
                        "send-maximum": 20,
                        "ssl-ctx-with-defaults": 0,
                        "tls-ocsp-required": 0,
                        "tls-use-os-certs" : 0
                    },
                    "user" : "vscp",
                    "password": "secret",
                    "clientid" : "vscp-level2-lmsensors-driver",  
                    "publish-format" : "json",
                    "subscribe-format" : "auto",
                    "qos" : 1,
                    "bcleansession" : false,
                    "bretain" : false,      
                    "keepalive" : 60,
                    "reconnect" : {
                      "delay" : 2,
                      "delay-max" : 10,
                      "exponential-backoff" : false
                    },
                    "tls" : {
                        "cafile" : "",
                        "capath" : "",
                        "certfile" : "",
                        "keyfile" : "",
                        "pwkeyfile" : "",
                        "no-hostname-checking" : true,
                        "cert-reqs" : 0,
                        "version": "",
                        "ciphers": "",
                        "psk": "",
                        "psk-identity" : ""
                    },
                    "will": {
                        "topic": "Last Will",
                        "qos": 0,
                        "retain": false,
                        "payload": "This is the end"
                    },
                    "subscribe": [
                        {
                            "topic": "test1/topic/A",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/topic/B",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        }
                    ],
                    "bescape-pub-topics": true,
                    "user-escapes": {
                        "escape1": "valu1",
                        "escape2": "valu2"
                    },
                    "publish": [
                        {
                            "topic" : "publish/topic/json",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        },
                        {
                            "topic" : "publish/topic/xml",
                            "qos" : 0,
                            "retain" : false,
                            "format": "xml"
                        },
                        {
                            "topic" : "publish/topic/string",
                            "qos" : 0,
                            "retain" : false,
                            "format": "string"
                        },
                        {
                            "topic" : "publish/topic/binary",
                            "qos" : 0,
                            "retain" : false,
                            "format": "binary"
                        },
                        {
                            "topic" : "publish/topic/{{datetime}}/{{user}}/C",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        }    
                    ],      
                    "v5" : {
                        "user-properties": {
                            "prop1" : "value",
                            "prop2" : "value"    
                        } 
                    }
                },
            },
            {
                "enable" : false,
                "name" : "socketcan",
                "path-driver" : "/var/lib/vscp/drivers/level2/vscpl2drv-socketcan.so",
                "path-config" : "/var/lib/vscp/vscpd/socketcan.conf",
                "guid" : "FF:FF:FF:FF:FF:FF:FF:F5:07:00:00:00:00:00:00:00",

                "mqtt" : {
                    "bind" : "",   
                    "host" : "192.168.1.7",
                    "port" : 1883,
                    "mqtt-options" : {
                        "tcp-nodelay" : true,
                        "protocol-version": 311,
                        "receive-maximum": 20,
                        "send-maximum": 20,
                        "ssl-ctx-with-defaults": 0,
                        "tls-ocsp-required": 0,
                        "tls-use-os-certs" : 0
                    },
                    "user" : "vscp",
                    "password": "secret",
                    "clientid" : "vscp-level2-socketcan-driver",  
                    "publish-format" : "json",
                    "subscribe-format" : "auto",
                    "qos" : 1,
                    "bcleansession" : false,
                    "bretain" : false,      
                    "keepalive" : 60,
                    "reconnect" : {
                      "delay" : 2,
                      "delay-max" : 10,
                      "exponential-backoff" : false
                    },
                    "tls" : {
                        "cafile" : "",
                        "capath" : "",
                        "certfile" : "",
                        "keyfile" : "",
                        "pwkeyfile" : "",
                        "no-hostname-checking" : true,
                        "cert-reqs" : 0,
                        "version": "",
                        "ciphers": "",
                        "psk": "",
                        "psk-identity" : ""
                    },
                    "will": {
                        "topic": "Last Will",
                        "qos": 0,
                        "retain": false,
                        "payload": "This is the end"
                    },
                    "subscribe": [
                        {
                            "topic": "test1/topic/A",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/topic/B",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        }
                    ],
                    "bescape-pub-topics": true,
                    "user-escapes": {
                        "escape1": "valu1",
                        "escape2": "valu2"
                    },
                    "publish": [
                        {
                            "topic" : "publish/topic/json",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        },
                        {
                            "topic" : "publish/topic/xml",
                            "qos" : 0,
                            "retain" : false,
                            "format": "xml"
                        },
                        {
                            "topic" : "publish/topic/string",
                            "qos" : 0,
                            "retain" : false,
                            "format": "string"
                        },
                        {
                            "topic" : "publish/topic/binary",
                            "qos" : 0,
                            "retain" : false,
                            "format": "binary"
                        },
                        {
                            "topic" : "publish/topic/{{datetime}}/{{user}}/C",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        }    
                    ],      
                    "v5" : {
                        "user-properties": {
                            "prop1" : "value",
                            "prop2" : "value"    
                        } 
                    }
                },
            },
            {
                "enable" : false,
                "name" : "mqtt",
                "path-driver" : "/var/lib/vscp/drivers/level2/vscpl2drv-mqtt.so",
                "path-config" : "/var/lib/vscp/vscpd/mqtt.conf",
                "guid" : "FF:FF:FF:FF:FF:FF:FF:F5:08:00:00:00:00:00:00:00",

                "mqtt" : {
                    "bind" : "",   
                    "host" : "192.168.1.7",
                    "port" : 1883,
                    "mqtt-options" : {
                        "tcp-nodelay" : true,
                        "protocol-version": 311,
                        "receive-maximum": 20,
                        "send-maximum": 20,
                        "ssl-ctx-with-defaults": 0,
                        "tls-ocsp-required": 0,
                        "tls-use-os-certs" : 0
                    },
                    "user" : "vscp",
                    "password": "secret",
                    "clientid" : "vscp-level2-mqtt-driver",  
                    "publish-format" : "json",
                    "subscribe-format" : "auto",
                    "qos" : 1,
                    "bcleansession" : false,
                    "bretain" : false,      
                    "keepalive" : 60,
                    "reconnect" : {
                      "delay" : 2,
                      "delay-max" : 10,
                      "exponential-backoff" : false
                    },
                    "tls" : {
                        "cafile" : "",
                        "capath" : "",
                        "certfile" : "",
                        "keyfile" : "",
                        "pwkeyfile" : "",
                        "no-hostname-checking" : true,
                        "cert-reqs" : 0,
                        "version": "",
                        "ciphers": "",
                        "psk": "",
                        "psk-identity" : ""
                    },
                    "will": {
                        "topic": "Last Will",
                        "qos": 0,
                        "retain": false,
                        "payload": "This is the end"
                    },
                    "subscribe": [
                        {
                            "topic": "test1/topic/A",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/topic/B",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        }
                    ],
                    "bescape-pub-topics": true,
                    "user-escapes": {
                        "escape1": "valu1",
                        "escape2": "valu2"
                    },
                    "publish": [
                        {
                            "topic" : "publish/topic/json",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        },
                        {
                            "topic" : "publish/topic/xml",
                            "qos" : 0,
                            "retain" : false,
                            "format": "xml"
                        },
                        {
                            "topic" : "publish/topic/string",
                            "qos" : 0,
                            "retain" : false,
                            "format": "string"
                        },
                        {
                            "topic" : "publish/topic/binary",
                            "qos" : 0,
                            "retain" : false,
                            "format": "binary"
                        },
                        {
                            "topic" : "publish/topic/{{datetime}}/{{user}}/C",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        }    
                    ],      
                    "v5" : {
                        "user-properties": {
                            "prop1" : "value",
                            "prop2" : "value"    
                        } 
                    }
                },
            },
            {
                "enable" : false,
                "name" : "tcpiplink",
                "path-driver" : "/var/lib/vscp/drivers/level2/vscpl2drv-tcpiplink.so",
                "path-config" : "/var/lib/vscp/vscpd/tcpiplink.conf",
                "guid" : "FF:FF:FF:FF:FF:FF:FF:F5:09:00:00:00:00:00:00:00",

                "mqtt" : {
                    "bind" : "",   
                    "host" : "192.168.1.7",
                    "port" : 1883,
                    "mqtt-options" : {
                        "tcp-nodelay" : true,
                        "protocol-version": 311,
                        "receive-maximum": 20,
                        "send-maximum": 20,
                        "ssl-ctx-with-defaults": 0,
                        "tls-ocsp-required": 0,
                        "tls-use-os-certs" : 0
                    },
                    "user" : "vscp",
                    "password": "secret",
                    "clientid" : "vscp-level2-tcpiplink-driver",  
                    "publish-format" : "json",
                    "subscribe-format" : "auto",
                    "qos" : 1,
                    "bcleansession" : false,
                    "bretain" : false,      
                    "keepalive" : 60,
                    "reconnect" : {
                      "delay" : 2,
                      "delay-max" : 10,
                      "exponential-backoff" : false
                    },
                    "tls" : {
                        "cafile" : "",
                        "capath" : "",
                        "certfile" : "",
                        "keyfile" : "",
                        "pwkeyfile" : "",
                        "no-hostname-checking" : true,
                        "cert-reqs" : 0,
                        "version": "",
                        "ciphers": "",
                        "psk": "",
                        "psk-identity" : ""
                    },
                    "will": {
                        "topic": "Last Will",
                        "qos": 0,
                        "retain": false,
                        "payload": "This is the end"
                    },
                    "subscribe": [
                        {
                            "topic": "test1/topic/A",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/topic/B",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        }
                    ],
                    "bescape-pub-topics": true,
                    "user-escapes": {
                        "escape1": "valu1",
                        "escape2": "valu2"
                    },
                    "publish": [
                        {
                            "topic" : "publish/topic/json",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        },
                        {
                            "topic" : "publish/topic/xml",
                            "qos" : 0,
                            "retain" : false,
                            "format": "xml"
                        },
                        {
                            "topic" : "publish/topic/string",
                            "qos" : 0,
                            "retain" : false,
                            "format": "string"
                        },
                        {
                            "topic" : "publish/topic/binary",
                            "qos" : 0,
                            "retain" : false,
                            "format": "binary"
                        },
                        {
                            "topic" : "publish/topic/{{datetime}}/{{user}}/C",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        }    
                    ],      
                    "v5" : {
                        "user-properties": {
                            "prop1" : "value",
                            "prop2" : "value"    
                        } 
                    }
                },
            },
            {
                "enable" : false,
                "name" : "rawethernet",
                "path-driver" : "/var/lib/vscp/drivers/level2/vscpl2drv-raweth.so",
                "path-config" : "/var/lib/vscp/vscpd/raweth.conf",
                "guid" : "FF:FF:FF:FF:FF:FF:FF:F5:0A:00:00:00:00:00:00:00",

                "mqtt" : {
                    "bind" : "",   
                    "host" : "192.168.1.7",
                    "port" : 1883,
                    "mqtt-options" : {
                        "tcp-nodelay" : true,
                        "protocol-version": 311,
                        "receive-maximum": 20,
                        "send-maximum": 20,
                        "ssl-ctx-with-defaults": 0,
                        "tls-ocsp-required": 0,
                        "tls-use-os-certs" : 0
                    },
                    "user" : "vscp",
                    "password": "secret",
                    "clientid" : "vscp-level2-rawethernet-driver",  
                    "publish-format" : "json",
                    "subscribe-format" : "auto",
                    "qos" : 1,
                    "bcleansession" : false,
                    "bretain" : false,      
                    "keepalive" : 60,
                    "reconnect" : {
                      "delay" : 2,
                      "delay-max" : 10,
                      "exponential-backoff" : false
                    },
                    "tls" : {
                        "cafile" : "",
                        "capath" : "",
                        "certfile" : "",
                        "keyfile" : "",
                        "pwkeyfile" : "",
                        "no-hostname-checking" : true,
                        "cert-reqs" : 0,
                        "version": "",
                        "ciphers": "",
                        "psk": "",
                        "psk-identity" : ""
                    },
                    "will": {
                        "topic": "Last Will",
                        "qos": 0,
                        "retain": false,
                        "payload": "This is the end"
                    },
                    "subscribe": [
                        {
                            "topic": "test1/topic/A",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/topic/B",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        }
                    ],
                    "bescape-pub-topics": true,
                    "user-escapes": {
                        "escape1": "valu1",
                        "escape2": "valu2"
                    },
                    "publish": [
                        {
                            "topic" : "publish/topic/json",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        },
                        {
                            "topic" : "publish/topic/xml",
                            "qos" : 0,
                            "retain" : false,
                            "format": "xml"
                        },
                        {
                            "topic" : "publish/topic/string",
                            "qos" : 0,
                            "retain" : false,
                            "format": "string"
                        },
                        {
                            "topic" : "publish/topic/binary",
                            "qos" : 0,
                            "retain" : false,
                            "format": "binary"
                        },
                        {
                            "topic" : "publish/topic/{{datetime}}/{{user}}/C",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        }    
                    ],      
                    "v5" : {
                        "user-properties": {
                            "prop1" : "value",
                            "prop2" : "value"    
                        } 
                    }
                },
            },
            {
                "enable" : false,
                "name" : "sim",
                "path-driver" : "/var/lib/vscp/drivers/level2/vscpl2drv-sim.so",
                "path-config" : "/var/lib/vscp/vscpd/sim.conf",
                "guid" : "FF:FF:FF:FF:FF:FF:FF:F5:0B:00:00:00:00:00:00:00",

                "mqtt" : {
                    "bind" : "",   
                    "host" : "192.168.1.7",
                    "port" : 1883,
                    "mqtt-options" : {
                        "tcp-nodelay" : true,
                        "protocol-version": 311,
                        "receive-maximum": 20,
                        "send-maximum": 20,
                        "ssl-ctx-with-defaults": 0,
                        "tls-ocsp-required": 0,
                        "tls-use-os-certs" : 0
                    },
                    "user" : "vscp",
                    "password": "secret",
                    "clientid" : "vscp-level2-simulation-driver",  
                    "publish-format" : "json",
                    "subscribe-format" : "auto",
                    "qos" : 1,
                    "bcleansession" : false,
                    "bretain" : false,      
                    "keepalive" : 60,
                    "reconnect" : {
                      "delay" : 2,
                      "delay-max" : 10,
                      "exponential-backoff" : false
                    },
                    "tls" : {
                        "cafile" : "",
                        "capath" : "",
                        "certfile" : "",
                        "keyfile" : "",
                        "pwkeyfile" : "",
                        "no-hostname-checking" : true,
                        "cert-reqs" : 0,
                        "version": "",
                        "ciphers": "",
                        "psk": "",
                        "psk-identity" : ""
                    },
                    "will": {
                        "topic": "Last Will",
                        "qos": 0,
                        "retain": false,
                        "payload": "This is the end"
                    },
                    "subscribe": [
                        {
                            "topic": "test1/topic/A",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/topic/B",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        }
                    ],
                    "bescape-pub-topics": true,
                    "user-escapes": {
                        "escape1": "valu1",
                        "escape2": "valu2"
                    },
                    "publish": [
                        {
                            "topic" : "publish/topic/json",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        },
                        {
                            "topic" : "publish/topic/xml",
                            "qos" : 0,
                            "retain" : false,
                            "format": "xml"
                        },
                        {
                            "topic" : "publish/topic/string",
                            "qos" : 0,
                            "retain" : false,
                            "format": "string"
                        },
                        {
                            "topic" : "publish/topic/binary",
                            "qos" : 0,
                            "retain" : false,
                            "format": "binary"
                        },
                        {
                            "topic" : "publish/topic/{{datetime}}/{{user}}/C",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        }    
                    ],      
                    "v5" : {
                        "user-properties": {
                            "prop1" : "value",
                            "prop2" : "value"    
                        } 
                    }
                },
            },
            {
                "enable" : false,
                "name" : "1-wire",
                "path-driver" : "/var/lib/vscp/drivers/level2/vscpl2drv-wire1.so",
                "path-config" : "/var/lib/vscp/vscpd/wire1.conf",
                "guid" : "FF:FF:FF:FF:FF:FF:FF:F5:0C:00:00:00:00:00:00:00",

                "mqtt" : {
                    "bind" : "",   
                    "host" : "192.168.1.7",
                    "port" : 1883,
                    "mqtt-options" : {
                        "tcp-nodelay" : true,
                        "protocol-version": 311,
                        "receive-maximum": 20,
                        "send-maximum": 20,
                        "ssl-ctx-with-defaults": 0,
                        "tls-ocsp-required": 0,
                        "tls-use-os-certs" : 0
                    },
                    "user" : "vscp",
                    "password": "secret",
                    "clientid" : "vscp-level2-one-wire-driver",  
                    "publish-format" : "json",
                    "subscribe-format" : "auto",
                    "qos" : 1,
                    "bcleansession" : false,
                    "bretain" : false,      
                    "keepalive" : 60,
                    "reconnect" : {
                      "delay" : 2,
                      "delay-max" : 10,
                      "exponential-backoff" : false
                    },
                    "tls" : {
                        "cafile" : "",
                        "capath" : "",
                        "certfile" : "",
                        "keyfile" : "",
                        "pwkeyfile" : "",
                        "no-hostname-checking" : true,
                        "cert-reqs" : 0,
                        "version": "",
                        "ciphers": "",
                        "psk": "",
                        "psk-identity" : ""
                    },
                    "will": {
                        "topic": "Last Will",
                        "qos": 0,
                        "retain": false,
                        "payload": "This is the end"
                    },
                    "subscribe": [
                        {
                            "topic": "test1/topic/A",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/topic/B",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        },
                        {
                            "topic": "test2/#",
                            "qos": 0,
                            "v5-options": 0,
                            "format": "auto"
                        }
                    ],
                    "bescape-pub-topics": true,
                    "user-escapes": {
                        "escape1": "valu1",
                        "escape2": "valu2"
                    },
                    "publish": [
                        {
                            "topic" : "publish/topic/json",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        },
                        {
                            "topic" : "publish/topic/xml",
                            "qos" : 0,
                            "retain" : false,
                            "format": "xml"
                        },
                        {
                            "topic" : "publish/topic/string",
                            "qos" : 0,
                            "retain" : false,
                            "format": "string"
                        },
                        {
                            "topic" : "publish/topic/binary",
                            "qos" : 0,
                            "retain" : false,
                            "format": "binary"
                        },
                        {
                            "topic" : "publish/topic/{{datetime}}/{{user}}/C",
                            "qos" : 0,
                            "retain" : false,
                            "format": "json"
                        }    
                    ],      
                    "v5" : {
                        "user-properties": {
                            "prop1" : "value",
                            "prop2" : "value"    
                        } 
                    }
                },
            }
        ]
    }
}

Categories
General

GitHub Summerfest | GitHub Resources

Following in the footsteps of our Winterfest traditions, we’ve prepared an hour of virtual games, lightning talks, and expert Q&As for you to kick summer off right. Zoom fatigue? Not with us! Come and join us for a virtual get-together with DevOps and security peers from all over Europe.

Source: GitHub Summerfest | GitHub Resources

Categories
General

Summerfest

Now ready for GitHub Summerfest next week.

Thank you GitHub!

Categories
CAN4VSCP

Nice and stable

I have had CAN4VSCP boards running now for many years here on the VSCP hill. Setups like the above for my weather station, take care of things like hot water generation, fridge control, pellets stove and heater, alarms, lights and much, much, much more. The setup is actually incredible stable and have survived many thunderstorms, winter blizzards (several setups is mounted outside like the one above), rain, and power hick ups. It just works.

All CAN4VSCP designs are real open hardware with all documents and firmware open and freee to use. It is OK to build your own, sell them, change them or do whatever you can come up with.

From november this year I will start to sell them again – after this five year stop – aimed to those of you that like to obtain your hardware that way. To buy some hardware is also a good way to support the VSCP project. Some additional cards will appear to at that time. Strangely the designs does not feel old event if many of them are almost ten years at this point. Oldies in electronic terms.

I myself is becoming old to. But still love this more then can express. The work with VSCP will continue.

Categories
General

eSPI Protocol | Prodigy Technovations

eSPI ProtocoleSPI Protocol INTRODUCTIONeSPI stands for enhanced serial peripheral interface. It was developed by Intel. eSPI is an all-in-one bus that was designed to replace the LPC bus as well as the SPI bus, SMbus and sideband signals. For designers of computing applications, migrating from the LPC bus to the eSPI bus offered benefits such

Source: eSPI Protocol | Prodigy Technovations

Categories
General

Ever wondered what you could do with CAN? Then click to discover what CAN could do for you!

Source: Ever wondered what you could do with CAN? Then click to discover what CAN could do for you!

Categories
General

I3C, the High-Performance Interface for Next-Generation Sensors

The electronic sensors market is constantly expanding, with double-digit year-over-year growth rates. The main factors driving this growth are the high

Source: I3C, the High-Performance Interface for Next-Generation Sensors

Categories
VSCP

State of #VSCP

I planned to release version 15.0.0 of VSCP today. But as usual plans are one thing and reality is another. I still need some more time. But very soon now...

This has been a very hard release to get out. Mainly because the big rewrite of code. The rewrite has taken nearly two years to accomplish so there are many, many, MANY changes.

The biggest change is that MQTT is used for higher level functionality now. This means that the drivers (both level I and level II) talk to a MQTT broker in the following fashione

It is actually possible to have as many subscribe/publish topics as one need. Like this

So from a higher level view you now subscribe or publish VSCP events on a MQTT broker of choice. Events that can be on four different formats; binary, JSON, XML or ASCII.

The default format is JSON. Ans a VSCP JSON event looks like this

{
    "vscpHead": 2,
    "vscpObId": 123,
    "vscpDateTime": "2017-01-13T10:16:02",
    "vscpTimeStamp":50817,
    "vscpClass": 10,
    "vscpType": 8,
    "vscpGuid": "00:00:00:00:00:00:00:00:00:00:00:00:00:01:00:02",
    "vscpData": [1,2,3,4,5,6,7],
    "note": "This is some text"
}

For measurement events some optional fields can be added

measurement {
    "value" : 1.23,
    "unit" : 0,
    "sensorindex" : 1,
    "zone" : 11,
    "subzone" : 22
}

If you have worked with the VSCP websocket protocol ws2 you recognize this format.

The tcp/ip interface, the web socket interfaces, the decision matrix, the webserver, remote variables are gone from the VSCP daemon with this release. From tghis point the VSCP daemon will do one thing. Have a common interface to drivers and handle the transfer of events between the drivers and MQTT brokers. One can look at it as a pluggable driver interface for MQTT brokers.

Well, a lot of functionality has been written during the year using the VSCP web interface, websocket, tcp/ip etc. But that work does not need to be thrown away. This functionality is now available as drivers to the VSCP daemon. Initially the tcp/ip server and client, the web interface, websockets (ws1/ws2) and the rest interface is in place. Later the decision matrix functionality and remote variables will be added again as well.

Another news is that the VSCP daemon natively now builds on Windows again. Many have asked for that. Most driver will be available there as well.

There are more of course. But more on that latter. If I sit here and just write about the release it will never come out.

Last I want to thank my sponsors. It has been a tremendous help during this long development time to get this sponsorship. It’s been that little drop of water that made the boat go float each month. Thank You!

ps What about VSCP works someone may ask? The rewrite works continue isd trhe answer. A lot to rewrite there as well. ds.

Categories
General

Announcing Matter (previously ‘CHIP’) on ESP32 | by Hrishikesh Dhayagude | The ESP Journal | May, 2021 | Medium

Introduction

Source: Announcing Matter (previously ‘CHIP’) on ESP32 | by Hrishikesh Dhayagude | The ESP Journal | May, 2021 | Medium

Categories
General

GitHub Summerfest | GitHub Resources

Following in the footsteps of our Winterfest traditions, we’ve prepared an hour of virtual games, lightning talks, and expert Q&As for you to kick summer off right. Zoom fatigue? Not with us! Come and join us for a virtual get-together with DevOps and security peers from all over Europe.

Source: GitHub Summerfest | GitHub Resources