You have to setup the config.json as per the pilight docs…
Here’s an example of mine…
{
"devices": {
"pibedroompir": {
"protocol": [ "kaku_switch_old" ],
"id": [{
"id": 31,
"unit": 1
}],
"state": "on"
},
"pilivingroompir": {
"protocol": [ "kaku_switch_old" ],
"id": [{
"id": 30,
"unit": 15
}],
"state": "on"
},
"pihallpir": {
"protocol": [ "kaku_switch_old" ],
"id": [{
"id": 23,
"unit": 5
}],
"state": "on"
},
"pikitchenpir": {
"protocol": [ "kaku_switch_old" ],
"id": [{
"id": 31,
"unit": 0
}],
"state": "on"
}
},
"rules": {},
"gui": {
"pibedroompir": {
"name": "bedroompir",
"group": [ "bedroom" ],
"media": [ "web" ],
"readonly": 0
},
"pilivingroompir": {
"name": "livingroompir",
"group": [ "livingroom" ],
"media": [ "web" ],
"readonly": 0
},
"pihallpir": {
"name": "hallpir",
"group": [ "hall" ],
"media": [ "web" ],
"readonly": 0
},
"pikitchenpir": {
"name": "kitchenpir",
"group": [ "kitchen" ],
"media": [ "web" ],
"readonly": 0
}
}'
"settings": {
"log-level": 6,
"pid-file": "/var/run/pilight.pid",
"log-file": "/var/log/pilight.log",
"port": 5000,
"webserver-enable": 1,
"webserver-http-port": 5001,
"webserver-cache": 1,
"webserver-root": "/usr/local/share/pilight/webgui",
"standalone": 1,
"gpio-platform": "raspberrypi3"
},
"hardware": {
"433gpio": {
"sender": 0,
"receiver": 1
}
},
"registry": {
"pilight": {
"firmware": {
"version": 20976,
"lpf": 556850,
"hpf": 219750
},
"version": {
"current": "8.0.3"
}
},
"webgui": {
"tabs": 3
},
"webserver": {
"ssl": {
"certificate": {
"secure": 0,
"location": "/etc/pilight/pilight.pem"
}
}
}
}
}
Couple of things with this file :-
- You can’t edit it while the daemon is running as it will overwrite it when you save it
- it’s located in /etc/pilight
The hardware section has to be setup, however this is correct for the the pins as per the docs for plugging the hardware pilight suggests, so if you have done the same it should be OK, but do check it.
The webgui needs setting up to if you are using it.