Community
OpenEnergyMonitor

OpenEnergyMonitor Community

EmonTH Nodeid not changing when DIP switches changed

I’ve just purchased an emonBase and two emonTH sensors. I’ve setup the base OK and one of the emonTH sensors. This one is configured with both DIP switches OFF.

Adding the second emonTH was unsuccessful. the DIP Switches are set to On-Off. Looking at the log shows that both devices are sending NodeID 23, whereas the second one should be 24 I think. I tried changing the DIP switches and cycling the power, but no change: it always sends nodeID 23.

Obviously, I could just change the other device’s NodeID but I’d rather solve the problem rather than just avoid it.

Before I connect a serial adapt, is there anything I can check?

Welcome, Gareth, to OEM.

I’m sorry you appear to have a problem with one of your emonTHs.

I don’t think there is. I presume you’ve changed the switch a few times in case there’s some dirt or other contamination in it that might move? If that doesn’t solve it, I think it sounds like a faulty switch, or maybe an assembly problem.

If you have the serial adapter, then that’s probably the easier alternative (than contacting the shop and probably returning the unit).

All you need to do is supply the access code +++ as it starts up with the programmer connected and the Arduino’s IDE showing the Serial Monitor, and set the “base” node ID to the number you want, which will indeed be 24.

If you do want to contact the shop for a replacement, email [email protected]
I’ll mention @Gwil here so he’ll see this thread and he’ll be aware of the problem.

Thanks @Robert.Wall. I’ll reprogram it for now. I’ll be ordering more soon, so hopefully these won’t have the same problem.

You don’t need to reprogram as such, all you’re doing is setting a variable in EEPROM that’s read at startup.

@Robert.Wall Sorry, bad term to use. I know what I meant :slight_smile:

You could edit the source code to make the NodeID 24 permanently, then upload the sketch, if you so wished. It’s an equally valid approach, and what I thought you meant.