Ankündigung

Einklappen
Keine Ankündigung bisher.

Stromzähler: Umrechnungen (Durchschnitt über historische Werte)

Einklappen
X
 
  • Filter
  • Zeit
  • Anzeigen
Alles löschen
neue Beiträge

    #16
    1) klappt
    2) wird gemacht.

    Danke!

    Aber hier brauche ich nochmal Hilfe:
    Code:
    [Allgemein]
        name = Allgemein
        [[Stromzaehler]]
            [[[Counter]]]
                name = Counter
                type = num
                sqlite = yes
                knx_dpt = 12
                knx_send = 6/7/0
                knx_listen = 6/7/0
            [[[Zaehlerstand]]]
                name = Zaehlerstand
                type = num
                sqlite = yes
                knx_dpt = 14
                knx_send = 6/7/1
                eval = sh.Allgemein.Stromzaehler.Counter()/800.0
                eval_trigger = Allgemein.Stromzaehler.Counter
            [[[Momentanleistung_1min]]]
                name = Momentanleistung_1min
                type = num
                sqlite = yes
                knx_dpt = 14
                knx_send = 6/7/2
    #           eval = sh.Allgemein.Stromzaehler.Zaehlerstand()
                eval = sh.Allgemein.Stromzaehler.Zaehlerstand.db('avg', '2i', '1i')
    Die letzte Zeile mag er nicht.
    Das Sqlite Plugin scheint aber aktiv:
    Code:
    2013-07-12 17:27:16,488 SmartHome.py DEBUG    sqlite next time: 2013-07-13 03:02:00+02:00 -- scheduler.py:_next_time:238
    Dennoch gibt es einen Parse-Error in der letzten Zeile.

    Gruß,
    Hendrik

    Kommentar


      #17
      Hallo,

      so, wie versprochen habe ich mich mit Python beschäftigt (hatte ich vorher bereits, aber nur lesend, nicht schreibend).

      Aber dennoch weiß ich noch nicht, warum oben stehendes nicht funktioniert.
      Hat jemand mal ein funktionierendes Beispiel, oder kann nochmal über meine Konfiguration sehen?

      Gruß,
      Hendrik

      Kommentar


        #18
        Hallo,

        Zitat von henfri Beitrag anzeigen
        Dennoch gibt es einen Parse-Error in der letzten Zeile.
        es könnte helfen den Parse-Error zu posten.

        Bis bald

        Marcus

        Kommentar


          #19
          Oh, wenn ich wüsste, wo Details dazu stehen, wäre ich sicher schon weiter!

          Ich gucke immer auf die Debug-Informationen (-d -n, wenn ich mich recht entsinne).

          Da war eben nix genaueres zu sehen.
          Sollte es? Oder gucke ich an der falschen Stelle?

          Gruß,
          Hendrik

          Kommentar


            #20
            mit -n passt das schon.
            Poste doch einfach den kompletten Output.

            Ich kann die Datenmengen schon verarbeiten.

            Bis bald

            Marcus

            Kommentar


              #21
              Hallo,

              hier erstmal die entsprechende Zeile:
              Code:
              2013-07-25 21:19:25,314 SmartHome.py WARNING  Problem reading allgemein.conf: Parse error in value at line 26. -- smarthome.py:__init__:216
              r
              Und unten noch der ganze Output.

              Vielen Dank für deine Hilfe!

              Gruß,
              Hendrik

              Code:
              root@HomeServer:/usr/local/smarthome# ./bin/smarthome.py -n -d > /var/log/sh_stdout.txt 2> /var/log/sh_stderr.txt &
              [1] 22798
              root@HomeServer:/usr/local/smarthome# grep parse /var/log/sh_stderr.txt
              2013-07-25 21:19:25,316 SmartHome.py DEBUG    knx: eg.wohnzimmer.light.level listen on 1/1/163 -- __init__.py:parse_item:230
              2013-07-25 21:19:25,316 SmartHome.py DEBUG    knx: Light listen on 1/1/160 -- __init__.py:parse_item:230
              2013-07-25 21:19:25,317 SmartHome.py DEBUG    knx: aussen.dach.sens_umwelt aussen temp nord ost listen on 6/5/1 -- __init__.py:parse_item:230
              2013-07-25 21:19:25,321 SmartHome.py DEBUG    knx: multimedia.zones listen on 9/1/55 -- __init__.py:parse_item:230
              2013-07-25 21:19:25,321 SmartHome.py DEBUG    knx: multimedia.zones listen on and init with 9/1/55 -- __init__.py:parse_item:239
              2013-07-25 21:19:25,322 SmartHome.py DEBUG    knx: multimedia.power listen on 9/1/0 -- __init__.py:parse_item:230
              2013-07-25 21:19:25,323 SmartHome.py DEBUG    knx: multimedia.TunerCDToggle listen on 9/1/1 -- __init__.py:parse_item:230
              2013-07-25 21:19:25,323 SmartHome.py DEBUG    knx: multimedia.MasterVolume_updown listen on 9/1/3 -- __init__.py:parse_item:230
              2013-07-25 21:19:25,323 SmartHome.py DEBUG    knx: multimedia.MasterMute listen on 9/1/4 -- __init__.py:parse_item:230
              2013-07-25 21:19:25,323 SmartHome.py DEBUG    knx: multimedia.ZoneAToggle listen on 9/1/5 -- __init__.py:parse_item:230
              2013-07-25 21:19:25,324 SmartHome.py DEBUG    knx: multimedia.ZoneBToggle listen on 9/1/6 -- __init__.py:parse_item:230
              2013-07-25 21:19:25,324 SmartHome.py DEBUG    knx: multimedia.ZoneCToggle listen on 9/1/7 -- __init__.py:parse_item:230
              2013-07-25 21:19:25,325 SmartHome.py DEBUG    knx: multimedia.ZoneDToggle listen on 9/1/8 -- __init__.py:parse_item:230
              2013-07-25 21:19:25,325 SmartHome.py DEBUG    knx: multimedia.TunerPresetUpDown listen on 9/1/10 -- __init__.py:parse_item:230
              2013-07-25 21:19:25,325 SmartHome.py DEBUG    knx: multimedia.Zone2Toggle listen on 9/1/12 -- __init__.py:parse_item:230
              2013-07-25 21:19:25,326 SmartHome.py DEBUG    knx: multimedia.Zone2VolUpDown listen on 9/1/13 -- __init__.py:parse_item:230
              2013-07-25 21:19:25,326 SmartHome.py DEBUG    knx: multimedia.Zone2MuteToggle listen on 9/1/14 -- __init__.py:parse_item:230
              2013-07-25 21:19:25,326 SmartHome.py DEBUG    knx: multimedia.Zone2InputToggle listen on 9/1/15 -- __init__.py:parse_item:230
              2013-07-25 21:19:25,331 SmartHome.py WARNING  knx: Ignoring Squeezebox.Name unknown dpt: 16.001 -- __init__.py:parse_item:220
              2013-07-25 21:19:25,332 SmartHome.py DEBUG    squeezebox: Squeezebox.Name receives updates by "00:04:20:27:a7:28 name" -- __init__.py:parse_item:63
              2013-07-25 21:19:25,332 SmartHome.py DEBUG    squeezebox: Squeezebox.Name is send to "00:04:20:27:a7:28 name {}" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,332 SmartHome.py DEBUG    squeezebox: Squeezebox.IP receives updates by "player ip 00:04:20:27:a7:28" -- __init__.py:parse_item:63
              2013-07-25 21:19:25,333 SmartHome.py DEBUG    squeezebox: Squeezebox.Signal_Strength receives updates by "00:04:20:27:a7:28 signalstrength" -- __init__.py:parse_item:63
              2013-07-25 21:19:25,333 SmartHome.py DEBUG    knx: Squeezebox.Power listen on and init with 9/2/1 -- __init__.py:parse_item:239
              2013-07-25 21:19:25,333 SmartHome.py DEBUG    squeezebox: Squeezebox.Power receives updates by "00:04:20:27:a7:28 prefset server power" -- __init__.py:parse_item:63
              2013-07-25 21:19:25,333 SmartHome.py DEBUG    squeezebox: Squeezebox.Power is initialized by "00:04:20:27:a7:28 power" -- __init__.py:parse_item:75
              2013-07-25 21:19:25,334 SmartHome.py DEBUG    squeezebox: Squeezebox.Power is send to "00:04:20:27:a7:28 power {}" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,334 SmartHome.py DEBUG    knx: Squeezebox.Mute listen on and init with 9/2/2 -- __init__.py:parse_item:239
              2013-07-25 21:19:25,334 SmartHome.py DEBUG    squeezebox: Squeezebox.Mute receives updates by "00:04:20:27:a7:28 prefset server mute" -- __init__.py:parse_item:63
              2013-07-25 21:19:25,334 SmartHome.py DEBUG    squeezebox: Squeezebox.Mute is initialized by "00:04:20:27:a7:28 mixer muting" -- __init__.py:parse_item:75
              2013-07-25 21:19:25,334 SmartHome.py DEBUG    squeezebox: Squeezebox.Mute is send to "00:04:20:27:a7:28 mixer muting {}" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,335 SmartHome.py DEBUG    squeezebox: Squeezebox.Volume receives updates by "00:04:20:27:a7:28 prefset server volume" -- __init__.py:parse_item:63
              2013-07-25 21:19:25,335 SmartHome.py DEBUG    squeezebox: Squeezebox.Volume is initialized by "00:04:20:27:a7:28 mixer volume" -- __init__.py:parse_item:75
              2013-07-25 21:19:25,335 SmartHome.py DEBUG    squeezebox: Squeezebox.Volume is send to "00:04:20:27:a7:28 mixer volume {}" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,336 SmartHome.py DEBUG    squeezebox: Squeezebox.Volume_Up is send to "00:04:20:27:a7:28 button volup" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,336 SmartHome.py DEBUG    squeezebox: Squeezebox.Volume_Down is send to "00:04:20:27:a7:28 button voldown" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,336 SmartHome.py DEBUG    knx: Squeezebox.Play listen on and init with 9/2/5 -- __init__.py:parse_item:239
              2013-07-25 21:19:25,336 SmartHome.py DEBUG    squeezebox: Squeezebox.Play receives updates by "00:04:20:27:a7:28 play" -- __init__.py:parse_item:63
              2013-07-25 21:19:25,337 SmartHome.py DEBUG    squeezebox: Squeezebox.Play is initialized by "00:04:20:27:a7:28 mode" -- __init__.py:parse_item:75
              2013-07-25 21:19:25,337 SmartHome.py DEBUG    squeezebox: Squeezebox.Play is send to "00:04:20:27:a7:28 play" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,337 SmartHome.py DEBUG    knx: Squeezebox.Stop listen on and init with 9/2/6 -- __init__.py:parse_item:239
              2013-07-25 21:19:25,337 SmartHome.py DEBUG    squeezebox: Squeezebox.Stop receives updates by "00:04:20:27:a7:28 stop" -- __init__.py:parse_item:63
              2013-07-25 21:19:25,337 SmartHome.py DEBUG    squeezebox: Squeezebox.Stop is initialized by "00:04:20:27:a7:28 mode" -- __init__.py:parse_item:75
              2013-07-25 21:19:25,337 SmartHome.py DEBUG    squeezebox: Squeezebox.Stop is send to "00:04:20:27:a7:28 stop" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,338 SmartHome.py DEBUG    knx: Squeezebox.Pause listen on and init with 9/2/7 -- __init__.py:parse_item:239
              2013-07-25 21:19:25,338 SmartHome.py DEBUG    squeezebox: Squeezebox.Pause receives updates by "00:04:20:27:a7:28 pause" -- __init__.py:parse_item:63
              2013-07-25 21:19:25,338 SmartHome.py DEBUG    squeezebox: Squeezebox.Pause is initialized by "00:04:20:27:a7:28 mode" -- __init__.py:parse_item:75
              2013-07-25 21:19:25,338 SmartHome.py DEBUG    squeezebox: Squeezebox.Pause is send to "00:04:20:27:a7:28 pause {}" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,339 SmartHome.py WARNING  knx: Ignoring Squeezebox.Current_Title unknown dpt: 16.001 -- __init__.py:parse_item:220
              2013-07-25 21:19:25,339 SmartHome.py DEBUG    squeezebox: Squeezebox.Current_Title receives updates by "00:04:20:27:a7:28 playlist newsong" -- __init__.py:parse_item:63
              2013-07-25 21:19:25,339 SmartHome.py DEBUG    squeezebox: Squeezebox.Current_Title is initialized by "00:04:20:27:a7:28 current_title" -- __init__.py:parse_item:75
              2013-07-25 21:19:25,339 SmartHome.py DEBUG    squeezebox: Squeezebox.Genre receives updates by "00:04:20:27:a7:28 genre" -- __init__.py:parse_item:63
              2013-07-25 21:19:25,340 SmartHome.py DEBUG    squeezebox: Squeezebox.Artist receives updates by "00:04:20:27:a7:28 artist" -- __init__.py:parse_item:63
              2013-07-25 21:19:25,340 SmartHome.py DEBUG    squeezebox: Squeezebox.Album receives updates by "00:04:20:27:a7:28 album" -- __init__.py:parse_item:63
              2013-07-25 21:19:25,341 SmartHome.py DEBUG    squeezebox: Squeezebox.Title receives updates by "00:04:20:27:a7:28 title" -- __init__.py:parse_item:63
              2013-07-25 21:19:25,341 SmartHome.py DEBUG    squeezebox: Squeezebox.Duration receives updates by "00:04:20:27:a7:28 duration" -- __init__.py:parse_item:63
              2013-07-25 21:19:25,341 SmartHome.py DEBUG    squeezebox: Squeezebox.Time receives updates by "00:04:20:27:a7:28 time" -- __init__.py:parse_item:63
              2013-07-25 21:19:25,341 SmartHome.py DEBUG    squeezebox: Squeezebox.Time is send to "00:04:20:27:a7:28 time {}" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,342 SmartHome.py DEBUG    squeezebox: Squeezebox.Playlist_Index receives updates by "00:04:20:27:a7:28 playlist index" -- __init__.py:parse_item:63
              2013-07-25 21:19:25,342 SmartHome.py DEBUG    squeezebox: Squeezebox.Playlist_Index is send to "00:04:20:27:a7:28 playlist index {}" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,342 SmartHome.py DEBUG    squeezebox: Squeezebox.Playlist_Forward is send to "00:04:20:27:a7:28 playlist index +1" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,342 SmartHome.py DEBUG    squeezebox: Squeezebox.Playlist_Backward is send to "00:04:20:27:a7:28 playlist index -1" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,343 SmartHome.py DEBUG    squeezebox: Squeezebox.Playlist_Name receives updates by "00:04:20:27:a7:28 playlist name" -- __init__.py:parse_item:63
              2013-07-25 21:19:25,343 SmartHome.py DEBUG    squeezebox: Squeezebox.Playlist_Name is send to "00:04:20:27:a7:28 playlist name {}" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,343 SmartHome.py DEBUG    squeezebox: Squeezebox.Playlist_Save is send to "00:04:20:27:a7:28 playlist save {}" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,344 SmartHome.py DEBUG    squeezebox: Squeezebox.Playlist_Load is send to "00:04:20:27:a7:28 playlist load {}" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,344 SmartHome.py DEBUG    squeezebox: Squeezebox.Playlist_Load_Internetradio is send to "00:04:20:27:a7:28 playlist load file:///home/robert/playlists/Internetradio.m3u" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,344 SmartHome.py DEBUG    squeezebox: Squeezebox.Repeat receives updates by "00:04:20:27:a7:28 playlist repeat" -- __init__.py:parse_item:63
              2013-07-25 21:19:25,344 SmartHome.py DEBUG    squeezebox: Squeezebox.Repeat is send to "00:04:20:27:a7:28 playlist repeat {}" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,345 SmartHome.py DEBUG    squeezebox: Squeezebox.Repeat_Song is send to "00:04:20:27:a7:28 playlist repeat 1" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,345 SmartHome.py DEBUG    squeezebox: Squeezebox.Repeat_Playlist is send to "00:04:20:27:a7:28 playlist repeat 2" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,345 SmartHome.py DEBUG    squeezebox: Squeezebox.Repeat_None is send to "00:04:20:27:a7:28 playlist repeat 0" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,346 SmartHome.py DEBUG    squeezebox: Squeezebox.Shuffle receives updates by "00:04:20:27:a7:28 playlist shuffle" -- __init__.py:parse_item:63
              2013-07-25 21:19:25,346 SmartHome.py DEBUG    squeezebox: Squeezebox.Shuffle is send to "00:04:20:27:a7:28 playlist shuffle {}" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,346 SmartHome.py DEBUG    squeezebox: Squeezebox.Shuffle_By_Song is send to "00:04:20:27:a7:28 playlist shuffle 1" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,346 SmartHome.py DEBUG    squeezebox: Squeezebox.Shuffle_By_Album is send to "00:04:20:27:a7:28 playlist shuffle 2" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,347 SmartHome.py DEBUG    squeezebox: Squeezebox.Shuffle_None is send to "00:04:20:27:a7:28 playlist shuffle 0" -- __init__.py:parse_item:90
              2013-07-25 21:19:25,356 SmartHome.py DEBUG    knx: <lib.logic.Logic instance at 0x2366320> listen on 9/1/0 -- __init__.py:parse_logic:289
              2013-07-25 21:19:25,356 SmartHome.py DEBUG    knx: <lib.logic.Logic instance at 0x2366320> listen on 9/1/1 -- __init__.py:parse_logic:289
              2013-07-25 21:19:25,356 SmartHome.py DEBUG    knx: <lib.logic.Logic instance at 0x2366320> listen on 9/1/3 -- __init__.py:parse_logic:289
              2013-07-25 21:19:25,356 SmartHome.py DEBUG    knx: <lib.logic.Logic instance at 0x2366320> listen on 9/1/4 -- __init__.py:parse_logic:289
              2013-07-25 21:19:25,357 SmartHome.py DEBUG    knx: <lib.logic.Logic instance at 0x2366320> listen on 9/1/5 -- __init__.py:parse_logic:289
              2013-07-25 21:19:25,357 SmartHome.py DEBUG    knx: <lib.logic.Logic instance at 0x2366320> listen on 9/1/6 -- __init__.py:parse_logic:289
              2013-07-25 21:19:25,357 SmartHome.py DEBUG    knx: <lib.logic.Logic instance at 0x2366320> listen on 9/1/7 -- __init__.py:parse_logic:289
              2013-07-25 21:19:25,357 SmartHome.py DEBUG    knx: <lib.logic.Logic instance at 0x2366320> listen on 9/1/8 -- __init__.py:parse_logic:289
              2013-07-25 21:19:25,357 SmartHome.py DEBUG    knx: <lib.logic.Logic instance at 0x2366320> listen on 9/1/10 -- __init__.py:parse_logic:289
              2013-07-25 21:19:25,357 SmartHome.py DEBUG    knx: <lib.logic.Logic instance at 0x2366320> listen on 9/1/12 -- __init__.py:parse_logic:289
              2013-07-25 21:19:25,357 SmartHome.py DEBUG    knx: <lib.logic.Logic instance at 0x2366320> listen on 9/1/13 -- __init__.py:parse_logic:289
              2013-07-25 21:19:25,358 SmartHome.py DEBUG    knx: <lib.logic.Logic instance at 0x2366320> listen on 9/1/14 -- __init__.py:parse_logic:289
              2013-07-25 21:19:25,358 SmartHome.py DEBUG    knx: <lib.logic.Logic instance at 0x2366320> listen on 9/1/15 -- __init__.py:parse_logic:289
              2013-07-25 21:19:26,359 SmartHome.py DEBUG    0.0.0 read 9/1/55 -- __init__.py:parse_telegram:198
              2013-07-25 21:19:26,359 SmartHome.py DEBUG    0.0.0 read 9/2/1 -- __init__.py:parse_telegram:198
              2013-07-25 21:19:26,360 SmartHome.py DEBUG    0.0.0 read 9/2/2 -- __init__.py:parse_telegram:198
              2013-07-25 21:19:26,360 SmartHome.py DEBUG    0.0.0 read 9/2/5 -- __init__.py:parse_telegram:198
              2013-07-25 21:19:26,360 SmartHome.py DEBUG    0.0.0 read 9/2/6 -- __init__.py:parse_telegram:198
              2013-07-25 21:19:26,360 SmartHome.py DEBUG    0.0.0 read 9/2/7 -- __init__.py:parse_telegram:198
              2013-07-25 21:19:26,360 SmartHome.py DEBUG    knx: 1.0.35 set 9/1/55 to 0 -- __init__.py:parse_telegram:185
              2013-07-25 21:19:26,405 SmartHome.py DEBUG    knx: 0.0.0 set 9/1/56 to 0 -- __init__.py:parse_telegram:180
              2013-07-25 21:19:26,408 SmartHome.py DEBUG    knx: 0.0.0 set 9/1/57 to 0 -- __init__.py:parse_telegram:180
              2013-07-25 21:19:26,408 SmartHome.py DEBUG    knx: 0.0.0 set 9/1/58 to 0 -- __init__.py:parse_telegram:180
              2013-07-25 21:19:26,409 SmartHome.py DEBUG    knx: 0.0.0 set 9/1/59 to 0 -- __init__.py:parse_telegram:180
              2013-07-25 21:19:27,617 SmartHome.py DEBUG    knx: 1.0.22 set 1/1/119 to 29 -- __init__.py:parse_telegram:180
              2013-07-25 21:19:27,957 SmartHome.py DEBUG    knx: 1.0.49 set 1/1/123 to 29 -- __init__.py:parse_telegram:180
              2013-07-25 21:19:28,015 SmartHome.py DEBUG    knx: 1.0.49 set 1/1/64 to 29 -- __init__.py:parse_telegram:180
              2013-07-25 21:19:28,226 SmartHome.py DEBUG    knx: 1.0.5 set 6/7/0 to 0 1 23 26 -- __init__.py:parse_telegram:180
              2013-07-25 21:19:29,160 SmartHome.py DEBUG    knx: 0.0.0 set 8/2/20 to 0 -- __init__.py:parse_telegram:180
              2013-07-25 21:19:29,161 SmartHome.py DEBUG    knx: 0.0.0 set 8/2/21 to 0 -- __init__.py:parse_telegram:180
              2013-07-25 21:19:29,322 SmartHome.py DEBUG    knx: 1.0.17 set 6/5/11 to 0 0 -- __init__.py:parse_telegram:180
              2013-07-25 21:19:30,687 SmartHome.py DEBUG    knx: 0.0.0 set 8/2/20 to 1 -- __init__.py:parse_telegram:180
              2013-07-25 21:19:30,687 SmartHome.py DEBUG    knx: 0.0.0 set 8/2/21 to 1 -- __init__.py:parse_telegram:180
              2013-07-25 21:19:32,515 SmartHome.py DEBUG    knx: 1.0.38 set 6/2/0 to d 37 -- __init__.py:parse_telegram:180
              2013-07-25 21:19:32,889 SmartHome.py DEBUG    knx: 0.0.0 set 8/2/20 to 0 -- __init__.py:parse_telegram:180
              2013-07-25 21:19:32,891 SmartHome.py DEBUG    knx: 0.0.0 set 8/2/21 to 0 -- __init__.py:parse_telegram:180
              2013-07-25 21:19:34,435 SmartHome.py DEBUG    knx: 1.0.5 set 6/7/0 to 0 1 23 27 -- __init__.py:parse_telegram:180
              2013-07-25 21:19:35,211 SmartHome.py DEBUG    knx: 1.0.37 set 6/2/15 to c dd -- __init__.py:parse_telegram:180
              2013-07-25 21:19:35,305 SmartHome.py DEBUG    knx: 1.0.17 set 6/5/12 to 2f 5c -- __init__.py:parse_telegram:180

              Kommentar


                #22
                Hi Hendrik,

                probier mal

                Code:
                eval = "sh.Allgemein.Stromzaehler.Zaehlerstand.db('avg', '2i', '1i')"
                dann versucht der Config-Parser die Zeile nicht großartig zu interpretieren und nimmt sie als normalen String.

                Bis bald

                Marcus

                Kommentar


                  #23
                  Hallo Marcus,

                  ich komme jetzt erst dazu, sorry.
                  Es hat schonmal geholfen, es gibt keine Fehlermeldung mehr beim Start.

                  Aber es funktioniert dennoch leider noch nicht:
                  Code:
                          [[[Momentanleistung_1min]]]
                              name = Momentanleistung_1min
                              type = num
                              sqlite = yes
                              knx_dpt = 14
                              knx_send = 6/7/2
                              eval = "sh.Allgemein.Stromzaehler.Zaehlerstand()- sh.Allgemein.Stromzaehler.Zaehlerstand.db('avg', '2i', '1i')"
                              eval_trigger=Allgemein.Stromzaehler.Counter
                  Code:
                  2013-07-31 22:52:22,239 SmartHome.py DEBUG    Triggering Allgemein.Stromzaehler.Zaehlerstand - by: Init source: None dest: None value: None -- scheduler.py:trigger:117
                  2013-07-31 22:52:22,240 SmartHome.py DEBUG    Triggering Allgemein.Stromzaehler.Momentanleistung_1min - by: Init source: None dest: None value: None -- scheduler.py:trigger:117
                  2013-07-31 22:52:22,249 Allgemein.Stromzaehler.Momentanleistung_1min WARNING  Method Allgemein.Stromzaehler.Momentanleistung_1min exception: near "<": syntax error -- scheduler.py:_task:295
                  2013-07-31 22:52:27,426 SmartHome.py DEBUG    Allgemein.Stromzaehler.Counter = 3794 via KNX 1.0.5 -- item.py:_update:219
                  Was kann das "near "<"" bedeuten?

                  Gruß,
                  Hendrik

                  Kommentar


                    #24
                    Hallo Hendrik,

                    hast Du Dein Thema bereits gelöst (ist so nicht markiert). Ich bin im Moment ebenfalls dran, die Zähler darzustellen und würde mich gerne an Deine Lösung anhängen.

                    Grüße Michel

                    Kommentar


                      #25
                      Ja, prinzipiell funktioniert es.

                      Gruß,
                      Hendrik

                      Kommentar


                        #26
                        Danke, dann probiere ich es aus !

                        Michel

                        Kommentar


                          #27
                          Hi Hendrik,

                          wie sieht denn deine funktionierende Konfig aus.

                          Ich mach jetzt schon mehrere Tage damit rum und habe verschiedene Beispiele ausprobiert, bekomme es aber nicht zum laufen.

                          Letzter Stand :eval = "sh.Zaehler.Wasser.Zaehlerstand2.db('max', '1d')"

                          Was brauch ich genau in der eval Zeile, und was bedeutet .db an dem Itemname.

                          Will eigentlich auch nur Stunden Tages Wochen und Monatsverbrauch errechnen.

                          Danke

                          ip_freak

                          Kommentar


                            #28
                            Hallo ip_freak,

                            nach dem Thread habe ich folgende Konfig, die für mich läuft :

                            Code:
                            [zaehler]
                                name = Zähler
                                sv_page = room
                                sv_img = measure_power_meter.png
                            
                                [[strom]]
                                    [[[counter]]]
                                        name = Counter
                                        type = num
                                        sqlite = yes
                                        knx_dpt = 12
                                        knx_cache = 9/0/0
                            
                                   [[[v_10m]]]
                                        name = Stromverbrauch Mittelung auf 10 Minuten
                                        type = num
                                        sqlite = yes
                                        eval = (sh.zaehler.strom.counter.db('max','10i') - sh.zaehler.strom.counter.db('min','10i')) * 6.0 / 250.0 
                                        eval_trigger = zaehler.strom.counter
                            
                                   [[[v_1h]]]
                                        name = Stromverbrauch Mittelung auf 1 Stunde
                                        type = num
                                        sqlite = yes
                                        eval = (sh.zaehler.strom.counter.db('max','1h') - sh.zaehler.strom.counter.db('min','1h')) / 250.0
                                        eval_trigger = zaehler.strom.counter
                                        
                                [[vis01]]
                                    name = Zählerstand Strom
                                    type = bool
                                    sv_widget = {{ basic.value('item-1', 'zaehler.strom.counter') }}
                                        
                                [[vis02]]
                                    name = Mittelwert Verbrauch
                                    type = bool
                                    sv_widget = {{ plot.period('item-1',['zaehler.strom.v_10m','zaehler.strom.v_1h'],'avg','24h',0,'','','',['10m','1h'],'',['area','area'],['',''],'1h')}}
                            Um die Verwirrung nicht komplett zu machen: Ich gehe im Moment davon aus, dass ein Zähler kontinuierlich hochläuft. Damit habe ich in einem Intervall mit den Min Funktion den Anfangswert der Intervalls, mit der Max Funktion den Endwert. Vom Prinzip kannst Du das auch machen, wie von henfri beschrieben mit avg der Intervalls minus dem avg der vorhergehenden, Du hast halt 1 Intervall Verzögerung in der Anzeige drin.

                            Grüsse

                            Michel

                            Kommentar


                              #29
                              Prinzipiell funktioniert das genau so bei mir. Allerdings habe ich dadurch das Problem, dass der Verbrauch dann nicht korrekt angezeigt wird, wenn nichts verbraucht wird.
                              Beispiel Gasverbrauch: Über Nacht fährt die Heizung auf Nachtabsenkung und es wird über Stunden kein Gas verbraucht. Die Visu liefert aber anstatt eines Nullwertes einfach den letzten Wert weiter (siehe Bild).

                              Items dazu sehen so aus:

                              [[gas]]
                              [[[gasimpuls]]]
                              name = gasimpuls
                              type = bool
                              knx_dpt = 1
                              knx_listen = 1/2/10

                              [[[gascounter]]]
                              name = gascounter
                              type = num
                              sqlite = yes
                              eval = (sh.zaehler.gas.gascounter()) + 1
                              eval_trigger = zaehler.gas.gasimpuls

                              [[[gascounter2]]]
                              name = gascounter2
                              type = num
                              sqlite = yes
                              eval = (sh.zaehler.gas.gascounter())
                              eval_trigger = zaehler.gas.gascounter

                              [[[gascounter24]]]
                              name = gascounter24
                              type = num
                              eval = (sh.zaehler.gas.gascounter2.db('max','1i') - sh.zaehler.gas.gascounter2.db('min','1d'))
                              eval_trigger = zaehler.gas.gascounter2

                              [[[gasv24]]]
                              name = Gasverbrauch der letzten 24 Stunden
                              type = num
                              sqlite = yes
                              eval = round ((sh.zaehler.gas.gascounter2.db('max','1i') - sh.zaehler.gas.gascounter2.db('min','1d')) * 0.9402 , 2)
                              eval_trigger = zaehler.gas.gascounter2
                              [[[gaspreis24]]]
                              name = Gaskosten der letzten 24 Stunden
                              type = num
                              sqlite = yes
                              eval = round ((sh.zaehler.gas.gasv24()) * 0.068425 , 2)
                              eval_trigger = zaehler.gas.gascounter2


                              [[[vg_1m]]]
                              name = gasverbrauch Mittelung auf 1 Minuten
                              type = num
                              sqlite = yes
                              eval = (sh.zaehler.gas.gascounter2.db('max','1i') - sh.zaehler.gas.gascounter2.db('min','1i')) * 60.0 * 0.9402
                              eval_trigger = zaehler.gas.gascounter2


                              [[[vg_10m]]]
                              name = gasverbrauch Mittelung auf 10 Minuten
                              type = num
                              sqlite = yes
                              eval = (sh.zaehler.gas.gascounter2.db('max','10i') - sh.zaehler.gas.gascounter2.db('min','10i')) * 6.0 * 0.9402
                              eval_trigger = zaehler.gas.gascounter2

                              [[[vg_1h]]]
                              name = gasverbrauch Mittelung auf 1 Stunde
                              type = num
                              sqlite = yes
                              eval = (sh.zaehler.gas.gascounter2.db('max','1h') - sh.zaehler.gas.gascounter2.db('min','1h')) * 0.9402
                              eval_trigger = zaehler.gas.gascounter2

                              [[visg01]]
                              name = Zaehlerstand gas
                              type = bool
                              sv_widget = {{ basic.value('item-1', 'zaehler.gas.gascounter2') }}

                              [[visg02]]
                              name = Mittelwert Verbrauch
                              type = bool
                              sv_widget = {{ plot.period('item-1',['zaehler.gas.vg_10m','zaehler.gas.vg_1h'],'avg','24h',0,'','','',['10m','1h'],'',['area','area'],['',''],'1h')}}

                              [[visg03]]
                              name = Mittelwert Verbrauch 1m,10m,60m
                              type = bool
                              sv_widget = {{ plot.period('item-1',['zaehler.gas.vg_1m','zaehler.gas.vg_10m','zaehler. gas.vg_1h'],'avg','24h',0,'','','',['1m','10m','1h'],'',['area','area','area'],['','',''],'1h')}}

                              Eine andere Auswertung des gleichen Zeitpunktes mit Misterhouse und RRD sieht dagegen so aus (siehe anderes Bild).

                              Wie bekomme ich also den Wert in der Visu auf 0?

                              Viele Grüße

                              Andi
                              Angehängte Dateien

                              Kommentar


                                #30
                                Das fehlt dir bei einem der ersten Items irgendwo ein "enforce_updates = yes", so dass auch "0" dauernd geschrieben wird oder?
                                Dann sollte irgendwann ja 0-0=0 dastehen.
                                Derzeit zwischen Kistenauspacken und Garten anlegen.
                                Baublog im Profil.

                                Kommentar

                                Lädt...
                                X