Publish to MQTT Issue

I am trying to publish two items to MQTT and I think I am doing something wrong. This is an emonPi with the emonSD-03May16 image. And I am using Node-RED to publish the two items.

When I look at the Input View via 192.168.40.230/emoncms/input/view I see one value for a split second and then it is replaced by the 2nd value.

The first value is published to emon/RF1/power1:

 

The second value is published to emon/RF1/energy_kWh and I also tried emon/RF2/energy_kWh:

 

Both value are published as a string and I also tried publishing them as a number.

I can MQTT subscribe to both items and both items appear as expected.

So what am I doing wrong in the Input View page? The only thing I can think off is I need to add something to the emonhub config file but I cannot determine what should be added.

Hello,

I was trying the same with an esp8266 and MQTT…
Have the same issues.
If I try to log the values I get Undefined. unable to create…

So I am interested in a solution also

Thanks

It sounds like you are doing everything correct, what exactly do you see on the inputs page? What input name(s) does the data appear under? No change to emonhub.conf should be required. EmonHub is not involved when posting to emon topic. The mqtt input script in emoncms is what subscribes to this topic and posts the data to emoncms.

Changing the debug level to INFO in /var/www/emoncms/settings.php then restarting the mqtt_input process will give you more info in the /var/log/emoncms.log .

$ sudo service mqtt_input restart

on the Inputs Page I would normally see just one item:
Node = RF1 / Key = power1 / Value = (unsure) and then it would quickly flash to
Node = RF1 / Key = energy_kWh / Value = 660.0. This is the item I would normally see.

I also had the same issue as Herbert: ERROR: Could not save processlist. undefined when trying create a Log to feed for energy_kWh. This was my first hint there was an issue…

I think I got things working and I hate to say this - I don’t know exactly what and why. These are the steps:

1) I did an emonPi update. And these are the areas updated

Here is the emonpiupdate log: 2016-07-06 at 19-28-50 - emonpiupdate.pdf (37.3 KB)

This did not change the MQTT or Input View issues above.

I noticed there were certain git pulls that did not update or state “Already up-to-date”. I highlighted these items in yellow. In the past this was due to a git permission error and was fixed with (BETA): emonSD22Dec15 - emonPi / emonBase (Raspberry Pi + RFM69Pi) Emoncms v9 pre-built ready | Archived Forum.

2) I ran this fix on the oem_openHab, usefulscripts, the huawei-hilink-status git areas. (I don’t use the oem_openHab or huawei-hilink-status items but repaired then anyway)

3) And then I ran another emonPi Update.

Here is the emonpiupdate log: 2016-07-06 at 20-25-24 - emonpiupdate.pdf (35.5 KB)

4) and then I did a sudo reboot.

And now the MQTT, the Input View and the Log to feed all work as expected. And I don’t know if one of the emonPi updates and/or the reboot helped.

Can you export your nodeRed flow and post on the thread so I can test?

  • sent from my mobile device

This is fairly ugly as I am experimenting and learning:

RF.json.txt (9.9 KB)

-or-

