Som questions about the EmonTX/NanodeRF

Hi!

This is my first post here, i am very happy with the effort from this community to create this fantastic energy monitoring suite.

I have the Raspberry & Emon V3 setup, wich was quite easy to setup. And also a EmonTX with Nanode RF that is not so easy to setup.

 

I have looked across this site to try to find som simple 1-2-3 setup guide for this arduino board but cant seem to find it.

 

Some questions remain.

- Does the Nanode come preloaded with the firmware and software it needs or do i have to program the unit myself?

- How can i set this unit up with my API key for posting to emoncms?

- Where can i find specific detailed information on how to connect dallas sensor, wich ports to be used?

- How many dallas sensors can be connected to one port?

- Can this unit be configured to have 3 CTs, One optical pulse sensor or two, and 5 dallas sensors?

 

I am also interested to know if the EmonTX V3 can use multiple dallas sensors on one bus? How many can be used? Do i need to upload some new arduino sketch or do some alterations to the software in any way for this to work or will it automaticly be listed more incoming data in emoncms?

 

Would be happy if there is such a thing as a simple 1-2-3 setu guide where i can just follow instructions to get my data online.

Hope that someone has the time to give me some pointers.

Thanks

Robert Wall's picture

Re: Som questions about the EmonTX/NanodeRF

"Some questions remain.

- Does the Nanode come preloaded with the firmware and software it needs or do i have to program the unit myself?"

It comes with a Bootloader, but no sketch. You can find suitable sketches on GitHub. https://github.com/openenergymonitor/NanodeRF (Do NOT use the latest Ethercard library, use the OCT2012 version.)

"- How can i set this unit up with my API key for posting to emoncms?"
You enter your APIkey in the sketch.

"- Where can i find specific detailed information on how to connect dallas sensor, wich ports to be used?"

"- How many dallas sensors can be connected to one port?"

"- Can this unit be configured to have 3 CTs, One optical pulse sensor or two, and 5 dallas sensors?"

Do you mean the emonTx or the NanodeRF? I think the Nanode RF cannot do more than operate as a base node because there is insufficient memory. That is the reason you must use the old Ethercard library and not the latest version. If you are asking about your other emonTx, which version is it?

"I am also interested to know if the EmonTX V3 can use multiple dallas sensors on one bus? How many can be used? Do i need to upload some new arduino sketch or do some alterations to the software in any way for this to work or will it automaticly be listed more incoming data in emoncms?"

The emonTx V3 can use more than one temperature sensor, but only if you use a separate 5 V supply. The current available when using the ac adapter as the only power source is insufficient for more than one. If you do have an external 5 V supply, then you can have many sensors. How many depends on the topology of the connections, there is some guidance in Building Blocks. The default emonTx V3.4 "discrete sample" sketch will, without modification, read up to 6 sensors and send the temperatures.

goodfidelity's picture

Re: Som questions about the EmonTX/NanodeRF

Thank you kindly for fast and accurate information.

I will just have to dig in to the sketches and try to design the sketch that i need. Probably start with the default sketch for the Nanode/TXShield. 

I still have som questions:

- What is the name of default sketch for NanodeRF + TX Shield combination? Do i need multiple files to put together one sketch or is this all pre-made somewhere?

- Can the Emon TX Shield for NanodeRF use multiple Dallas sensors? Does it require special sketch?

- Can i add something to the sketch in order to get optical LED pulse readout from the NanodeRF/TX shield? I need input for two sensor readers. I already have the hardware for one.

- There is four inputs where the dallas should go on my TXShield, two for power and two others with the text "dallas". Is this two separate inputs for dallas sensors or is it something else? In the pictures for this product in the shop there is only three inputs. On my unit however there are four.

 

Many questions, but i see so much potential in these gadgets that i really want to find out. I read all the info on the site Wiki and the webshop but this info seems to be missing. Thanks to anyone who would like to fill in this info.

 

 

Robert Wall's picture

Re: Som questions about the EmonTX/NanodeRF

I shall repeat what I wrote above: I do not think the NanodeRF is capable of doing any more than operating as a base node. I think if you try to add an emonTx Shield and then merge the functions of the emonTx sketch into the NanodeRF sketch, you will fail, because there is insufficient memory available in the ATmega 328P. That is the reason why there is no sketch for the combination of emonTx Shield + NanodeRF.

goodfidelity's picture

Re: Som questions about the EmonTX/NanodeRF

Hi!

 

Thank you kindly for  repeating this information.

In the shop it looks like this shield and the Nanode should work together, but maybe they dont. 

It is stated that:

"Compatible with OpenEnergyMonitor modules (emonGLCD, emonBase - NanodeRF etc.)"

 

