• 10 dec 2017: forum version update. In case of issues use this topic.
  • 30 nov 2017: pilight moved servers. In case of issues use this topic.
Hello There, Guest! Login Register


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
problem publish to pilight MQTT server
#1
So I am setting my first steps in MQTT using pilight version v8.1.5-nightly-45c64b39 on Rpi and testing it with MQTT.fx on Windows. Subscribing in MQTT.fx to pilight topics is working fine. But when I try to change the state of a switch by publishing a command the pilight.log shows:
Code:
ERROR: elro_400_switch: insufficient number of arguments
config.json (shortened version):
Code:
{
       "devices":
               "keuken": {
                       "protocol": [ "elro_400_switch" ],
                       "id": [{
                               "systemcode": 9,
                               "unitcode": 29
                       }],

               }
       },
       "settings": {
               "log-level": 6,
               "pid-file": "/var/run/pilight.pid",
               "log-file": "/var/log/pilight.log",
               "standalone": 1,
               "webserver-enable": 1,
               "webserver-root": "/usr/local/share/pilight/webgui",
               "webserver-http-port": 5001,
               "webserver-https-port": 5002,
               "webserver-cache": 1,
               "whitelist": "",
               "gpio-platform": "raspberrypi1b2",
               "mqtt-port": 1883,
               "mqtt-enable": 1
       },
       "hardware": {
               "433gpio": {
                       "sender": 0,
                       "receiver": 1
               }
       },
       "registry": {
               "webserver": {
                       "ssl": {
                               "certificate": {
                                       "location": "/etc/pilight/pilight.pem"
                               }
                       }
               },
               "pilight": {
                       "version": {
                               "current": "8.1.5"
                       }
               },
               "hardware": {
                       "RF433": {
                               "mingaplen": 4420,
                               "maxgaplen": 72900,
                               "minrawlen": 26,
                               "maxrawlen": 400
                       }
               }
       }
}
So I use MQTT.fx to connect, subscribe and publish.
Subscribe to :
Code:
pilight/device/keuken/+
 gives a timestamp and a state after I switched it; perfect

Publish:
Code:
pilight/device/keuken/state on
gives no action and the pilight.log shows:

Code:
[Aug 26 13:45:25:114372] ERROR: elro_400_switch: insufficient number of arguments
What am I doing wrong here?
 
Reply
#2
Probably nothing except that MQTT is under heavy debugging. I will look into it later.
 
Reply
#3
(08-26-2020, 05:09 PM)curlymo Wrote: Probably nothing except that MQTT is under heavy debugging. I will look into it later.

Ah ok. Well if I can be of any help testing, let me know. Is there a way of monitoring what the pilight MQTT server actually receives?
 
Reply
#4
Can you check if the latest staging improves anything?
 
Reply
#5
(08-30-2020, 08:01 PM)curlymo Wrote: Can you check if the latest staging improves anything?

I did reinstall  Raspbian from scratch after a problem. I installed the new nightly and after testing with subribe and publish this is the log:
Code:
[Aug 31 19:48:02:67446] INFO: version v8.1.5-nightly-1af4c284
[Aug 31 19:48:02:107002] INFO: daemon listening to port: 37557
[Aug 31 19:48:02:157820] INFO: secured webserver started on port: 5002 (fd 15)
[Aug 31 19:48:02:158142] INFO: regular webserver started on port: 5001 (fd 16)
[Aug 31 19:48:02:169151] INFO: new client, ip: 127.0.0.1, port: 35926
[Aug 31 19:48:02:276215] NOTICE: no pilight ssdp connections found
[Aug 31 19:48:02:279827] INFO: new client, ip: 127.0.0.1, port: 35930
[Aug 31 19:49:45:292390] ERROR: elro_400_switch: insufficient number of arguments
subscribing still works; publishing still does not.
Sorry so no improvement
 
Reply
  


Possibly Related Threads...
Thread Author Replies Views Last Post
Lightbulb working MQTT in version v8.1.5-nightly-1af4c284 fleisch 0 7 11 hours ago
Last Post: fleisch
  bridging pilight and mosquitto hansrijn2 3 208 10-09-2020, 08:12 PM
Last Post: hansrijn2
  pilight for Raspbian Buster (raspberry pi 4) ? starob 32 9,655 08-10-2020, 09:12 AM
Last Post: simanuel
  pilight switch node in node-red framp 0 530 06-24-2020, 10:01 PM
Last Post: framp
  MQTT external Broker (not local) configuration nicky 3 390 06-02-2020, 05:00 PM
Last Post: curlymo
  pilight-control TML 13 1,613 05-27-2020, 07:51 AM
Last Post: curlymo
  API Requests by HTTP from other devices fore use in pilight scootermacro 2 773 05-10-2020, 08:19 AM
Last Post: scootermacro
  MQTT cannot be disabled on nightly image ayeyebrazov 5 568 05-01-2020, 03:11 PM
Last Post: ayeyebrazov
  MQTT subscribe to a weather station? peteratoce 5 583 04-08-2020, 07:17 AM
Last Post: curlymo
  pilight-send seems successful but doesn't actually send RF signal ayeyebrazov 37 4,467 03-31-2020, 01:02 PM
Last Post: curlymo

Forum Jump:


Browsing: 1 Guest(s)