[{"id":"19211dbb.e6dee2","type":"mqtt-broker","z":"","broker":"localhost","port":"1883","clientid":"","usetls":false,"verifyservercert":true,"compatmode":true,"keepalive":"15","cleansession":true,"willTopic":"","willQos":"0","willRetain":"false","willPayload":"","birthTopic":"","birthQos":"0","birthRetain":"false","birthPayload":""},{"id":"6a3ddc99.95c224","type":"subflow","name":"timestamp v2","info":"Input:\n- \"msg.payload\" is input string to be stored in\nlog file.\n- log file stored per msg.filename\n\n\nOutput:\n- timestamp and inputstring stored in logfile\n- ","in":[{"x":60,"y":160,"wires":[{"id":"e1df7f5f.1e208"}]}],"out":[{"x":600,"y":200,"wires":[{"id":"d8b6a947.274958","port":0}]}]},{"id":"d8b6a947.274958","type":"function","z":"6a3ddc99.95c224","name":"add timestamp v2","func":"var now = new Date();\nif (msg.filename === undefined) {\n        msg.filename = \"/home/pi/data/undefined.log\";\n    }\nmsg.payload = now.toString() + \"\\t\" + now.valueOf() + \"\\t\" + msg.payload;\nreturn msg;","outputs":"1","noerr":0,"x":430,"y":160,"wires":[["94bd61ac.6b42a"]]},{"id":"94bd61ac.6b42a","type":"file","z":"6a3ddc99.95c224","name":"","filename":"","appendNewline":true,"createDir":true,"overwriteFile":"false","x":630,"y":140,"wires":[]},{"id":"e1df7f5f.1e208","type":"switch","z":"6a3ddc99.95c224","name":"Drop \"Null\"","property":"payload","propertyType":"msg","rules":[{"t":"nnull"},{"t":"null"}],"checkall":"false","outputs":2,"x":210,"y":160,"wires":[["d8b6a947.274958"],[]]},{"id":"be2acc38.41d53","type":"subflow:6a3ddc99.95c224","z":"fa6d6521.059298","name":"","x":770,"y":700,"wires":[[]]},{"id":"75705061.8a8fb","type":"inject","z":"fa6d6521.059298","name":"Power Now","topic":"","payload":"","payloadType":"str","repeat":"","crontab":"","once":false,"x":130,"y":120,"wires":[["e8d8266.f1727d8"]]},{"id":"6bbdd1f8.94423","type":"xml","z":"fa6d6521.059298","name":"","attr":"","chr":"","x":290,"y":340,"wires":[["123f319f.edc0ce"]]},{"id":"11399809.eec668","type":"rbe","z":"fa6d6521.059298","name":"Ignore repeat values","func":"rbe","gap":"","start":"","x":540,"y":220,"wires":[["6bbdd1f8.94423"]]},{"id":"e883d58e.177c28","type":"http request","z":"fa6d6521.059298","name":"","method":"POST","ret":"txt","url":"http://192.168.40.111/cgi-bin/post_manager","x":490,"y":120,"wires":[["13ecabb2.ec1354","4ac38957.b53c78"]]},{"id":"e8d8266.f1727d8","type":"function","z":"fa6d6521.059298","name":"Format request","func":"//Create Eagle command XML fragment\nvar command = \"<Command>\\n\";\ncommand += \"  <Name>get_instantaneous_demand</Name>\\n\";\ncommand += \"  <MacId>d8d5b90000006770</MacId>\\n\";\ncommand += \"</Command>\\n\";\n\nmsg.payload = command;\n\nreturn msg;","outputs":1,"noerr":0,"x":320,"y":120,"wires":[["e883d58e.177c28"]]},{"id":"123f319f.edc0ce","type":"function","z":"fa6d6521.059298","name":"Calc Demand Value","func":"msg.filename = \"/home/pi/data/RainForest.log\"\n//ignore bad data\nif (!msg.payload.InstantaneousDemand) \n{\n    return;\n}\n\n//parse response\nstrDemand=msg.payload.InstantaneousDemand.Demand[0];\nintDemand=parseInt(strDemand,16);\n\nstrMultiplier=msg.payload.InstantaneousDemand.Multiplier[0];\nintMultiplier=parseInt(strMultiplier,16);\n\nstrDivisor=msg.payload.InstantaneousDemand.Divisor[0];\nintDivisor=parseInt(strDivisor,16);\n\nif (intDemand>2147483647) {     // largest number allowed 0x7FFFFFFF\n    intDemand = 0;\n}\n\nif (intMultiplier===0) {\n    intMultiplier = 1;\n} \n\nif (intDivisor===0) {\n    intDivisor = 1;\n}\n\nmsg.payload = (intDemand * intMultiplier) / intDivisor;\n\nmsg.payload = msg.payload * 1000;   //  output in Watts not kW\n\nreturn msg;","outputs":"1","noerr":0,"x":450,"y":340,"wires":[["e72c0f58.18d3f"]]},{"id":"4461bcc8.bb9e44","type":"debug","z":"fa6d6521.059298","name":"calc debug","active":true,"console":"false","complete":"payload","x":770,"y":300,"wires":[]},{"id":"13ecabb2.ec1354","type":"function","z":"fa6d6521.059298","name":"Ignore bad data","func":"//ignore bad data\nif (!msg.payload || msg.payload === null || msg.payload === '') \n{\n    return;\n}\n\nreturn msg;","outputs":1,"noerr":0,"x":340,"y":220,"wires":[["11399809.eec668"]]},{"id":"7b4d336a.84b2cc","type":"comment","z":"fa6d6521.059298","name":"Read Me: Notes (please retain these notes if distributing the flows)","info":"Author: Mike Thompson, GitHub: mike-linus\nDate: 24/2/2016\n\nThese examples show how to extract data and control the Rainforest Eagle using\nthe recommended HTTP Rest API both locally and via the Internet Gateway.\n\nFor those of you trying to get the most out of the Rainforest Eagle, these\nexample Node-Red flows should get you going. Having the flows in Node-Red\nopens up a huge range of automation possibilities. Enjoy :)\n\nTo use the flows:\n1. Modify the 'Format Request' function nodes to your specific credentials. For local requests, you need to add your own MAC address. For the Relay Gateway, the message headers need to be altered to your Gateway account.\n2. For all flows except the Gateway flow, modify the 'http request' nodes, tick  'use basic authentication?', add your 'Cloud ID' as the username, your 'Installation Code' as the password and your Eagle's IP address.\n3. For the Gateway flow, basic authentication is not used as the credentials are passed in the message header.\n4. To automate the flows, simply modify the 'inject node' to repeat at the required interval.\n5. To publish the data on a MQTT topic, just replace the debug node with an MQTT node.\n\nCreating your own commands simply requires creating the appropriate command string in the 'Format request' node. Refer to the Eagle Rest API documentation for more information.","x":276,"y":37,"wires":[]},{"id":"4ac38957.b53c78","type":"debug","z":"fa6d6521.059298","name":"http debug","active":false,"console":"false","complete":"payload","x":670,"y":80,"wires":[]},{"id":"762a2166.89d5e","type":"function","z":"fa6d6521.059298","name":"Format request 2","func":"//Create Eagle command XML fragment\nvar command = \"<Command>\\n\";\ncommand += \"  <Name>get_current_summation</Name>\\n\";\ncommand += \"  <MacId>d8d5b90000006770</MacId>\\n\";\ncommand += \"</Command>\\n\";\n\nmsg.payload = command;\n\nreturn msg;","outputs":1,"noerr":0,"x":310,"y":480,"wires":[["8669bd1.f79964"]]},{"id":"489d932.fb7626c","type":"inject","z":"fa6d6521.059298","name":"Total kWh","topic":"","payload":"","payloadType":"str","repeat":"","crontab":"","once":false,"x":120,"y":480,"wires":[["762a2166.89d5e"]]},{"id":"8669bd1.f79964","type":"http request","z":"fa6d6521.059298","name":"","method":"POST","ret":"txt","url":"http://192.168.40.111/cgi-bin/post_manager","x":490,"y":480,"wires":[["d36c3b7f.2c93c8"]]},{"id":"d36c3b7f.2c93c8","type":"xml","z":"fa6d6521.059298","name":"","attr":"","chr":"","x":210,"y":600,"wires":[["46874204.b978bc"]]},{"id":"46874204.b978bc","type":"function","z":"fa6d6521.059298","name":"Calc Current Summation","func":"msg.filename = \"/home/pi/data/RainForest.log\"\n//ignore bad data\nif (!msg.payload.CurrentSummation) \n{\n    return;\n}\n\n//parse response\nstrDelivered=msg.payload.CurrentSummation.SummationDelivered[0];\nintDelivered=parseInt(strDelivered,16);\n\nstrMultiplier=msg.payload.CurrentSummation.Multiplier[0];\nintMultiplier=parseInt(strMultiplier,16);\n\nstrDivisor=msg.payload.CurrentSummation.Divisor[0];\nintDivisor=parseInt(strDivisor,16);\n\nif (intDelivered>2147483647) {     // largest number allowed 0x7FFFFFFF\n    intDelivered = 0;\n}\n\nif (intMultiplier===0) {\n    intMultiplier = 1;\n} \n\nif (intDivisor===0) {\n    intDivisor = 1;\n}\n\nmsg.payload = (intDelivered * intMultiplier) / intDivisor;\n\nreturn msg;","outputs":"1","noerr":0,"x":390,"y":600,"wires":[["856a3171.7a95d"]]},{"id":"9392f723.6c6d08","type":"debug","z":"fa6d6521.059298","name":"calc debug 2","active":true,"console":"false","complete":"payload","x":770,"y":560,"wires":[]},{"id":"c5cd6847.3a3298","type":"mqtt out","z":"fa6d6521.059298","name":"","topic":"emon/RF2/energy_kWh","qos":"","retain":"","broker":"19211dbb.e6dee2","x":810,"y":600,"wires":[]},{"id":"5f184625.a0e7b8","type":"mqtt out","z":"fa6d6521.059298","name":"","topic":"emon/RF2/power1","qos":"","retain":"","broker":"19211dbb.e6dee2","x":790,"y":340,"wires":[]},{"id":"adc764b8.523898","type":"inject","z":"fa6d6521.059298","name":"","topic":"","payload":"","payloadType":"str","repeat":"60","crontab":"","once":false,"x":110,"y":180,"wires":[["e8d8266.f1727d8","7a22181f.85dde8"]]},{"id":"7a22181f.85dde8","type":"delay","z":"fa6d6521.059298","name":"","pauseType":"delay","timeout":"5","timeoutUnits":"seconds","rate":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":120,"y":400,"wires":[["762a2166.89d5e"]]},{"id":"9a26382f.65d9c8","type":"inject","z":"fa6d6521.059298","name":"Reboot Eagle","topic":"","payload":"","payloadType":"str","repeat":"","crontab":"","once":false,"x":130,"y":840,"wires":[["53e776ff.ac1888"]]},{"id":"53e776ff.ac1888","type":"function","z":"fa6d6521.059298","name":"Format request","func":"//Create Eagle command XML fragment\nvar command = \"<Command>\\n\";\ncommand += \"  <Name>reboot</Name>\\n\";\ncommand += \"  <MacId>d8d5b90000006770</MacId>\\n\";\ncommand += \"  <Target>Eagle</Target>\\n\";\ncommand += \"</Command>\\n\";\n\nmsg.payload = command;\n\nreturn msg;","outputs":1,"noerr":0,"x":300,"y":840,"wires":[["e69ea7bf.196158"]]},{"id":"e69ea7bf.196158","type":"http request","z":"fa6d6521.059298","name":"","method":"POST","ret":"txt","url":"http://192.168.40.111/cgi-bin/post_manager","x":470,"y":840,"wires":[["fdfde235.02022"]]},{"id":"fdfde235.02022","type":"debug","z":"fa6d6521.059298","name":"","active":true,"console":"false","complete":"false","x":630,"y":840,"wires":[]},{"id":"856a3171.7a95d","type":"rbe","z":"fa6d6521.059298","name":"","func":"rbe","gap":"","start":"","inout":"out","x":570,"y":600,"wires":[["c5cd6847.3a3298","9392f723.6c6d08","be2acc38.41d53"]]},{"id":"e72c0f58.18d3f","type":"rbe","z":"fa6d6521.059298","name":"","func":"rbe","gap":"","start":"","inout":"out","x":610,"y":340,"wires":[["5f184625.a0e7b8","4461bcc8.bb9e44","be2acc38.41d53"]]}]

 
This is what I started with and then added the MQTT nodes.

Source:
Node-RED flows - Rainforest Eagle Smart Meter API

All looks correct to me. Sorry I’m still away from home and unable to test on a live system. However, I can’t see a problem with your flow. You could try posting a test from another MQTT client such as MQTTLens chrome extension or the emonPi itself e.g.

$ mosquitto_pub -u 'emonpi' -P 'emonpimqtt2016' -t 'emon/RF2/power1' -m '9999'

This will post 999 to emon/RF2/power1

Great, good to hear you got it working. I think the reboot is the thing that
has made the difference. All the other updates are not used for anything to
do with MQTT. Please continue to test and let me know if the problem
returns.

Hi, I was following this as I had more or less the same issue.
So…yes the reboot made the error : ERROR: Could not save processlist. undefined disappear.
Solved…
However now my emonpi is not updating locally anymore :frowning:
So on emoncms.org I can see my feeds but locally I can not get them to work anymore.

Suggestions?

Thanks

Oh dear. Reboot should not effect local logging. There must be some other issue here. Could you post your emonhub.log and emoncms.log?

Hi Glyn,

Sorry for the late answer. I was on business trip and had no access to my system.

As you will see in the conf and log I am using a JeeLink (v3c) as it performs a lot better on receiving all the links in the house. However the problem is with the standard RaspberryPi RF also. Further I also moved storage to an USB stick as per your instructions.


#######################################################################
#######################      emonhub.conf     #########################
#######################################################################
### emonHub configuration file, for info see documentation:
### http://github.com/openenergymonitor/emonhub/blob/emon-pi/configuration.md
#######################################################################
#######################    emonHub  settings    #######################
#######################################################################

[hub]
### loglevel must be one of DEBUG, INFO, WARNING, ERROR, and CRITICAL
loglevel = DEBUG
### Uncomment this to also send to syslog
# use_syslog = yes
#######################################################################
#######################       Interfacers       #######################
#######################################################################

[interfacers]
### This interfacer manages the RFM12Pi/RFM69Pi/emonPi module
[[RFM2Pi]]
    Type = EmonHubJeeInterfacer
    [[[init_settings]]]
#        com_port = /dev/ttyAMA0
       com_port = /dev/ttyUSB0      
#        com_baud = 38400                        # 9600 for old RFM12Pi
        com_baud = 57600
    [[[runtimesettings]]]
        pubchannels = ToEmonCMS,
        subchannels = ToRFM12,

        group = 210
        frequency = 868
        baseid = 5                              # emonPi / emonBase nodeID
        quiet = true                            # Report incomplete RF packets (no implemented on emonPi)
        calibration = 230V                      # (UK/EU: 230V, US: 110V)
        # interval =  0                         # Interval to transmit time to emonGLCD (seconds)

[[MQTT]]

    Type = EmonHubMqttInterfacer
    [[[init_settings]]]
        mqtt_host = 127.0.0.1
        mqtt_port = 1883
        mqtt_user = emonpi
        mqtt_passwd = emonpimqtt2016

    [[[runtimesettings]]]
        pubchannels = ToRFM12,
        subchannels = ToEmonCMS,

        # emonhub/rx/10/values format
        # Use with emoncms Nodes module
        node_format_enable = 1
        node_format_basetopic = emonhub/

        # emon/emontx/power1 format - use with Emoncms MQTT input
        # http://github.com/emoncms/emoncms/blob/master/docs/RaspberryPi/MQTT.md
        nodevar_format_enable = 1
        nodevar_format_basetopic = emon/

[[emoncmsorg]]
    Type = EmonHubEmoncmsHTTPInterfacer
    [[[init_settings]]]
    [[[runtimesettings]]]
        pubchannels = ToRFM12,
        subchannels = ToEmonCMS,
        url = https://emoncms.org
        apikey = #emoncms          senddata = 1                    # Enable sending data to Emoncms.org
        sendstatus = 1                  # Enable sending WAN IP to Emoncms.org MyIP > https://emoncms.org/myip/list
        sendinterval= 30                # Bulk send interval to Emoncms.org in seconds

#######################################################################
#######################          Nodes          #######################
#######################################################################

[nodes]

## See config user guide: http://github.com/openenergymonitor/emonhub/blob/master/configuration.md

[[5]]
    nodename = emonpi
    [[[rx]]]
        names = power1,power2,power1pluspower2,vrms,t1,t2,t3,t4,t5,t6,pulsecount
        datacodes = h, h, h, h, h, h, h, h, h, h, L
        scales = 1,1,1,0.01,0.1,0.1,0.1,0.1,0.1,0.1,1
        units = W,W,W,V,C,C,C,C,C,C,p

[[6]]
    nodename = emontxshield
    [[[rx]]]
       names = power1, power2, power3, power4, vrms
       datacode = h
       scales = 1,1,1,1,0.01
       units =W,W,W,W,V

[[7]]
   nodename = emontx4
   [[[rx]]]
      names = power1, power2, power3, power4, vrms, temp1, temp2, temp3, temp4, temp5, temp6, pulse
      datacodes = h,h,h,h,h,h,h,h,h,h,h,L
      scales = 1,1,1,1,0.01,0.1,0.1, 0.1,0.1,0.1,0.1,1
      units =W,W,W,W,V,C,C,C,C,C,C,p

[[8]]
    nodename = emontx3
    [[[rx]]]
       names = power1, power2, power3, power4, vrms, temp1, temp2, temp3, temp4, temp5, temp6, pulse
       datacodes = h,h,h,h,h,h,h,h,h,h,h,L
       scales = 1,1,1,1,0.01,0.1,0.1, 0.1,0.1,0.1,0.1,1
       units =W,W,W,W,V,C,C,C,C,C,C,p

[[9]]
   nodename = emontx2
   [[[rx]]]
      names = power1, power2, power3, power4, vrms, temp1, temp2, temp3, temp4, temp5, temp6, pulse
      datacode = h
      scales = 1,1,1,1,0.01,0.1,0.1, 0.1,0.1,0.1,0.1,1
      units =W,W,W,W,V,C,C,C,C,C,C,p

[[10]]
    nodename = kelder
    [[[rx]]]
       names = power1, power2, power3, power4, vrms, temp1, temp2, temp3, temp4, temp5, temp6, pulse
       datacode = h
       scales = 1,1,1,1,0.01,0.1,0.1, 0.1,0.1,0.1,0.1,1
       units =W,W,W,W,V,C,C,C,C,C,C,p

[[19]]
   nodename = emonth1
   [[[rx]]]
      names = temperature, external temperature, humidity, battery
      datacode = h
      scales = 0.1,0.1,0.1,0.1
      units = C,C,%,V

[[20]]
   nodename = emonth2
   [[[rx]]]
      names = temperature, external temperature, humidity, battery
      datacode = h
      scales = 0.1,0.1,0.1,0.1
      units = C,C,%,V

[[21]]
   nodename = emonth3
   [[[rx]]]
      names = temperature, external temperature, humidity, battery
      datacode = h
      scales = 0.1,0.1,0.1,0.1
      units = C,C,%,V

[[22]]
   nodename = emonth4
   [[[rx]]]
      names = temperature, external temperature, humidity, battery
      datacode = h
      scales = 0.1,0.1,0.1,0.1
      units = C,C,%,V
[[23]]
    nodename = emonth5
    [[[rx]]]
       names = temperature, external temperature, humidity, battery, pulsecount
       datacodes = h,h,h,h,L
       scales = 0.1,0.1,0.1,0.1,1
       units = C,C,%,V,p

[[24]]
    nodename = emonth6
    [[[rx]]]
       names = temperature, external temperature, humidity, battery, pulsecount
       datacodes = h,h,h,h,L
       scales = 0.1,0.1,0.1,0.1,1
       units = C,C,%,V,p

[[25]]
    nodename = emonth7
    [[[rx]]]
       names = temperature, external temperature, humidity, battery, pulsecount
       datacodes = h,h,h,h,L
       scales = 0.1,0.1,0.1,0.1,1
       units = C,C,%,V,p

[[26]]
    nodename = emonth8
    [[[rx]]]
       names = temperature, external temperature, humidity, battery, pulsecount
       datacodes = h,h,h,h,L
       scales = 0.1,0.1,0.1,0.1,1
       units = C,C,%,V,p

[[11]]
    nodename = zolder
    [[[rx]]]
       names = powerL1, powerL2, powerL3, power4, Vrms, temp1, temp2, temp3, temp4, temp5, temp6
       datacode = h
       scales = 1,1,1,1,0.01,0.1,0.1,0.1,0.1,0.1,0.1
       units =W,W,W,W,V,C,C,C,C,C,C
[[28]]
    nodename = ketel
    [[[rx]]]
       names = temp1, temp2, temp3, temp4, temp5, rsi

[[29]]
    nodename = boiler
    [[[rx]]]
       names = temp1, temp2, temp3, temp4, temp5, rsi


2016-07-09 16:05:03.226|WARN|phpmqtt_input.php|Starting MQTT Input script
2016-07-09 16:05:05.324|WARN|phpmqtt_input.php|Subscribing to: emon/#
2016-07-09 16:05:05.326|WARN|phpmqtt_input.php|Not connected, retrying connection
2016-07-09 16:05:05.328|WARN|phpmqtt_input.php|Connecting to MQTT server: Connection Accepted.: code: 0
2016-07-09 16:05:05.329|WARN|phpmqtt_input.php|Subscribed to topic: emon/#emoncms

No problem, all looks Ok with your configuration. I will need your emonhub.log file to debug further

Hi Glyn,

Sorry for the late reply…I had some holiday…
so find below some emonhub.log information.

If I check with mosquitto_sub -v -u ‘emonpi’ -P ‘emonpimqtt2016’ -t ‘emon/#’ I see a lot of information passing…so mqtt is running well I suppose…
Hope you can help

Regards

Herbert

2016-08-02 19:39:32,233 INFO     RFM2Pi     Publishing: emon/zolder/rssi -95
2016-08-02 19:39:32,234 INFO     RFM2Pi     Publishing: emonhub/rx/11/values 10,0,0,0,240.94,0
2016-08-02 19:39:32,236 INFO     RFM2Pi     Publishing: emonhub/rx/11/rssi -95
2016-08-02 19:39:32,238 DEBUG    RFM2Pi     457796 adding frame to buffer => [1470159572, 11, 10, 0, 0, 0, 240.94, 0, -95]
2016-08-02 19:39:32,239 DEBUG    RFM2Pi     457796 Sent to channel' : ToEmonCMS
2016-08-02 19:39:33,379 DEBUG    RFM2Pi     Discarding RX frame 'unreliable content'? 239 0 128 42 72 65 152 66 12 (-109)
2016-08-02 19:39:33,624 DEBUG    RFM2Pi     Discarding RX frame 'unreliable content'? 208 12 8 20 72 122 50 136 20 155 186 75 240 31 20 36 33 228 32 166 163 (-109)
2016-08-02 19:39:35,117 INFO     emoncmsorg sending: https://emoncms.org/input/bulk.json?apikey=E-M-O-N-C-M-S-A-P-I-K-E-Y&data=[[1470159550,11,5,0,0,1,240.94,0,-96],[1470159555,10,758,220,1,31,236.66,21.1,-55],[1470159561,11,1,0,0,1,240.55,0,-93],[1470159566,10,565,0,1,30,236.79,21.1,-55],[1470159569,28,215,202,203,203,206,0,-92],[1470159572,11,10,0,0,0,240.94,0,-95]]&sentat=1470159575
2016-08-02 19:39:35,298 DEBUG    emoncmsorg acknowledged receipt with 'ok' from https://emoncms.org
2016-08-02 19:39:35,299 INFO     emoncmsorg sending: https://emoncms.org/myip/set.json?apikey=E-M-O-N-C-M-S-A-P-I-K-E-Y
2016-08-02 19:39:37,048 DEBUG    RFM2Pi     Discarding RX frame 'unreliable content'? 205 16 6 32 242 8 32 128 126 188 56 0 62 38 129 72 4 8 133 3 140 (-110)
2016-08-02 19:39:38,158 DEBUG    RFM2Pi     Discarding RX frame 'unreliable content'? 98 33 2 88 194 104 25 212 8 72 2 209 144 139 52 34 19 66 53 28 54 (-110)
2016-08-02 19:39:38,461 DEBUG    RFM2Pi     457797 NEW FRAME : OK 10 40 2 0 0 0 0 30 0 153 92 211 0 (-54)
2016-08-02 19:39:38,464 DEBUG    RFM2Pi     457797 Timestamp : 1470159578.46
2016-08-02 19:39:38,464 DEBUG    RFM2Pi     457797 From Node : 10
2016-08-02 19:39:38,465 DEBUG    RFM2Pi     457797    Values : [552, 0, 0, 30, 237.05, 21.1]
2016-08-02 19:39:38,466 DEBUG    RFM2Pi     457797      RSSI : -54
2016-08-02 19:39:38,466 INFO     RFM2Pi     Publishing: emon/kelder/power1 552
2016-08-02 19:39:38,468 INFO     RFM2Pi     Publishing: emon/kelder/power2 0
2016-08-02 19:39:38,470 INFO     RFM2Pi     Publishing: emon/kelder/power3 0
2016-08-02 19:39:38,471 INFO     RFM2Pi     Publishing: emon/kelder/power4 30
2016-08-02 19:39:38,473 INFO     RFM2Pi     Publishing: emon/kelder/vrms 237.05
2016-08-02 19:39:38,474 INFO     RFM2Pi     Publishing: emon/kelder/temp1 21.1
2016-08-02 19:39:38,476 INFO     RFM2Pi     Publishing: emon/kelder/rssi -54
2016-08-02 19:39:38,477 INFO     RFM2Pi     Publishing: emonhub/rx/10/values 552,0,0,30,237.05,21.1
2016-08-02 19:39:38,479 INFO     RFM2Pi     Publishing: emonhub/rx/10/rssi -54
2016-08-02 19:39:38,481 DEBUG    RFM2Pi     457797 adding frame to buffer => [1470159578, 10, 552, 0, 0, 30, 237.05, 21.1, -54]
2016-08-02 19:39:38,481 DEBUG    RFM2Pi     457797 Sent to channel' : ToEmonCMS

Hi Glyn,

Just for your info …I was looking around on other topics and did a sudo service mqtt_input restart
And suddenly everything is working fine.
So definitively something is wrong with the MQTT service…

Regards

Herbert

1 Like