"Product Description

The emonTx Shield is an open source hardware arduino shield footprint compatible electricity and temperature monitoring shield that can be connected to any standard Arduino UNO, Leonardo, NanodeRF (for web connectivity and posting to emoncms.org) or even the new Arduino Yun."

 

 

But maybe that means communication with these modules by radio, and not direct connect?

I cant really understand how the shield should be used? Do i need another Arduino board just to operate the shield? And then go by radio to the Nanode that will upload the info? Thats a bummber because my shield does not have RF chip.

Is it possible or not to use the Nanode for energymonitoring, or is it only possible to relay the signal from other units?

Can this unit handle for example just two optical pulse readers and 5 dallas sensors or is the momory not enough for any kind of sensors?

 

I am tempted by the fact that this can be one unit, and not a network of multiple units, that can be used for independent energy monitoring. With this unit it would be possible to build €30 energy monitoring hardware that uploads info to emoncms. IF it worked as i assumed.

 

I really need some info on this.

 

Thanks kindly for the response!

 

 

Robert Wall's picture

Re: Som questions about the EmonTX/NanodeRF

The emonTx Shield is indeed normally used with a stand-alone Arduino board, and it adds the capability for 4 CTs and one voltage input, the temperature input and the radio module.

Normally, the Nanode RF has always and, as far as I am aware, only been used as a Base node. I've asked Glyn Hudson or Trystan Lea to comment.

goodfidelity's picture

Re: Som questions about the EmonTX/NanodeRF

Ok, thanks. Then i would need another RF module on the Shield as i lacks one. I thought i could use it with the Nanode straight away.

 

I am still interested in getting more details regardin my wanted setup.

 

- Is it possible to monitor 3CT, 6 Dallas, and two LED pulse inputs with one TX shield?

 

The perfect setup for me would be one unit, with ethernet included on the board, measuring these points. Relay output would be bonus.

 

Thank you kindly for your fast replys

Robert Wall's picture

Re: Som questions about the EmonTX/NanodeRF

There should be no problem with monitoring 3 CTs and 6 DS18B20s, but you might have a problem with the two LED pulse inputs, as those would connect directly to the Arduino, and in order to use the usual interrupt-driven routine, you would need two free interrupts. I am not an Arduino expert, but someone who is might be able to help you here.

TrystanLea's picture

Re: Som questions about the EmonTX/NanodeRF

Hello goodfidelity, Robert. I did put together an example a year ago for the EmonTxShield and NanodeRF together here:

https://github.com/openenergymonitor/emonTxFirmware/blob/master/emonTxSh...

Its been a while since I've ran it, Has this stopped working with the more recent library? I havent got the Nanode with me here but can test when Im in the office on Monday.

dBC's picture

Re: Som questions about the EmonTX/NanodeRF

 in order to use the usual interrupt-driven routine, you would need two free interrupts

There's a table here that shows which Arduino pins are mapped to which interrupt vectors on various Arduino models:  http://www.arduino.cc/en/Reference/AttachInterrupt.  Then you just need to find two that aren't being used by your shield(s) for other purposes.

goodfidelity's picture

Re: Som questions about the EmonTX/NanodeRF

Hi Trystan and Robert!

I am really new to Arduino and still have not even uploaded a sketch. 

I am trying to figure out the limits and possibility before i start planning how to set up the system, so that is why i am doing this research about the Nanode with TXshield. 

I like the concept of one small, cheap unit providing all that i need and sending it straight out to the emoncms.

And what i wanted from the beginning was the possibility to run:

- 3 CTs

- AC/AC adapter

- 5 Dallas sensors

- One or Two optical sensors for pulse counting. S0 (TTL pulse) might work as well.

 

For technical reasons i understand that there are limits in the arduino platform which will not allow this. So maybe now i should focus on what is possible.

Maybe its enough with just 3 CTs, AC/AC and 5 dallas units. As the CTs install quick and easy.

Or maybe just 5 dallas units and two optical pulse inputs. And use external power meters with pulse output. This is more expensive, more difficult to install but very accurate. And most cases i would need only one power meter and one pulse input anyway.

 

The equipment will be used to monitor ventilation systems. And since there sometimes are many systems in one building i just want one unit to handle measuring temperatures and power consumption. Installation needs to be cheap and fast. I prefer ethernet, but sometimes it might go through ethernet bridge.

 

What is the damage, can this be done with one single ardunioboard that has ethernet output, like the Nanode? Just adding the EmonTX shield?

Thank you for all the help so far!

 

//J

 

goodfidelity's picture

Re: Som questions about the EmonTX/NanodeRF

Hi dBc!

