emonhub.conf and Nodes

I have a Raspberry PI successfully receiving data over the serial port using the EmonHubSerialInterfacer. My first tests using the Node config below work just fine.  Any new node that I put on the network show up in the Inputs and everything is in the right place. 

[[99]]

datacode = h
datacode = l, h, h, h

But I would like to have a different data structure for different nodes. Can I create ranges with different data structures? What does the [[99]] actually mean? Should this be [[255]] if I want to have more nodes than 99?

I can't find any documentation regarding the emonhub.conf, if I am mistaken please point me in the right direction.

Regards,

pb66's picture

Re: emonhub.conf and Nodes

the [nodes] section of emonhub.conf is where you can optionally define setting for the nodes on your system. ordinarily only node ids 1 to 30 are used in emoncms as jeelib imposes a 5bit id (0-31) and emoncms has evolved predominantly around that limit. there is a 32 node max_limit set in emoncms settings that is for the purpose of limiting the number of nodes to 32 and this is implemented by setting a <32 limit on the node id. On a local emoncms it can be raised but it will still restrict the range of permissable ids rather than the count directly.

So node [[99]] was chosen as an obviously out of range example node (which alas, has turned out to be not so obvious) unless you have an active node using the id 99 the settings won't have any effect, so no this isn't an upper limit either.

Originally all emontx sketches just transmitted ints and emonhub in its default (no nodes defined) state treats all data values as signed ints, so if using a default emonTx sketch you do not need to define the node. If you were to change, for example a emonTx's sketch to one that sends data in other formats then you would need to define the node in [nodes] so emonhub knows the 'custom' (ie non-integer only) format.

This is currently a hot development area that is still being defined so more info will become available, hopefully.

Paul

bborncr's picture

Re: emonhub.conf and Nodes

Thanks for the reply! Now it makes sense.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.