Energy monitor project - help needed for pulse counting!

Help needed!
I just received my imp and I’m enjoying getting to know it! A project I’ve been wanting to do for a while is a energy monitoring setup that “counts” the LED pulses on my energy meter and uploads it to the "cloud"
I’m trying to do something similar to this existing project.
http://openenergymonitor.org/emon/buildingblocks/introduction-to-pulse-counting
http://openenergymonitor.org/emon/buildingblocks/interrupt-based-pulse-counter

Any ideas or suggestions for counting the pulses? Can I do it with PULSE_COUNTER and with which sensor?
Help is highly appreciated!

Best, Tobias

The pulse counter is designed for counting thousands to hundreds of thousands of pulses per second; usually, the power metering pulses are a lot slower - often just a few pulses per second at the most.

For that, just registering a ping change handler that increments a number should be enough. Try to keep this handler short (ie: don’t log within the handler), though.

And tell us, or show us, what kind of meter you have. Some are digital, some are not. That will determine the sensor to use.

As planned, soon will be available very simple energy monitoring boards, imp-ready for 1 and 3 phase systems, 120V or 220V. I’ll make a note when it will be done.

Thanks for the prompt feedback!
I need the sensor to read a blinking LED with 1000 impulses/kWh, so as Hugo pointed out will the frequency be very low. So I’m thinking the TSL257 or TSL261 - they would play well with the imp right?

Peter AP: Sounds interesting with imp-ready monitoring boards! Will they be for CT sensors or blinkers as well?

A TSL part will work (make sure you get a visible light one), a phototransistor can also work if you bias it correctly.

I used an LTR-301 for my energy monitor project. I counted pulses from the IR-led for 10 seconds (10.000 imps/kWh). Even with only 1-2 pulses during the 10 seconds the imp was able to count the correct number.