PCMadman,
You might want to try to utilise some of the wealth of code available for the Arduino (ATmega168,328 and 1280). This includes a complete integrated design environment, bootloader and useful libraries for I/O, serial comms, ethernet/TCP/IP communications etc.
I'm not sure of your background, and forgive me for assuming that you are not a professional embedded programmer, but starting from scratch to get a full USB datalogging running on your ATmega32U6 would be a substantial undertaking. I see from the datasheet that it has a USB bootloader already on-chip, and hopefully Atmel have complemented this with a nice user friendly bootloading application to run on the PC.
However, if you try to retain some compatability with the Arduino - you know that you have a huge wealth of code resources out there already, plus most of the hardware drivers to I2C, dataflash, ethernet, TCP/IP stack etc.
Counting the pulses from the gasmeter is the trivial part. Getting them into the PC, or direct up to the web, and then presenting the data in a useful manner is the bulk of this project - and the part that most people are going to have to use and interract with.
Several people on this forum have written their own presentation applications, and I can assure you that there are a significant number of people, both as individuals or organisations who are doing similar. Almost every utility now has on line viewing of historical consumption data. Some of these packages are good, some are so buggy and limited that I can't see why the utility has bothered. My dealings with the British Gas online graphing were a very bad experience. The package assumed that if you didn't have any data for the current quarter, then it would assume that you used 327670 kWh of gas - purely down to poor coding and a maths error.
Some of the electricity packages are not much better. They will show you monthly, weekly and daily - but half hourly would be a lot better. You might also want to compare Saturday 24th with Saturday 31st october - to see if your consumption had changed between particular days. Very few graphing packages have these capabilities.
This said, you might want to look at the work by Dale Lane - one of the IBM hackers of the CurrentCost electricity monitor. He decided to write his own graphing package
http://dalelane.co.uk/blog/?p=872CurrentCost are now distributing digital input boards to work alongside their electricity monitor. You can use these for pulse-counting and then feed the data through the CurrentCost, where it logs it and generates an XML formal serial output data. For someone who already has a CurrentCost, this might be one of the quickest ways to get something up and running.
Finally a word about data storage. Back in the late 1990s when I had to design a wireless gas meter pulse counter which communicated with a PSTN modem for data output, memory was still quite expensive. The design could only afford a 128Kx8 static RAM - and so I was tasked with finding some way to package sufficiently fine grain gas data - for at least a years worth of daily consumption into the 128K available.
My solution was to allow 256 bytes per day - which consisted of 240 pulsecount readings taken at 6 minute accumulations - each reading was allowed one byte, limiting you to 255 pulses per 6 minutes - enough for even the largest of gas consumers. The remaining 16 bytes was a header (or footer) which said what day/date the data pertained to, and what the daily absolute start total was.
32 of these daily blocks would be packaged into a monthly block which was 8K bytes. There would always be at least one spare daily block at the end of the "month" as no month, to my knowledge, exceeds 31 days. This was a convenient way of being able to access a particular month's data. For example August being the 8th month - just index 8x 8K into the address range and read out whichever daily block you need.
So, using this simple scheme, it made data retrieval very easy. You always new where to search in the address space for given dates - as these were tied to the calendar. At midnight on the realtime clock, you just start accumulating your data in the next daily block - and you could store 16 months worth of data in a relatively small memory device - at 6 minute granularity which at 10 readings per hour is almost optimum to show the fine detail of gas or electricity consumption. Whilst once per second data might be interesting - it really needs to be accumulated (smoothed) over a larger time window to give a presentable graph.
These days of huge, cheap data flash memories (8Mbit for about £2.50) allows vast quantities of data to be logged - but a thought should be given to how it is best organised for retrieval and more importantly, display.
MyOzone - that would be the discontinued DS2423 - data sheet says not for new designs.
http://www.maxim-ic.com/quick_view2.cfm?qv_pk=2912I think however Philips/NXP have a pulsecounter on an I2C bus - they certainly used to back in 1998
Ken