Hi All,
I'm new to the world of 'OpenEnergyMonitor' and am amazed on the knowledge and enthusiasm that can be found throughout this forum. A short introduction: I myself am 46 years and live in the Netherlands. I work with unix/linux systems in the role of sysadmin but am no programmer. I'm also no electrical engineer and cannot read the schematics found around here. So soldering together my own set would not be such a great idea ;). As such the pre-assembled/build components found here in the shop would give me the perfect possibilities to put together a nice setup that should get me started. Now for measuring our power usage the bundle with the EmonTx with CT clips & RaspPI set should do the trick. I would however like to get the picture complete for our family including GAS (covering most of our utility bill) and water. Now this is the part where i'm lost a bit on the possibilities.
My GAS & Water meter are both from the company Itron and are compatible with the Cyble sensor (v2). Now from all the reading i understand that with the EmonTx v3.x you must use the pulse count screw terminal to be able to do 'something' with pulse counting.
So here are some questions i have;
Here ( https://www.itron.com/PublishedContent/Cyble%20Sensor%20EN%2003-14_Brochure.pdf ) are some more details on the Cyble sensor. On the market i can find different types of this sensor (2 wire version / 5 wire version) and a factory set so called 'K' factor (explained in the brochure). Now i know these are quite expensive but as mentioned i'm really not the guy to get my own soldering gun ;)
1st. Would this Cyble sensor be compatible to be used directly with the EmonTx v3.4 by connecting it to the ' pulse-counting screw terminal'. And if so which one, the 2 or 5 wire version and what ' K' factor and how to connect.
2nd. The EmonTx v3.4 (as i understand it) only has room to connect one pulse counter to the pulse-counting screw terminal. So if i would want to collect data from two different (Gas & Water) Cyble sensors i would also need two EmonTx v3.4 sensor nodes?. Or could the RaspberryPi be of some use here.
Any guidance is much appreciated.
Thanks & Kind regards
Patrick
Re: Cyble sensor compatibility EmonTx v3.4 (pulse counting)
I do not know enough about the Raspberry Pi to say whether that would be better, so I will only talk about the emonTx.
Your Cyble sensor requires a meter with the correct "Cyble Target". Your meters have that.
The Cyble sensor has an internal battery with a life of 12 years. Is this a concern? After 12 years (or maybe more, possibly less), you will need to replace the entire sensor.
I think you do not need the extra information that the 5-wire sensor gives you (direction of flow, both HF & LF outputs and cable cut detection), therefore the 2-wire version with K=1 is equivalent to the HF output of the 5-wire version.
The value of K determines the smallest quantity that you know about. With K=1, you have one pulse per revolution of the target. The printing on the meter face should say what that is in m3 (I cannot read that in the photograph). If it does not, you will need to count the number revolutions for one digit on the register.
I cannot think of an easy way for you to use two of these with one emonTx V3.4, so I think you will need two emonTx's. You connect the brown & white wires (either way round) to "IRQ1/Dig3" and "GND".
You will need to use a sketch that uses interrupts, and I think there is not yet one for the emonTx V3.4, therefore it will be necessary to convert the V3.2 version. This is not a major problem.
Re: Cyble sensor compatibility EmonTx v3.4 (pulse counting)
Hi Robert,
Thanks for your clear explanation, exactly what i was hoping to hear. I think i have everything now clear for myself and am going to proceed with building my set.
Thanks again.
Patrick
Re: Cyble sensor compatibility EmonTx v3.4 (pulse counting)
If a utility meter provides an optical output, the activity can be captured using a simple LDR-based sensor. This can be polled every mains cycle (or every few milliseconds) to find the LED's state. This approach can use any of the IO pins.
On the emonTx V3, IO ports 5 and 19 are available at the 6-way terminal block in addition to digital 2 or 3 which supports interrupts.
Re: Cyble sensor compatibility EmonTx v3.4 (pulse counting)
The Cyble detector appears to use a 'metal detector' technique to determine the passing of the flag on the "fast" indicator, and the gas meter certainly does not have an optical pulse output—rather a reflective spot on the "first drum". To use that would require a LED illuminator, a detector and a means of mounting both that would also exclude ambient light, and as Patrick isn't a constructor, it's a non-starter. So he's better to stay with a proven device that doesn't require development beyond converting a sketch.
Re: Cyble sensor compatibility EmonTx v3.4 (pulse counting)
OK, Robert, I'm not familiar with the Cyble detector. I was simply picking up on the comment that:
... with the EmonTx v3.x you must use the pulse count screw terminal to be able to do 'something' with pulse counting.
If the meter provides an optical output, it is possible to use any of the IO ports for this purpose.
Re: Cyble sensor compatibility EmonTx v3.4 (pulse counting)
Hi,
Thanks for all the info provided. I just placed my order and hope i will get things going. Looking forward to playing around with it. In the mean time i'm learning every day here. This community is amazing.
Could well be i'll be posting some more questions in the near future when running into issues. But that's part of the fun. ;)
Thanks again all.
Kind regards
Patrick
Re: Cyble sensor compatibility EmonTx v3.4 (pulse counting)
"If the meter provides an optical output, it is possible to use any of the IO ports for this purpose."
It doesn't. They are gas and water meters and so do not have access to an electrical supply. The data sheet notes: "the fast duration of the pulse does not allow to connect electro-mechanical relays". From that I deduce that the pulse is less than a few hundred milliseconds wide, but they do not disclose anything else about it. It may well be wider than 20 ms and thus could be polled once per mains cycle by a standard input, but we cannot take that for granted and I think the only safe way is to use the interrupt input.
Re: Cyble sensor compatibility EmonTx v3.4 (pulse counting)
Did you get this to work ?
Have a watermeter with Cyble Sensor, so if it works for you i will go the same way.
Re: Cyble sensor compatibility EmonTx v3.4 (pulse counting)
Hi Larsjo,
That's a coincidence, just finished updating the emontx with latest FW (including pulse counting), going to try the cyble sensor this weekend, will for sure let you know the outcome. Furthermore i thought i had the itron cyble sensor compatible gas meter but was mistaking in that, so ordered a reed switch from flukso for the gas meter.
Kind regards
Patrick
Re: Cyble sensor compatibility EmonTx v3.4 (pulse counting)
Hi All,
A short update on the progress on my attempts to get water & gas pulse monitoring to work.
For each of the pulse generating sensors i use a eMonTX v3.4. So i have two eMonTX v3.4 units measuring a total of 7 CT sensors.
Started with connecting the Flukso sensor to the screw terminal pins 3 & 4. (on the TX using default v1.6 sketch). This seemed a somewhat frustrating process as i could not get any stable reading. Serial connected the emonTX to see what was detected. When connected at power-on the serial console showed weird counters.
When putting a small magnet on the sensor the pulse count remained stable at the same value (so concluding the senor is working)
Connect the Cyble sensor to my other emonTX and this produced the exact same result (so large number of pulsecounts while nothing was happening). Test with a magnet failed because of the way the Cyble sensor works (hence, its generating a pulse on its own when a cycle of the meter is detected.)
So was wondering on how to proceed and started googling-around. I finally landed on the arduino tutorial pages. ( http://www.arduino.cc/en/tutorial/button ) Modified it slightly with some info found elsewhere and resulted in the following sketch.
This is basically exactly what i was hoping for, just to see if the pulses were detected correctly from both the Cyble sensor and Flukso sensor. It will light the emonTX LED whenever a pulse is detected. This worked perfectly on both the sensors, for the GAS meter whenever the last digit showed the number '7' the LED would turn on. For the cyble sensor on the water meter this also worked but could clearly distinguish it is working in another way ( hence the cyble sensor would produce a pulse for a shorter amount of time because of the way it works)
I'm thinking that if i can produce a '1' or a '0' on the console and make the LED go on and off upon detection of one cycle of the gas & water meter it can be used 'somehow' in a sketch to produce some meaningful info to pus to emoncms.
So i'm basically at the point on discovering on how to incorporate this in the emonTX discrete sampling sketch (as the currently available pulse counting in that sketch isn't working for me)
One of the things that still a question mark for me would be the working of the Flukso reed switch. (hence, if gas was used but stopped exactly when the last digit shows 7 on my meter the LED would remain on)'. As stated, i'm no programmer and having real difficulties in understanding the sketches, but taking small steps at the time.
Will update whenever something interesting evolves in my little home project. (and of course any help would be much appreciated)
Kind regards
Patrick
Re: Cyble sensor compatibility EmonTx v3.4 (pulse counting)
What you're seeing there is no doubt contact bounce. The standard pulse input and routine in the default sketch is not suitable (as you've found out) for mechanical switches. I solved this problem a long time ago - see about half way down this thread. [Beware, that sketch was for the emonTx V3.2]
Re: Cyble sensor compatibility EmonTx v3.4 (pulse counting)
Good to hear that the water reading is working.
?? why the 7 digit, is that where the magnet is ?
Any photo of the setup.
Re: Cyble sensor compatibility EmonTx v3.4 (pulse counting)
There's quite a lot of information here: http://openenergymonitor.org/emon/node/1732
Re: Cyble sensor compatibility EmonTx v3.4 (pulse counting)
Hi Larsjo
Yes indeed the last digit is triggering my (Flukso) reed switch whenever the display show a '7'. So thats the position of the dial where the magnet is best positioned for the reedswitch.
Robert pointed me into the right direction in regards to the software debouncing. Found out (after doing a lot searching on the web) there are different approaches to this. I tested out some of them. I modified my sketch accordingly and now am pretty happy with the result (although it needs some tweaking still as the Cyble sensor seems to generate a few false pulses) During all the testing i also discovered the emonhub is not receiving all of the transmissions from both of my emonTx's. So some work needs to be done there. (perhaps both emonTx's being so close together interfere with each others radiosignal?) But overall readings (both water with the Cyble sensor and Gas with the Flukso probe) are satisfying for me.
Now with the pulses coming in i'm able to do the math. For me the most important one are the costs. I know from within Emoncms you can get some cost calculations but i personally like the ' My Electric' way of showing usage. Unfortunately not possible to display costs by default. So as (not being a coder) hacked my way through the scripts and modified it to show the cost as well.
Kind regards
Patrick
Re: Cyble sensor compatibility EmonTx v3.4 (pulse counting)
Nice work. Will give it a try.