Ankündigung

Einklappen
Keine Ankündigung bisher.

Trockenübungen mit smarthome.py und smartvisu

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

    #16
    Hi,

    ach ja, falls das Log zu lange ist, kann man es auch einfach als Datei anhängen.

    Bis bald

    Marcus

    Kommentar


      #17
      Zitat von mknx Beitrag anzeigen
      Hi Marc,

      verwendest Du den immer noch den Offline-Treiber?

      Bis bald

      Marcus
      ja, ist immer noch der offline treiber
      gruss marc

      Kommentar


        #18
        oh.

        Der offline-Treiber ist dafür ohne eine Verbindung mit einem Backend zu arbeiten!

        Da muss schon der SH.py-Treiber ausgewählt sein...

        Bis bald

        Marcus

        Kommentar


          #19
          Ah, ok...
          Jetzt gibts im Log auch Hinweise auf den "Testraum". Aber es scheint dennoch ein Fehler drin zu sein...
          Code:
          root@smarthome:/usr/smarthome# /usr/smarthome/bin/smarthome.py -d
          2014-02-01 12:13:52,919 INFO     Main         Start SmartHome.py 1.0-23-g43fa9aa -- smarthome.py:__init__:231
          2014-02-01 12:13:52,924 DEBUG    Main         Python 3.2.3 -- smarthome.py:__init__:232
          2014-02-01 12:13:52,931 INFO     Main         Init Scheduler -- scheduler.py:__init__:86
          2014-02-01 12:13:52,938 INFO     Main         Init Plugins -- smarthome.py:start:274
          2014-02-01 12:13:52,957 DEBUG    Scheduler    creating 5 workers -- scheduler.py:run:93
          2014-02-01 12:13:52,964 DEBUG    Main         Plugin: knx -- plugin.py:__init__:43
          2014-02-01 12:13:52,987 DEBUG    Main         Plugin: visu -- plugin.py:__init__:43
          2014-02-01 12:13:53,084 DEBUG    Main         Plugin: cli -- plugin.py:__init__:43
          2014-02-01 12:13:53,097 DEBUG    Main         Plugin: sql -- plugin.py:__init__:43
          2014-02-01 12:13:53,129 DEBUG    Main         SQLite 3.7.13 -- __init__.py:__init__:62
          2014-02-01 12:13:53,610 DEBUG    Main         SQLite: database integrity ok -- __init__.py:__init__:78
          2014-02-01 12:13:53,638 DEBUG    Main         SQLite pack next time: 2014-02-02 03:02:00+01:00 -- scheduler.py:_next_time:289
          2014-02-01 12:13:53,644 DEBUG    Main         Plugin: ow -- plugin.py:__init__:43
          2014-02-01 12:13:53,661 DEBUG    Main         Plugin: whatsapp -- plugin.py:__init__:43
          2014-02-01 12:13:55,269 INFO     Main         Init Items -- smarthome.py:start:280
          2014-02-01 12:13:55,285 INFO     Thread-8     Authed 4917617898128 -- ListenerClient.py:onAuthSuccess:67
          2014-02-01 12:13:55,473 DEBUG    Main         Item env.core.memory = 14912531.9001211 via SQLite None None -- item.py:set:457
          2014-02-01 12:13:55,601 DEBUG    Main         Item env.core.threads = 8.0 via SQLite None None -- item.py:set:457
          2014-02-01 12:13:55,728 DEBUG    Main         Item env.core.garbage = 0.0 via SQLite None None -- item.py:set:457
          2014-02-01 12:13:55,734 DEBUG    Main         Item env.core: no type specified. -- item.py:__init__:242
          2014-02-01 12:13:55,780 DEBUG    Main         Item env.location: no type specified. -- item.py:__init__:242
          2014-02-01 12:13:55,903 DEBUG    Main         Item env.system.load = 0.0985609405271899 via SQLite None None -- item.py:set:457
          2014-02-01 12:13:55,915 DEBUG    Main         Item env.system: no type specified. -- item.py:__init__:242
          2014-02-01 12:13:55,919 DEBUG    Main         Item env: no type specified. -- item.py:__init__:242
          2014-02-01 12:13:55,942 DEBUG    Main         Item Test.Testraum: no type specified. -- item.py:__init__:242
          2014-02-01 12:13:55,947 DEBUG    Main         Item Test: no type specified. -- item.py:__init__:242
          2014-02-01 12:13:55,955 INFO     Main         Start Plugins -- plugin.py:start:65
          2014-02-01 12:13:56,036 DEBUG    ow           1w-disc next time: 2014-02-01 12:13:58+01:00 -- scheduler.py:_next_time:289
          2014-02-01 12:13:56,044 INFO     Main         Start Logics -- logic.py:__init__:33
          2014-02-01 12:13:56,054 DEBUG    Main         Reading Logics from /usr/smarthome/lib/env/logic_conf -- logic.py:_read_logics:64
          2014-02-01 12:13:56,095 DEBUG    Connections  KNX: connected to 127.0.0.1:6720 -- connection.py:connect:391
          2014-02-01 12:13:56,101 DEBUG    Connections  KNX: enable group monitor -- __init__.py:handle_connect:117
          2014-02-01 12:13:56,104 DEBUG    Main         Reading Logics from /usr/smarthome/etc/logic.conf -- logic.py:_read_logics:64
          2014-02-01 12:13:56,116 DEBUG    Connections  WebSocket: binding to 0.0.0.0:2424 (TCP) -- connection.py:connect:161
          2014-02-01 12:13:56,130 DEBUG    Connections  CLI: binding to 0.0.0.0:2323 (TCP) -- connection.py:connect:161
          2014-02-01 12:13:56,133 DEBUG    Main         Logic: dummy -- logic.py:__init__:44
          2014-02-01 12:13:56,149 DEBUG    Main         dummy next time: 2014-02-01 12:14:07+01:00 -- scheduler.py:_next_time:289
          2014-02-01 12:13:56,152 INFO     Connections  1-Wire: connected to 127.0.0.1:4304 -- __init__.py:connect:66
          2014-02-01 12:13:56,158 DEBUG    Main         Logic: env_stat -- logic.py:__init__:44
          2014-02-01 12:13:56,178 DEBUG    Main         env_stat next time: 2014-02-01 12:14:07+01:00 -- scheduler.py:_next_time:289
          2014-02-01 12:13:56,183 DEBUG    Main         Logic: Test -- logic.py:__init__:44
          2014-02-01 12:13:56,192 DEBUG    Main         Logic: Whatsapp -- logic.py:__init__:44
          2014-02-01 12:13:56,201 DEBUG    Main         Logic: hello -- logic.py:__init__:44
          2014-02-01 12:13:56,210 DEBUG    Main         Logic: env_init -- logic.py:__init__:44
          2014-02-01 12:13:56,222 DEBUG    Main         Logic: env_loc -- logic.py:__init__:44
          2014-02-01 12:13:57,253 DEBUG    Main         knx: 1.1.54 set 5/1/130 to 00 -- __init__.py:parse_telegram:181
          2014-02-01 12:13:58,303 DEBUG    Main         knx: 1.1.54 set 5/1/130 to 01 -- __init__.py:parse_telegram:181
          2014-02-01 12:13:58,598 DEBUG    Scheduler    1w-disc next time: 2014-02-01 12:23:58+01:00 -- scheduler.py:_next_time:289
          2014-02-01 12:13:59,663 INFO     1w-disc      1-Wire: 28.7007E0020000 with sensors: T11, T10, T, T12, T9 -- __init__.py:_discovery:431
          2014-02-01 12:13:59,671 INFO     1w-disc      1-Wire: 28.8408E0020000 with sensors: T11, T10, T, T12, T9 -- __init__.py:_discovery:431
          2014-02-01 12:13:59,678 INFO     1w-disc      1-Wire: 28.7448E0020000 with sensors: T11, T10, T, T12, T9 -- __init__.py:_discovery:431
          2014-02-01 12:13:59,685 INFO     1w-disc      1-Wire: 28.F40CE0020000 with sensors: T11, T10, T, T12, T9 -- __init__.py:_discovery:431
          2014-02-01 12:13:59,693 INFO     1w-disc      1-Wire: 28.0C4CE0020000 with sensors: T11, T10, T, T12, T9 -- __init__.py:_discovery:431
          2014-02-01 12:13:59,700 INFO     1w-disc      1-Wire: 28.A24BE0020000 with sensors: T11, T10, T, T12, T9 -- __init__.py:_discovery:431
          2014-02-01 12:13:59,707 INFO     1w-disc      1-Wire: 28.A629E0020000 with sensors: T11, T10, T, T12, T9 -- __init__.py:_discovery:431
          2014-02-01 12:13:59,714 INFO     1w-disc      1-Wire: 28.B1B11B030000 with sensors: T11, T10, T, T12, T9 -- __init__.py:_discovery:431
          2014-02-01 12:13:59,721 INFO     1w-disc      1-Wire: 28.C548E0020000 with sensors: T11, T10, T, T12, T9 -- __init__.py:_discovery:431
          2014-02-01 12:13:59,728 INFO     1w-disc      1-Wire: 28.7318E0020000 with sensors: T11, T10, T, T12, T9 -- __init__.py:_discovery:431
          2014-02-01 12:13:59,736 INFO     1w-disc      1-Wire: 28.F332E0020000 with sensors: T11, T10, T, T12, T9 -- __init__.py:_discovery:431
          2014-02-01 12:13:59,743 INFO     1w-disc      1-Wire: 28.1B4FE0020000 with sensors: T11, T10, T, T12, T9 -- __init__.py:_discovery:431
          2014-02-01 12:13:59,750 INFO     1w-disc      1-Wire: 28.F729E0020000 with sensors: T11, T10, T, T12, T9 -- __init__.py:_discovery:431
          2014-02-01 12:14:00,060 DEBUG    ow           1w-sen next time: 2014-02-01 12:14:00+01:00 -- scheduler.py:_next_time:289
          2014-02-01 12:14:00,110 DEBUG    1w-sen       1-Wire: sensor cycle takes 2.193450927734375e-05 seconds -- __init__.py:_sensor_cycle:399
          2014-02-01 12:14:00,617 DEBUG    Scheduler    1w-sen next time: 2014-02-01 12:24:00+01:00 -- scheduler.py:_next_time:289
          2014-02-01 12:14:00,705 DEBUG    Main         knx: 1.1.0 set 3/1/13 to 055f -- __init__.py:parse_telegram:181
          2014-02-01 12:14:01,243 DEBUG    Main         knx: 1.1.54 set 5/1/130 to 00 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:01,401 DEBUG    Main         knx: 1.1.57 set 5/1/120 to 00 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:01,706 DEBUG    env_loc      Item env.location.sunrise = 2014-02-02 07:55:01.202819+01:00 via Logic None None -- item.py:__update:363
          2014-02-01 12:14:01,710 DEBUG    sh.gc        Garbage collector: collected 0 objects. -- smarthome.py:_garbage_collection:498
          2014-02-01 12:14:01,713 DEBUG    env_init     Item env.core.version = 1.0-23-g43fa9aa via Logic None None -- item.py:__update:363
          2014-02-01 12:14:01,709 INFO     hello        Hello World! -- hello.py:<module>:3
          2014-02-01 12:14:01,744 DEBUG    env_init     Item env.core.start = 2014-02-01 12:14:01.741120+01:00 via Logic None None -- item.py:__update:363
          2014-02-01 12:14:01,774 DEBUG    env_loc      Item env.location.sunset = 2014-02-01 17:22:37.109064+01:00 via Logic None None -- item.py:__update:363
          2014-02-01 12:14:01,793 DEBUG    env_init     Item env.system.name = smarthome.local via Logic None None -- item.py:__update:363
          2014-02-01 12:14:01,834 DEBUG    env_init     Item env.system.start = 2014-01-20 17:03:08.830243+01:00 via Logic None None -- item.py:__update:363
          2014-02-01 12:14:01,890 DEBUG    env_loc      Item env.location.moonrise = 2014-02-02 08:52:44.719338+01:00 via Logic None None -- item.py:__update:363
          2014-02-01 12:14:01,973 DEBUG    env_loc      Item env.location.moonset = 2014-02-01 19:55:22.150435+01:00 via Logic None None -- item.py:__update:363
          2014-02-01 12:14:02,075 DEBUG    env_loc      Item env.location.day = True via Logic None None -- item.py:__update:363
          2014-02-01 12:14:02,113 DEBUG    sh.gc        Object references: 10518 -- smarthome.py:_maintenance:490
          2014-02-01 12:14:02,334 DEBUG    Scheduler    env_loc next time: 2014-02-01 12:44:02+01:00 -- scheduler.py:_next_time:289
          2014-02-01 12:14:02,356 DEBUG    Scheduler    sh.gc next time: 2014-02-02 02:04:00+01:00 -- scheduler.py:_next_time:289
          2014-02-01 12:14:02,494 DEBUG    Main         knx: 1.1.0 set 5/2/11 to 0c71 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:03,861 DEBUG    Main         knx: 1.1.57 set 5/1/120 to 01 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:04,992 DEBUG    Main         knx: 1.1.54 set 5/1/130 to 01 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:05,989 DEBUG    Main         knx: 1.1.57 set 5/1/120 to 00 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:06,681 DEBUG    Main         knx: 1.1.0 set 5/5/2 to 00 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:06,719 DEBUG    Main         knx: 1.1.0 set 5/5/1 to 00 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:07,242 DEBUG    Main         knx: 1.1.54 set 5/1/130 to 00 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:07,460 ERROR    dummy        Logic: dummy, File: /usr/smarthome/logics/dummy_series.py, Line: 2, Method: <module>, Exception: 'SmartHome' object has no attribute 'first' -- scheduler.py:_task:334
          Traceback (most recent call last):
            File "/usr/smarthome/lib/scheduler.py", line 327, in _task
              exec(obj.bytecode)
            File "/usr/smarthome/logics/dummy_series.py", line 2, in <module>
              sh.first.living.temperature(random.randint(20, 23))
          AttributeError: 'SmartHome' object has no attribute 'first'
          2014-02-01 12:14:07,470 DEBUG    env_stat     Item env.core.memory = 14934016 via Logic None None -- item.py:__update:363
          2014-02-01 12:14:07,490 DEBUG    env_stat     Item env.system.load = 0.11 via Logic None None -- item.py:__update:363
          2014-02-01 12:14:07,499 DEBUG    env_stat     Item env.location.moonlight = 4 via Logic None None -- item.py:__update:363
          2014-02-01 12:14:07,906 DEBUG    Scheduler    dummy next time: 2014-02-01 12:19:07+01:00 -- scheduler.py:_next_time:289
          2014-02-01 12:14:07,913 DEBUG    Scheduler    env_stat next time: 2014-02-01 12:19:07+01:00 -- scheduler.py:_next_time:289
          2014-02-01 12:14:08,293 DEBUG    Main         knx: 1.1.54 set 5/1/130 to 01 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:10,628 DEBUG    Main         knx: 1.1.0 set 3/1/18 to 0c71 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:11,855 DEBUG    Main         knx: 1.1.56 set 5/1/150 to 2697 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:12,709 DEBUG    Main         knx: 1.1.57 set 5/1/120 to 01 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:15,247 DEBUG    Main         knx: 1.1.44 set 5/1/105 to 01 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:17,261 DEBUG    Main         knx: 1.1.54 set 5/1/130 to 00 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:17,707 DEBUG    Main         knx: 1.1.44 set 5/1/105 to 00 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:18,757 DEBUG    Main         knx: 1.1.44 set 5/1/105 to 01 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:18,994 DEBUG    Main         knx: 1.1.0 set 3/1/44 to 0627 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:20,723 DEBUG    Main         knx: 1.1.31 set 5/2/35 to 07fa -- __init__.py:parse_telegram:181
          2014-02-01 12:14:21,127 DEBUG    Main         knx: 1.1.44 set 5/1/105 to 00 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:23,210 DEBUG    Main         knx: 1.1.57 set 5/1/120 to 00 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:24,326 DEBUG    Main         knx: 1.1.0 set 3/1/34 to 0f7e -- __init__.py:parse_telegram:181
          2014-02-01 12:14:24,394 DEBUG    Main         knx: 1.1.254 set 0/3/16 to 01 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:26,269 DEBUG    Main         knx: 1.1.57 set 5/1/120 to 01 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:28,512 DEBUG    Main         WebSocket: incoming connection from 192.168.0.20:61936 to 0.0.0.0:2424 -- connection.py:accept:188
          2014-02-01 12:14:29,230 DEBUG    Main         192.168.0.20:61936 sent '{"cmd":"proto","ver":3}' -- __init__.py:json_parse:270
          2014-02-01 12:14:29,240 DEBUG    Main         192.168.0.20:61936 sent '{"cmd":"monitor","items":["Test.Testraum.Schalter","Test.Testraum.Spots"]}' -- __init__.py:json_parse:270
          2014-02-01 12:14:32,079 DEBUG    Main         knx: 1.1.0 set 3/1/10 to 0eb0 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:32,689 DEBUG    Main         knx: 1.1.57 set 5/1/120 to 00 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:33,988 DEBUG    Main         knx: 1.1.31 set 5/2/35 to 0c0e -- __init__.py:parse_telegram:181
          2014-02-01 12:14:39,049 DEBUG    Main         knx: 1.1.31 set 5/2/35 to 07fe -- __init__.py:parse_telegram:181
          2014-02-01 12:14:39,081 DEBUG    Main         192.168.0.20:61936 sent '{"cmd":"item","id":"Test.Testraum.Schalter","val":"1"}' -- __init__.py:json_parse:270
          2014-02-01 12:14:39,087 DEBUG    Main         Item Test.Testraum.Schalter = True via Visu 192.168.0.20:61936 None -- item.py:__update:363
          2014-02-01 12:14:39,139 DEBUG    Main         knx: 1.1.57 set 5/1/120 to 01 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:40,272 DEBUG    Main         knx: 1.1.54 set 5/1/130 to 01 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:41,988 DEBUG    Main         knx: 1.1.0 set 3/1/12 to 052d -- __init__.py:parse_telegram:181
          2014-02-01 12:14:42,205 DEBUG    Main         192.168.0.20:61936 sent '{"cmd":"item","id":"Test.Testraum.Schalter","val":"0"}' -- __init__.py:json_parse:270
          2014-02-01 12:14:42,211 DEBUG    Main         Item Test.Testraum.Schalter = False via Visu 192.168.0.20:61936 None -- item.py:__update:363
          2014-02-01 12:14:43,098 DEBUG    Main         knx: 1.1.57 set 5/1/120 to 00 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:44,139 DEBUG    Main         knx: 1.1.0 set 3/1/14 to 0ce2 -- __init__.py:parse_telegram:181
          2014-02-01 12:14:44,161 DEBUG    Main         knx: 1.1.57 set 5/1/120 to 01 -- __init__.py:parse_telegram:181
          ^C2014-02-01 12:14:44,944 INFO     Main         Number of Threads: 8 -- smarthome.py:stop:348
          2014-02-01 12:14:44,949 INFO     Main         Stop Plugins -- plugin.py:stop:70
          2014-02-01 12:14:44,953 DEBUG    Main         WebSocketHandler: closing socket 192.168.0.20:61936 -- connection.py:close:308
          2014-02-01 12:14:45,161 DEBUG    Main         KNX: closing socket 127.0.0.1:6720 -- connection.py:close:308
          2014-02-01 12:14:46,169 INFO     Main         Thread: Thread-7, still alive -- smarthome.py:stop:370
          2014-02-01 12:14:46,174 INFO     Main         Thread: Main, still alive -- smarthome.py:stop:370

          Kommentar


            #20
            Zitat von marcjoerg Beitrag anzeigen
            Aber es scheint dennoch ein Fehler drin zu sein...
            Es ist echt mühselig...

            Aus https://knx-user-forum.de/smarthome-...rbehebung.html :

            Mit einer Problembeschreibung posten.
            • Was möchtest Du erreichen?
            • Was machst Du (genau)?
            • Was klappt nicht?


            Fragst Du Dich etwas wieso Deine Logik nicht getriggert wird? Wie sollte sie auch, du hast ja keine Abhängigkeit angegeben.
            Configuration ? SmartHome.py 1.0 documentation

            Bis bald

            Marcus

            Kommentar


              #21
              Hi Marcus,

              Danke für die Tipps.
              Problembeschreibung und Voraussetzungen hatte ich - wie es die "Forenrichtlinien" wünschen - in einem der vorherigen Posts aufgezeigt.

              Ich fuchse mich mal durch...
              Beste Grüße
              Marc

              Kommentar


                #22
                hi marcjoerg,

                du musst bei deiner Logic in der logic.conf dein watch_item eintragen, sonst wird sie nicht getriggert.

                lg rudi

                Kommentar


                  #23
                  Hi Rudi!
                  Danke, das wars!
                  Wenn ich es richtig verstehe, müssen in die logic.conf alle "hörenden" Adresse aufgelistet sein.
                  Viele Grüße
                  Marc

                  Kommentar


                    #24
                    Ja genau. Es muss angegeben werden wovon die Logic getriggert wird.
                    Entweder von einem watch_item, von cycle oder von crontab.

                    Steht aber alles genauer in der docu:
                    Configuration ? SmartHome.py 1.0 documentation

                    Und nicht aufgeben

                    LG rudi

                    Kommentar

                    Lädt...
                    X