Wednesday, December 17, 2008

Itron Remote Read Meter Protocol Notes

This entry is simply a collection of notes about the Itron Remote Read Electric Meter protocol. Since I'm getting to the point with my AVR Butterfly where I will need to start feeding it actual meter data I need to know more about the data format. So here are the interesting bits I'm finding.

These notes are from a patent assigned to EnScan, and may or may not be relevant to the Itron meter.

The transponder signal is comprised of a series of eight spaced transmission bursts, or transponder information packets.

Each transponder information packet is separated in time from adjacent transponder information packets by a predetermined period S.

Each transponder information packet is transmitted at a pseudorandom frequency ranging from 912 MHz to 918 MHz.

Each transponder information packet within a single transponder signal is identical.

Transponder information packets are divided into a plurality of data fields including preamble field, spare field, instrument type field, instrument parameter field, tamper field, instrument identification field and error control code field.

The transmission of each transponder information packet begins with preamble data field with bit sequence 111110010101001100000 which provides bit sync and word sync for digital decoders within the receiver.

The spare data field follows the preamble field and is five bits in length and is reserved for future use.

The instrument type field follows the spare bit field and is four bits in length. It contains data representative of the particular type of instrument with which transponder is associated.

The instrument parameter field follows instrument type field and is twenty-two bits in length. It contains data representative of the parameter sensed by meter

The tamper field follows instrument parameter field. It is a four bit field and contains data representative of tampering.

The instrument identification field follows tamper field, and is twenty-four bits long. It contains data identifying the particular meter with which the transponder is associated.

Transponder information packets end with the 16 bit error control code field the contents of which is produced as a function of the data contained in the spare, instrument type, instrument parameter, tamper, and instrument identification data.

The BCH encoder produces a BCH error control code constructed of a shortened 255, 239, 2 code Galois field generated by the following polynomial: P(X)=1+X+X5 +X6 +X8 +X9 +X10 +X11 +X13 +X14 +X16.

The Manchester encoder implements a Manchester I encoding scheme. Manchester encoders are well known and produce a code in which a data clock is embedded into the data stream.

The Manchester encoded bit stream forming the transponder information packet is used to on-off key (OOK) the carrier signal.

The sequence timing control is unresponsive to enable signals from the enable circuit for 10 seconds after transmission of a final transponder information packet of transponder signal. If after this predetermined "dead time" period the transponder receives another activation signal, the sequence timing control will initiate transmission of another transponder signal.

Patent for a system that reads meters for an in-home display:


Thursday, December 4, 2008

Arduino on the AVR Butterfly

When I started my Itron meter reader project I had to get the AVR Butterfly up and running under AVR Studio. This was a little tedious but eventually I got it working. While I was doing that I thought that it would be useful to be able to run Arduino code on the Butterfly. I looked around a bit and found that there was a thread on the forum about doing just this.

I went on with AVR Studio, but just the other day user Nick Lott posted some of the groundwork that sets up the Arduino IDE to work with the butterfly. After a bit of poking around with it to get the clock frequency and USART set up properly, it's working great. The AnalogInput sample even reads the light sensor and writes to the piezo speaker out of the box (the brighter the light, the faster it ticks).

I made the following changes.

Edit boards.txt to update to 8Mhz:

This didn't seem to have any effect so I edited the butterfly\makefile to update to 8Mhz:
F_CPU = 8000000

Update 2009-Jan-30

I have written (or adapted code for) several classes to handle the Butterfly's hardware. The LCD, temp sensor, dataflash chip, and RTC clock all have easy-to-use interfaces now. The LCD class could be better, it needs some error checking and doesn't integrate with the Print class as nicely as it could, but it's quite functional.

The project is up on Google Code, feel free to check it out.