New node data not showing in Emoncms.org

@TrystanLea as now confirmed this isn’t working as expected so to have non-timestamped payload delete or comment out the timestamped value altogether as any value there True,true,False,false will require a timestamp, this is a bug and I will take a look once i get a emonpi set up again.

[edit - Issue raised so it doesn’t get forgotten :slight_smile: ]

Prior to the exception I sent the six values to the emonhub socket (timestamp 98 6.8 6.2 8.6 77.0) and after that followed the log snippet I sent.

Nothing else happened since I am working in a test environment.

I think you mean (timestamp 98 6.8 6.2 8.6 77.0), had you sent a timestamp I would have worked, albeit with a timestamp. However just knowing the position of the “6.8” in the payload would have helped, Trystan has now tried this and confirmed the situation so I don’t need the log entries now.

For now comment out or delete the timestamped = line for non-timestamped data.

@TrystanLea has also confirmed data getting to emoncms so hopefully it should all work for you once you define the channel(s).

@lgheorghe and for anyone else interested, I put together the following python test script to test this feature:

import socket, time
s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
s.connect(('localhost', 8080))
s.sendall('98 3.8 1.6 5.2 80.3\r\n')

and my emonhub conf entry is:

[[sockettests]]
        Type = EmonHubSocketInterfacer
        [[[init_settings]]]
                port_nb = 8080
        [[[runtimesettings]]]
                pubchannels = ToEmonCMS,

Which results in the following emonhub.log

2018-01-30 22:11:03,782 DEBUG    sockettests 2 NEW FRAME : 98 3.8 1.6 5.2 80.3
2018-01-30 22:11:03,782 DEBUG    sockettests 2 Timestamp : 1517350263.78
2018-01-30 22:11:03,783 DEBUG    sockettests 2 From Node : 98
2018-01-30 22:11:03,783 DEBUG    sockettests 2    Values : [3.8, 1.6, 5.2, 80.3]
2018-01-30 22:11:03,783 DEBUG    sockettests 2 Sent to channel(start)' : ToEmonCMS
2018-01-30 22:11:03,783 DEBUG    sockettests 2 Sent to channel(end)' : ToEmonCMS

and emoncms inputs as expected when used with either the emoncms http interfacer or the mqtt interfacer.

You are right - it was without the timestamp.
The string sent was: 98 6.8 6.2 8.6 77.0 - where 98 is the nodeid and 6.8 is the first data value.

I’ve fixed the timestamp property bug and updated the emonhub configuration documentation with an example of how to use the socket interfacer, thanks @pb66 I can see how useful this interfacer could be now:

https://github.com/openenergymonitor/emonhub/blob/emon-pi/configuration.md