hardware:channels:meters:power:edl-ehz:e110
Unterschiede
Hier werden die Unterschiede zwischen zwei Versionen angezeigt.
Nächste Überarbeitung | Vorhergehende Überarbeitung | ||
hardware:channels:meters:power:edl-ehz:e110 [2014/12/31 17:09] – angelegt kg | hardware:channels:meters:power:edl-ehz:e110 [2017/12/31 10:37] (aktuell) – verschoben jau | ||
---|---|---|---|
Zeile 1: | Zeile 1: | ||
- | ====== Landis & Gyr E110 ====== | + | #redirect |
- | + | ||
- | + | ||
- | + | ||
- | Baud 300, 7E1 | + | |
- | + | ||
- | Dieser z.B. von Stedin verbaute Zähler verhält sich qua Ansprache wie der E350 ([[hardware: | + | |
- | < | + | |
- | --> "/? | + | |
- | / | + | |
- | --> chr(0x06).chr(0x30).chr(0x30).chr(0x30).chr(0x0D).chr(0x0A) | + | |
- | 0.00.6.0(K86T0000) | + | |
- | 0.00.6.1(21497110) | + | |
- | 2.18.1(000000.00) | + | |
- | 2.18.2(008278.78) | + | |
- | 2.18.0(008278.78) | + | |
- | 3.28.1(000000.00) | + | |
- | 3.28.2(000000.00) | + | |
- | 3.28.0(000000.00) | + | |
- | </ | + | |
- | + | ||
- | Zum Auslesen dient eine (quick and dirty) modifizierte Version des Perl-Scripts von [[hardware: | + | |
- | Der E110 benötigt etwas mehr Zeit zum Lesen als der DRS155 (read_char_time =3, read_const_time = 10) und sendet 165 chars zurück ($port-> | + | |
- | + | ||
- | < | + | |
- | #!/ | + | |
- | + | ||
- | # teile von http:// | + | |
- | # 20130802 : ollir | + | |
- | # vereinfachte Version von http:// | + | |
- | + | ||
- | use Device:: | + | |
- | + | ||
- | + | ||
- | my $port = Device:: | + | |
- | $port-> | + | |
- | $port-> | + | |
- | $port-> | + | |
- | $port-> | + | |
- | $port-> | + | |
- | $port-> | + | |
- | + | ||
- | $port-> | + | |
- | $port-> | + | |
- | $port-> | + | |
- | + | ||
- | my $verbose = 11 ; | + | |
- | + | ||
- | # ======================================== | + | |
- | sub sendgetserial { | + | |
- | my ($cmd) = @_; | + | |
- | my $count; | + | |
- | my $saw; | + | |
- | my $sawprint; | + | |
- | my $x; | + | |
- | + | ||
- | $port-> | + | |
- | $port-> | + | |
- | + | ||
- | ($count, | + | |
- | $x=uc(unpack(' | + | |
- | $sawprint = $saw; | + | |
- | + | ||
- | $cmd =~ s/ | + | |
- | $cmd =~ s/ | + | |
- | + | ||
- | $saw =~ s/ | + | |
- | $saw =~ s/ | + | |
- | + | ||
- | if ( $verbose> | + | |
- | printf "+++ sendserial\n" | + | |
- | print " CMD: $cmd \n"; | + | |
- | print " COUNT: $count \n"; | + | |
- | print " HEX: $x \n"; | + | |
- | print " ASCII: | + | |
- | printf "--- sendserial\n" | + | |
- | } | + | |
- | + | ||
- | return $saw; | + | |
- | } | + | |
- | # ======================================== | + | |
- | + | ||
- | ## Variablen | + | |
- | my $cmd; | + | |
- | my $res; | + | |
- | my $counter; | + | |
- | + | ||
- | # Initialisierung | + | |
- | sendgetserial("/? | + | |
- | + | ||
- | # Zählerabfrage | + | |
- | $cmd = chr(0x06).chr(0x30).chr(0x30).chr(0x30).chr(0x0D).chr(0x0A); | + | |
- | $_ = sendgetserial($cmd); | + | |
- | + | ||
- | s/ | + | |
- | + | ||
- | print $1; | + | |
- | </code> | + |
hardware/channels/meters/power/edl-ehz/e110.1420042146.txt.gz · Zuletzt geändert: 2014/12/31 17:09 (Externe Bearbeitung)