Trouble Getting Nodes to Appear with Modified Hat [solved]

Started by brandock, June 26, 2018, 12:41:15 PM

brandock

I have been using Open Energy Monitor's stack for a long time, but want to explore using the LPL Pi Gateway stack.

I configured a new RPi 3b+, got the Pi Gateway up and running, and got the serial communication working.

Then I took a spare RFM69Pi hat from OEM and changed the firmware so that it listens to my OEM sensors but outputs what I think should be compatible with LPL Pi Gateway.

This is what I'm seeing in the gateway.sys.log:

[06-26-18_11:14:18.376] [INFO]  LOADING USER METRICS...
[06-26-18_11:14:18.393] [INFO]  LOADING USER METRICS MODULE [_example.js]
[06-26-18_11:14:35.388] [LOG]   >: [26] 1:679 2:877 3:2879 4:3293 RSS:-67
[06-26-18_11:14:35.390] [LOG]   >: [23] 1:55681 2:3362 3:17 4:0 RSS:-65
[06-26-18_11:14:35.390] [LOG]   >: [1] 1:72 2:73 3:0 RSS:-72
[06-26-18_11:14:35.391] [LOG]   >: [1] 1:72 2:73 3:0 RSS:-76
[06-26-18_11:14:35.391] [LOG]   >: [23] 1:55682 2:3382 3:14 4:0 RSS:-66
[06-26-18_11:14:35.391] [LOG]   >: [22] 1:21 2:0 3:3434 RSS:-43
[06-26-18_11:14:35.392] [LOG]   >: [26] 1:680 2:876 3:2879 4:3293 RSS:-68

But I don't see anything in the Moteino Gateway Dashboard. I was expecting to see some unconfigured nodes appear.

Any advice?

Thanks,
Brandon

brandock

I explored further and saw that I needed to define metrics that match the labels I'm sending through. Once I got those matching up my nodes appeared.

Felix


brandock

#3
Yes. Resolved. Thanks!

In case anyone else is trying to do this, here's what I did. I put the following code in my userMetrics folder, as per the example there. Restart the gateway. Now I could see all my nodes coming from emonHub-style sensors. From there I could refine my userMetrics for each node to better fit what was coming in on that node.

//Catch-all metrics for inputs coming from emonHUB-style radios 
	catchAll1 : { name:'CatchAll1', regexp:/\b1\:(\w+)/i, value:''},
	catchAll2 : { name:'CatchAll2', regexp:/\b2\:(\w+)/i, value:''},
	catchAll3 : { name:'CatchAll3', regexp:/\b3\:(\w+)/i, value:''},
	catchAll4 : { name:'CatchAll4', regexp:/\b4\:(\w+)/i, value:''},
	catchAll5 : { name:'CatchAll5', regexp:/\b5\:(\w+)/i, value:''},
	catchAll6 : { name:'CatchAll6', regexp:/\b6\:(\w+)/i, value:''},
	catchAll7 : { name:'CatchAll7', regexp:/\b7\:(\w+)/i, value:''},
	catchAll8 : { name:'CatchAll8', regexp:/\b8\:(\w+)/i, value:''},
	catchAll9 : { name:'CatchAll9', regexp:/\b9\:(\w+)/i, value:''},
	catchAll10 : { name:'CatchAll10', regexp:/\b10\:(\w+)/i, value:''},
	catchAll11 : { name:'CatchAll11', regexp:/\b11\:(\w+)/i, value:''},
	catchAll12 : { name:'CatchAll12', regexp:/\b12\:(\w+)/i, value:''},
	catchAll13 : { name:'CatchAll13', regexp:/\b13\:(\w+)/i, value:''},
	catchAll14 : { name:'CatchAll14', regexp:/\b14\:(\w+)/i, value:''},
	catchAll15 : { name:'CatchAll15', regexp:/\b15\:(\w+)/i, value:''},
	catchAll16 : { name:'CatchAll16', regexp:/\b16\:(\w+)/i, value:''},
	catchAll17 : { name:'CatchAll17', regexp:/\b17\:(\w+)/i, value:''},
	catchAll18 : { name:'CatchAll18', regexp:/\b18\:(\w+)/i, value:''},
	catchAll19 : { name:'CatchAll19', regexp:/\b19\:(\w+)/i, value:''},
	catchAll20 : { name:'CatchAll20', regexp:/\b20\:(\w+)/i, value:''},
	catchAll21 : { name:'CatchAll21', regexp:/\b21\:(\w+)/i, value:''},
	catchAll22 : { name:'CatchAll22', regexp:/\b22\:(\w+)/i, value:''},
	catchAll23 : { name:'CatchAll23', regexp:/\b23\:(\w+)/i, value:''},
	catchAll24 : { name:'CatchAll24', regexp:/\b24\:(\w+)/i, value:''},
	catchAll25 : { name:'CatchAll25', regexp:/\b25\:(\w+)/i, value:''},
	catchAll26 : { name:'CatchAll26', regexp:/\b26\:(\w+)/i, value:''},
	catchAll27 : { name:'CatchAll27', regexp:/\b27\:(\w+)/i, value:''},
	catchAll28 : { name:'CatchAll28', regexp:/\b28\:(\w+)/i, value:''}