Thank you for the reply!

 

I wish my technical knowledge about this platform was more extended. However even if i look at that webpage i really cannot make any clear picture from what i read.

I understand that some of the pins on the Arduino/Nanode board are analouge, and some of them ar digital.

I also have some kind of idea that there are different kinds of digital inputs, but i dont know how they are different. 

Is it correct if i assume that "interrupts" are the digital inputs? And for each pulse counter i would need two digital inputs avalible? 

Thanks for the patience

 

//J

dBC's picture

Re: Som questions about the EmonTX/NanodeRF

I understand that some of the pins on the Arduino/Nanode board are analouge, and some of them ar digital.

Yes, that's probably the easiest way to think of it.  Strictly speaking they're all digital, it's just that only some of them can be used as analog inputs.   If ever you run out of digital pins, and you've spare analog pins that you don't plan using, you can use them as digital pins.    The pins live in PORTS, 8 pins per PORT.  Atmel recommend that if you have analog and digital pins in the one PORT, then you avoid any switching on the digital pins during an analog conversion.  That might be hard to arrange so the Arduino model of "here are your analog pins, and here are your digital pins" is a nice safe way to go.

I also have some kind of idea that there are different kinds of digital inputs, but i dont know how they are different. 

Yes.  The AVR has a bunch of features, like PWMs, Timers, Interrupt Controller, ADC etc etc.   Each of those features can only use restricted pins from the pool of all digital pins.  So if you want   to do PWM, you need to choose a pin that the PWM controller can access.  If you want to use the ADC, you have to choose a pin that the ADC can access (referred to as the "Analog Pins" above).  In your case, if you want to use the Interrupt Controller, you need to choose some pins that the interrupt controller can access.

To further complicate things, the Arduino runtime (and even your Arduino board) won't necessarily give you access to all of the pins that you could otherwise have used.   For example on the ATMega2560 chip, I think I can use 32 different pins as interrupt pins  (INT0:7 and PCINT0:23), but some of them I can only get to if I've designed my board to let me at the signals, and written my own software to configure them as interrupts.

Assuming you want to stick to stock standard Arduino designs, and use stock standard Arduino interrupt set-up code, then the table I referenced above tells you which pins you can use on various models.

And for each pulse counter i would need two digital inputs avalible? 

I'm not familiar with the sketch in question, so can't really comment on that.  I'd be surprised if you need two per pulse-counter.... one should be enough.

 

 

goodfidelity's picture

Re: Som questions about the EmonTX/NanodeRF

Thanks dBC!

I getting more and more understanding for how the board works. Its nice that you guys knows so much about all the hardware and software. I feel this will make a steep learning curve for me.

I am really interested now to know the exact limitations for the Nanode, what can it do and what it cant do in terms of beeing used as a stand alone energy monitoring unit.

Trystan seems to have tried it out, so i am really interested to know what is possible.

I am really enthusiastic about running the Nanode as a small, cheap and simple energy monitor with some temperature measuring capability. 

As mentioned earlier this can be mde very simple with the help of external energy meters.

//J

 

goodfidelity's picture

Re: Som questions about the EmonTX/NanodeRF

Hello again guys!

 

I just spent som time thinking about this that you all put in to this thread, and as i am not as much into hardware or programming i might be a bit off.

But my thinking is this:

Due to som limitations in the Nanode, it is difficult to use it for other things then as a base station.

And if it is to be used for other things, this needs to be simple stuff. Like reading the dallas sensor output.

Also i heard that sometimes it takes a long time for the communication process to finish (RJ45) and that might cause counting errors when counting pulses.

My conclusion was that there should be a simple one wire counter, that can be attached to the Nanode just like a Dallas sensor. And by simply letting the counter do the work, it only has to be read every now and then by the Nanode. This can allow longer intervals between operations on the Nanode (lower frequency?), if that is of any help to power saving if running on battery.

I found this chip:

DS2423: http://www.maximintegrated.com/en/products/comms/one-wire/DS2423.html

And after some googleing i found this, which seem to be what i am looking for:

http://forum.arduino.cc/index.php?topic=91087.0

This configuration will never loose count. And even if the network connection fails, or power fails to the Nanode, or the Nanode fails.. It will still be counting pulses. Time stamps however will be lost.

I can imagine, that there should be no problem fitting one of these and some Dallas sensors to the Nanode and use it as a one board energy monitor? And with the DS2423 always storing the count, it can be used to verify data already collected if anyone would need that.

Would it be possible, or very easy, to make a NanodeRF with two pulse counting inputs on the DS2423, and some inputs for Dallas or DHT22 sensors?

Thanks for all the good input so far!

//J

 

Comment viewing options

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