Landis+Gyr GridStream Protocol: Difference between revisions
→Capture files from various regions: Added a raw capture from Seattle City Light in Seattle, WA |
|||
| Line 7: | Line 7: | ||
====Sync and Header==== | ====Sync and Header==== | ||
----The | ----The Landis+Gyr Gridstream smart meters use a 52 bit sync shown below regardless of Gridstream version. This can be used in GNU Radio along with the header to uniquely identify packets. Note that at the start of the header we begin using start and stop bits. These must be stripped off of the rest of the data packet during processing. | ||
{| class="wikitable" | {| class="wikitable" | ||
|+Sync | |+Sync 52 bits long | ||
! colspan=" | ! colspan="7" |Sync | ||
|- | |- | ||
!0xAA | |||
!0xAA | !0xAA | ||
!0xAA | !0xAA | ||
| Line 19: | Line 19: | ||
!0xAA | !0xAA | ||
!0xA | !0xA | ||
|- | |- | ||
|10101010 | |||
|10101010 | |10101010 | ||
|10101010 | |10101010 | ||
| Line 29: | Line 27: | ||
|10101010 | |10101010 | ||
|1010 | |1010 | ||
|} | |||
----Of particular note is the difference between versions 1-4 and version 5. In version 5 there are two bits [11] that do not respect the start/stop bit checks of the prior versions. The older protocol expects a 0 start bit, bit data bits and a 1 stop bit. By violating two consecutive start bits the older versions of Gridstream ignore version 5 even if they have the same CRC Adder! This appears to be a way to add backwards compatibility to newer versions of Gridstream. | |||
{| class="wikitable" | |||
|+Header for Gridstream | |||
! colspan="3" |Header v1 - v4 | |||
! rowspan="3" | | |||
! colspan="3" |Header v5 | |||
|- | |||
!0x00 | |||
!0xFF (10 bit) | |||
!0x2A | |||
!0x00 | |||
!0xFF (11 bit) | |||
!0x2A | |||
|- | |||
|0 '''00000000''' 1 | |0 '''00000000''' 1 | ||
|0 '''11111111''' 1 | |0 '''11111111''' 1 | ||
|0 '''00101010''' 1 | |||
|0 '''00000000''' 1 | |||
|[11] '''11111111''' 1 | |||
|0 '''00101010''' 1 | |0 '''00101010''' 1 | ||
|} | |} | ||
Using GNU Radio it was found that shortening the Sync requirements a bit and incorporating part of the header leads to the cleanest data for further downstream processing. The modified sync shown in 8 bit chunks is shown below. | ----Using GNU Radio it was found that shortening the Sync requirements a bit and incorporating part of the header leads to the cleanest data for further downstream processing. The modified sync shown in 8 bit chunks is shown below. | ||
{| class="wikitable" | {| class="wikitable" | ||
|+Sync Word used with GNURadio | |+Sync Word used with GNURadio | ||