bemasher / rtlamr

An rtl-sdr receiver for Itron ERT compatible smart meters operating in the 900MHz ISM band.
GNU Affero General Public License v3.0
2.21k stars 249 forks source link

checksum for standard SCM #127

Closed gpgib6 closed 5 years ago

gpgib6 commented 5 years ago

Hi. In file scm.go, line 135 appears to rely on data scm.ChecksumVal but this data is not assigned until after the call, see lines 76 and 80.

bemasher commented 5 years ago

The scm.Checksum method is only used in the unique filter. The method p.Checksum is on the parser and references the data of the packet directly, it does not use scm.ChecksumVal.