Navigation

    Logo
    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unread
    • Categories
    • Unreplied
    • Popular
    • GitHub
    • Docu
    • Hilfe
    1. Home
    2. Deutsch
    3. ioBroker Allgemein
    4. Park-Ampel

    NEWS

    • Neuer Blog: Fotos und Eindrücke aus Solingen

    • ioBroker@Smart Living Forum Solingen, 14.06. - Agenda added

    • ioBroker goes Matter ... Matter Adapter in Stable

    Park-Ampel

    This topic has been deleted. Only users with topic management privileges can see it.
    • T
      TH16 @Wal last edited by

      @wal

      12:53:05.308 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:06.295 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:06.301 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:07.310 MQT: tele/Park-Ampel/STATE = {"Time":"2023-04-02T12:53:07","Uptime":"0T00:28:23","UptimeSec":1703,"Heap":18,"SleepMode":"Dynamic","Sleep":50,"LoadAvg":22,"MqttCount":1,"POWER1":"OFF","POWER2":"OFF","POWER3":"OFF","Wifi":{"AP":1,"SSId":"KON","BSSId":"CC:2D:21:55:C1:31","Channel":13,"Mode":"11n","RSSI":90,"Signal":-55,"LinkCount":1,"Downtime":"0T00:00:17"}}
      12:53:07.320 MQT: tele/Park-Ampel/SENSOR = {"Time":"2023-04-02T12:53:07","SR04":{"Distance":87.3}}
      12:53:07.325 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:07.331 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:08.265 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:08.271 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:09.310 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:09.317 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:10.280 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:10.288 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:11.278 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:11.284 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:12.267 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:12.273 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:13.278 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:13.285 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:14.267 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:14.275 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:15.312 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:15.318 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:16.283 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:16.289 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:17.277 MQT: tele/Park-Ampel/STATE = {"Time":"2023-04-02T12:53:17","Uptime":"0T00:28:33","UptimeSec":1713,"Heap":18,"SleepMode":"Dynamic","Sleep":50,"LoadAvg":19,"MqttCount":1,"POWER1":"OFF","POWER2":"OFF","POWER3":"OFF","Wifi":{"AP":1,"SSId":"KON","BSSId":"CC:2D:21:55:C1:31","Channel":13,"Mode":"11n","RSSI":90,"Signal":-55,"LinkCount":1,"Downtime":"0T00:00:17"}}
      12:53:17.287 MQT: tele/Park-Ampel/SENSOR = {"Time":"2023-04-02T12:53:17","SR04":{"Distance":87.3}}
      12:53:17.291 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:17.298 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:18.281 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:18.288 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:19.296 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:19.303 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:20.287 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:20.293 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:21.277 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:21.283 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:22.296 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:22.302 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:23.286 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:23.294 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:24.305 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:24.312 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:25.302 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:25.308 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:26.289 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:26.295 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:27.331 MQT: tele/Park-Ampel/STATE = {"Time":"2023-04-02T12:53:27","Uptime":"0T00:28:43","UptimeSec":1723,"Heap":18,"SleepMode":"Dynamic","Sleep":50,"LoadAvg":29,"MqttCount":1,"POWER1":"OFF","POWER2":"OFF","POWER3":"OFF","Wifi":{"AP":1,"SSId":"KON","BSSId":"CC:2D:21:55:C1:31","Channel":13,"Mode":"11n","RSSI":88,"Signal":-56,"LinkCount":1,"Downtime":"0T00:00:17"}}
      12:53:27.340 MQT: tele/Park-Ampel/SENSOR = {"Time":"2023-04-02T12:53:27","SR04":{"Distance":87.5}}
      12:53:27.345 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:27.352 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:28.289 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:28.296 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:29.279 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:29.285 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:30.301 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:30.307 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:31.292 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:31.298 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:32.308 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:32.314 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:33.300 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:33.306 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:53:34.292 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:53:34.298 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:07.285 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:07.291 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:08.274 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:08.281 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:09.267 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:09.273 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:10.304 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:10.311 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:11.296 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:11.302 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:12.287 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:12.293 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:13.276 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:13.283 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:14.269 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:14.275 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:15.312 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:15.318 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:16.304 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:16.310 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:17.302 MQT: tele/Park-Ampel/STATE = {"Time":"2023-04-02T12:54:17","Uptime":"0T00:29:33","UptimeSec":1773,"Heap":18,"SleepMode":"Dynamic","Sleep":50,"LoadAvg":19,"MqttCount":1,"POWER1":"OFF","POWER2":"OFF","POWER3":"OFF","Wifi":{"AP":1,"SSId":"KON","BSSId":"CC:2D:21:55:C1:31","Channel":13,"Mode":"11n","RSSI":90,"Signal":-55,"LinkCount":1,"Downtime":"0T00:00:17"}}
      12:54:17.312 MQT: tele/Park-Ampel/SENSOR = {"Time":"2023-04-02T12:54:17","SR04":{"Distance":87.4}}
      12:54:17.317 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:17.324 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:18.305 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:18.312 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:19.297 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:19.304 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:20.291 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:20.297 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:21.281 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:21.287 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:22.270 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:22.276 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:23.310 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:23.316 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:23.447 CMD: Weblog 4
      12:54:23.454 MQT: stat/Park-Ampel/RESULT = {"WebLog":4}
      12:54:23.458 Script: performs "power1 0"
      12:54:23.460 SRC: Rule
      12:54:23.463 CMD: Grp 0, Cmd 'POWER', Idx 1, Len 1, Pld 0, Data '0'
      12:54:23.471 MQT: stat/Park-Ampel/RESULT = {"POWER1":"OFF"}
      12:54:23.476 MQT: stat/Park-Ampel/POWER1 = OFF
      12:54:23.478 Script: performs "power2 0"
      12:54:23.480 SRC: Rule
      12:54:23.483 CMD: Grp 0, Cmd 'POWER', Idx 2, Len 1, Pld 0, Data '0'
      12:54:23.491 MQT: stat/Park-Ampel/RESULT = {"POWER2":"OFF"}
      12:54:23.497 MQT: stat/Park-Ampel/POWER2 = OFF
      12:54:23.500 Script: performs "power3 0"
      12:54:23.502 SRC: Rule
      12:54:23.505 CMD: Grp 0, Cmd 'POWER', Idx 3, Len 1, Pld 0, Data '0'
      12:54:23.513 MQT: stat/Park-Ampel/RESULT = {"POWER3":"OFF"}
      12:54:23.518 MQT: stat/Park-Ampel/POWER3 = OFF
      12:54:23.521 Script: performs "publish stat/Park-Ampel/RESULT {"AutoInGarage":"False"}"
      12:54:23.522 SRC: Rule
      12:54:23.525 CMD: Grp 0, Cmd 'PUBLISH', Idx 1, Len 47, Pld -99, Data 'stat/Park-Ampel/RESULT {"AutoInGarage":"False"}'
      12:54:23.530 MQT: stat/Park-Ampel/RESULT = {"AutoInGarage":"False"}
      12:54:23.873 CFG: Saved to flash at F6, Count 22, Bytes 4096
      12:54:24.285 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:24.287 SRC: Rule
      12:54:24.290 CMD: Grp 0, Cmd 'PUBLISH', Idx 1, Len 39, Pld -99, Data 'stat/Park-Ampel/RESULT {"Abstand":0.00}'
      12:54:24.296 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:25.281 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:25.283 SRC: Rule
      12:54:25.285 CMD: Grp 0, Cmd 'PUBLISH', Idx 1, Len 39, Pld -99, Data 'stat/Park-Ampel/RESULT {"Abstand":0.00}'
      12:54:25.291 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:26.295 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:26.297 SRC: Rule
      12:54:26.300 CMD: Grp 0, Cmd 'PUBLISH', Idx 1, Len 39, Pld -99, Data 'stat/Park-Ampel/RESULT {"Abstand":0.00}'
      12:54:26.305 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:27.296 MQT: tele/Park-Ampel/STATE = {"Time":"2023-04-02T12:54:27","Uptime":"0T00:29:43","UptimeSec":1783,"Heap":18,"SleepMode":"Dynamic","Sleep":50,"LoadAvg":23,"MqttCount":1,"POWER1":"OFF","POWER2":"OFF","POWER3":"OFF","Wifi":{"AP":1,"SSId":"KON","BSSId":"CC:2D:21:55:C1:31","Channel":13,"Mode":"11n","RSSI":90,"Signal":-55,"LinkCount":1,"Downtime":"0T00:00:17"}}
      12:54:27.305 MQT: tele/Park-Ampel/SENSOR = {"Time":"2023-04-02T12:54:27","SR04":{"Distance":87.4}}
      12:54:27.310 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:27.312 SRC: Rule
      12:54:27.315 CMD: Grp 0, Cmd 'PUBLISH', Idx 1, Len 39, Pld -99, Data 'stat/Park-Ampel/RESULT {"Abstand":0.00}'
      12:54:27.321 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:28.304 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:28.306 SRC: Rule
      12:54:28.308 CMD: Grp 0, Cmd 'PUBLISH', Idx 1, Len 39, Pld -99, Data 'stat/Park-Ampel/RESULT {"Abstand":0.00}'
      12:54:28.315 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:29.270 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:29.273 SRC: Rule
      12:54:29.276 CMD: Grp 0, Cmd 'PUBLISH', Idx 1, Len 39, Pld -99, Data 'stat/Park-Ampel/RESULT {"Abstand":0.00}'
      12:54:29.281 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:30.265 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:30.267 SRC: Rule
      12:54:30.270 CMD: Grp 0, Cmd 'PUBLISH', Idx 1, Len 39, Pld -99, Data 'stat/Park-Ampel/RESULT {"Abstand":0.00}'
      12:54:30.275 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:31.292 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:31.294 SRC: Rule
      12:54:31.298 CMD: Grp 0, Cmd 'PUBLISH', Idx 1, Len 39, Pld -99, Data 'stat/Park-Ampel/RESULT {"Abstand":0.00}'
      12:54:31.302 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:32.286 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:32.288 SRC: Rule
      12:54:32.291 CMD: Grp 0, Cmd 'PUBLISH', Idx 1, Len 39, Pld -99, Data 'stat/Park-Ampel/RESULT {"Abstand":0.00}'
      12:54:32.296 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      12:54:33.280 Script: performs "publish stat/Park-Ampel/RESULT {"Abstand":0.00}"
      12:54:33.283 SRC: Rule
      12:54:33.286 CMD: Grp 0, Cmd 'PUBLISH', Idx 1, Len 39, Pld -99, Data 'stat/Park-Ampel/RESULT {"Abstand":0.00}'
      12:54:33.291 MQT: stat/Park-Ampel/RESULT = {"Abstand":0.00}
      
      Wal 1 Reply Last reply Reply Quote 0
      • Wal
        Wal Developer @TH16 last edited by

        @th16 ,
        er ließt den Sensor nicht ein,

        Weg=SR04#Distance
        

        obwohl die Abfrage stimmt, ich kann leider nicht testen da ich den Sensor nicht habe.
        Ich kann da erstmal nicht weiter helfen.

        Flash nochmal die Sensor mit Rules und teste mal die Rule von @liv-in-sky.

        T 1 Reply Last reply Reply Quote 1
        • Wal
          Wal Developer @TH16 last edited by Wal

          @th16 ,
          so wie ich die Doku in Tasmota lese, wird nur alle Teleperiod ein Wert gesendet.
          D.h. Tasmota ist nicht für deine Applikation geeignet.
          Du wirst dir so etwas anschauen müssen oder wie @liv-in-sky bemerkte evtl. ESPEasy

          T 1 Reply Last reply Reply Quote 1
          • T
            TT-Tom @Wal last edited by

            @wal
            Sowas in Richtung Arduino hatte ich auch im Sinn aber ohne Sensor schwer zu testen.

            1 Reply Last reply Reply Quote 1
            • T
              TH16 @Wal last edited by

              @wal

              @wal sagte in Park-Ampel:

              @th16 ,
              so wie ich die Doku in Tasmota lese, wird nur alle Teleperiod ein Wert gesendet.
              D.h. Tasmota ist nicht für deine Applikation geeignet.
              Du wirst dir so etwas anschauen müssen oder wie @liv-in-sky bemerkte evtl. ESPEasy

              Das ist natürlich Schade, dass es so wie gedacht nicht funktioniert.
              Also werde ich mich wohl oder übel mal mit ESPHome/ESPEasy beschäftigen müssen wie von @liv-in-sky empfohlen.

              Euch allen, @Wal , @liv-in-sky , @TT-Tom , @David-G trotzdem einen herzlichen Dank für Eure Mühen bei diesem verzwickten Thema.
              Einen schönen Sonntag noch... 👍

              liv-in-sky 1 Reply Last reply Reply Quote 0
              • liv-in-sky
                liv-in-sky @TH16 last edited by

                @th16

                hier mal das ganze mit esphome - update im sekunden takt

                das ganze gehört aber noch verbessert: zb. die updatezeit zu ändern, wenn man weiter weg ist - sonst sendet der den ganzen tag oder auch; die updatezeit zu ändern, wenn sich der abstand nur minimal ändert (also bei stilstand) - aber das programmieren in esphome habe ich noch nie gemacht 😞

                script-vis31.gif

                T 1 Reply Last reply Reply Quote 1
                • T
                  TH16 @liv-in-sky last edited by

                  @liv-in-sky
                  Also das nenne ich mal schnell!
                  Ich denke mal, dass dies schon ausreichend sein sollte.
                  Und das Ganze ist mit ESPHome gemacht worden?
                  Also bräuchte ich "nur" den Wemos mit ESPHome zu flashen und mit ioBroker zu verbinden und MQTT auswerten?
                  Da ich mit ESPHome überhaupt noch nie was zu tun hatte, muss ich mich da erstmal einarbeiten.
                  Aber wenn ich das so sehe, wie schnell der updatet, lohnt sich der Aufwand auf jeden fall. 👍
                  So eine 10s-Sperre für MQTT-Übertragungen wie in Tasmota gibt es wohl bei ESPHome nicht?

                  Wal liv-in-sky 3 Replies Last reply Reply Quote 0
                  • Wal
                    Wal Developer @TH16 last edited by Wal

                    @th16 sagte in Park-Ampel:

                    So eine 10s-Sperre für MQTT-Übertragungen wie in Tasmota gibt es wohl bei ESPHome nicht?

                    Im Normalfall werden die Sensordaten in Echtzeit bei Änderungen übertragen, in der Teleperiode habe ich jetzt nur den SR04 gesehen.

                    Edit: Du hast Recht laut Doku sind es 10s, ich nutze bei meinen Geräten nur Script, da gebe ich den Intervall vor.
                    Du bekommst mit dem SR04 intern schon keine Echtzeitdaten, deshalb kann man keinen eigenen Intervall vorgeben.

                    1 Reply Last reply Reply Quote 0
                    • liv-in-sky
                      liv-in-sky @TH16 last edited by

                      @th16 hab mal nochmal drüber nachgedacht

                      dieses senden alle 1sek an iobroker finde ich nicht gut - zumindest sollte man dann die sende-update zeit anpassen, wenn das auto parkt oder nicht da ist - für esp-home habe ich da nicht alzuviel gefunden - https://community.home-assistant.io/t/dynamically-change-update-interval/108074/9

                      um das umzusetzen muss man schon irgendwie ahnung von esphome haben

                      wenn man aber die logic nicht an iob sendet, sondern intern hat (sowie das im tasmota script von @Wal war), macht das ganze mehr sinn - habe aber auch nur eins gefunden, was ich einigermaßen nachvollziehen kann https://gist.github.com/cadavre/1c4fe17e9f7d831080c5b6dd73b47930
                      leider ist da keinerlei anleitung dabei und er nutzt einen esp32 und ich weiß nicht mal, ob das wirklich funktioniert - aber irgendwie finde ich das am besten

                      1 Reply Last reply Reply Quote 0
                      • w00dst0ck
                        w00dst0ck last edited by

                        Im Vergleich zum guten alten Tennisball, der an einer Schnur von der Decke hängt und die Windschutzscheibe berührt, wenn man an der richtigen Stelle steht, wäre mir diese zwar technisch faszinierende aber fehleranfällige Lösung zu heikel.

                        Wenn einmal die Kommunikation ausfällt, hat man ggf. ne Macke im Auto.

                        liv-in-sky 1 Reply Last reply Reply Quote 0
                        • liv-in-sky
                          liv-in-sky @w00dst0ck last edited by liv-in-sky

                          @w00dst0ck

                          dann siehst du ja, das keine leds leuchten bzw. dass sich die led's nicht ändern

                          aber: wir sind smarthomler - wir wollen, dass strom fliest und kein ball von der decke hängt 🙂

                          so wie hier
                          script-vis33.gif

                          https://www.youtube.com/watch?v=HqqlY4_3kQ8

                          1 Reply Last reply Reply Quote 2
                          • liv-in-sky
                            liv-in-sky @TH16 last edited by

                            @th16 weil ich gerade zeit hatte - hier ein versuch mit chatgpt mit folgender aufgabe:

                            Image 044.png
                            Image 045.png

                            esphome:
                             name: sr04_leds
                             platform: ESP8266
                             board: nodemcuv2
                            
                            wifi:
                             ssid: "SSID"
                             password: "PASSWORD"
                            
                            # enable logging
                            logger:
                             
                            # enable Home Assistant API
                            api:
                            
                            # enable OTA updates
                            ota:
                            
                            sensor:
                             - platform: ultrasonic
                               trigger_pin: D1
                               echo_pin: D2
                               name: "SR04 Sensor"
                               update_interval: 1s
                            
                            output:
                             - platform: gpio
                               pin: D3
                               id: red_led
                             - platform: gpio
                               pin: D4
                               id: green_led
                             - platform: gpio
                               pin: D5
                               id: blue_led
                            
                            # automation to turn on/off leds based on sensor reading
                            automation:
                             - alias: "SR04 Distance LED Control"
                               trigger:
                                 platform: numeric_state
                                 entity_id: sensor.sr04_sensor
                                 above: 50
                               action:
                                 - output.turn_on: blue_led
                                 - output.turn_off: green_led
                                 - output.turn_off: red_led
                             - alias: "SR04 Distance LED Control"
                               trigger:
                                 platform: numeric_state
                                 entity_id: sensor.sr04_sensor
                                 above: 20
                                 below: 50
                               action:
                                 - output.turn_off: blue_led
                                 - output.turn_on: green_led
                                 - output.turn_off: red_led
                             - alias: "SR04 Distance LED Control"
                               trigger:
                                 platform: numeric_state
                                 entity_id: sensor.sr04_sensor
                                 below: 20
                               action:
                                 - output.turn_off: blue_led
                                 - output.turn_off: green_led
                                 - output.turn_on: red_led
                            
                            

                            T 1 Reply Last reply Reply Quote 2
                            • T
                              TH16 @liv-in-sky last edited by

                              @liv-in-sky
                              Vielen Dank!
                              Da hab ich diese Woche erstmal was zu tun. 😀
                              Ich melde mich...

                              liv-in-sky 2 Replies Last reply Reply Quote 0
                              • liv-in-sky
                                liv-in-sky @TH16 last edited by liv-in-sky

                                @th16

                                kuck mal da 🙂 - ganz unten dp leds zeigt farbe an, die auch mit den leds zusammengehören

                                script-vis34.gif

                                bitte nicht über die schaltung lachen - habe 2 linke hände für sowas 😞

                                script-vis35.gif

                                mußte das mit dem vl53lx sensor machen - der sr04 "spinnt" irgendwie

                                esphome:
                                 name: entfernungwemos
                                 platform: ESP8266
                                 board: d1_mini
                                
                                wifi:
                                 ssid: "Dragonyyyyyyy1"
                                 password: "xxxxxxxxxxxxx"
                                 use_address: 192.168.178.64
                                
                                # enable logging
                                logger:
                                 
                                # enable Home Assistant API
                                api:
                                
                                # enable OTA updates
                                ota:
                                
                                mqtt:
                                 broker: 192.168.178.59
                                 port: 1506
                                 topic_prefix: entfernungsampel/chatgpt/distance
                                 
                                i2c:
                                 sda: D2
                                 scl: D1
                                 scan: True
                                
                                sensor:
                                 - platform: vl53l0x
                                   address: '0x29'
                                   name: "SR04 Sensor"
                                   id: sr04_sensor
                                   long_range: true
                                   update_interval: 1s
                                   unit_of_measurement: "m"
                                   on_value:
                                     then:
                                       
                                       - if:
                                           condition:
                                             lambda: "return id(sr04_sensor).state > 0.5;"
                                           then:
                                             - output.turn_off: yellow_led
                                             - output.turn_on: green_led
                                             - output.turn_off: red_led
                                             - mqtt.publish:
                                                 topic: "entfernungsampel/chatgpt/leds"
                                                 payload: "green"
                                       - if:
                                           condition:
                                             lambda: "return (id(sr04_sensor).state > 0.2) && (id(sr04_sensor).state <= 0.5);"
                                           then:
                                             - output.turn_on: yellow_led
                                             - output.turn_off: green_led
                                             - output.turn_off: red_led
                                             - mqtt.publish:
                                                 topic: "entfernungsampel/chatgpt/leds"
                                                 payload: "yellow"
                                       - if:
                                           condition:
                                             lambda: "return id(sr04_sensor).state <= 0.2;"
                                           then:
                                             - output.turn_off: yellow_led
                                             - output.turn_off: green_led
                                             - output.turn_on: red_led
                                             - mqtt.publish:
                                                 topic: "entfernungsampel/chatgpt/leds"
                                                 payload: "red"
                                
                                output:
                                 - platform: gpio
                                   pin: D3
                                   id: red_led
                                 - platform: gpio
                                   pin: D4
                                   id: green_led
                                 - platform: gpio
                                   pin: D5
                                   id: yellow_led
                                
                                

                                so mache ich das mit dem flashen - über esphome adapter

                                • ein standard esphome yaml für den esp erstellt unter: https://web.esphome.io/ und die wifi angaben machen - der esp wird dazu am usb port des pc's angeschlossen

                                • die ip adresse habe ich dann im yaml eingetragen - unter wifi - use_address

                                • im esphome-dashboard (über esphome adapter) auf edit drücken und das yaml hineinkopieren - sichern - installieren - der esp wird über wifi neu geflasht

                                1 Reply Last reply Reply Quote 2
                                • liv-in-sky
                                  liv-in-sky @TH16 last edited by liv-in-sky

                                  @th16

                                  hab' ne neue version mit ws2812b led-stripe (6 leds) gemacht - gerstern war hier feiertag 🙂

                                  die mqtt daten (entfernung und ampelfarbe) werden nur noch bei änderung des bereichs (bzw änderung der ampelfarbe) zu iobroker übermittelt und nicht jede sekunde

                                  die einzelled's sind noch im code enthalten und könnten statt ws1812 weiterhin genutzt werden

                                  evtl versuche ich noch das abschalten der led's nach einer bestimmten stillstand periode einzufügen

                                  wie erwähnt - basteln ist nicht mein ding - die farben kommen in video leider nicht gnz so gut wie in echt 😞

                                  script-vis38.gif

                                  esphome:
                                   name: entfernungwemos
                                   platform: ESP8266
                                   board: d1_mini
                                  
                                  wifi:
                                   ssid: "Drxxxxxxxxxxxx"
                                   password: "fdfdfghjjhgffddddd"
                                   use_address: 192.168.178.64
                                  
                                  # enable logging
                                  logger:
                                   
                                  # enable Home Assistant API
                                  api:
                                  
                                  # enable OTA updates
                                  ota:
                                  
                                  mqtt:
                                   broker: 192.168.178.59
                                   port: 1506
                                   # topic_prefix: entfernungsampel/chatgpt/distance
                                   
                                  i2c:
                                   sda: D2
                                   scl: D1
                                   scan: True
                                  
                                  globals:
                                   - id: cur_led
                                     type: std::string
                                     initial_value: '"off"'
                                  
                                  light:
                                   - platform: neopixelbus
                                     type: GRB
                                     id: voyant_led
                                     variant: WS2812X
                                     pin: GPIO3
                                     num_leds: 6
                                     name: "NeoPixel Light"
                                     default_transition_length: 0.5s
                                     availability:
                                       topic: livingroom/status
                                       payload_available: online
                                       payload_not_available: offline
                                     state_topic: entfernungsampel/chatgpt/neo/custom_state_topic
                                     command_topic: entfernungsampel/chatgpt/neo/custom_command_topic
                                     command_retain: false
                                  
                                  sensor:
                                   - platform: vl53l0x
                                     address: '0x29'
                                     name: "SR04 Sensor"
                                     id: sr04_sensor
                                     long_range: true
                                     update_interval: 1s
                                     unit_of_measurement: "m"
                                     on_value:
                                       then:
                                         - logger.log:
                                             format: "Setting temp bar width to %s. and %d and %d and %d"
                                             args: ['id(cur_led).c_str()','strcmp(id(cur_led).c_str(), "green")','strcmp(id(cur_led).c_str(), "yellow")','strcmp(id(cur_led).c_str(), "red")']
                                         - if:
                                             condition:
                                               and:
                                               - lambda: "return id(sr04_sensor).state > 0.8;"
                                               - lambda: 'return (strcmp(id(cur_led).c_str(), "green")<0 || strcmp(id(cur_led).c_str(), "green")>0 );'
                                             then:
                                               - lambda: |- 
                                                         id(cur_led) = "green";    
                                               - output.turn_off: yellow_led
                                               - output.turn_on: green_led
                                               - output.turn_off: red_led
                                          #     - light.addressable_set:
                                          #        id: voyant_led
                                          #        range_from: 0
                                          #        range_to: 5
                                          #        red: 100%
                                          #        green: 0%
                                          #        blue: 0%
                                          #        color_brightness: 30%
                                  
                                               - mqtt.publish:
                                                    topic: "entfernungsampel/chatgpt/color/leds"
                                                    payload: "green"
                                               - mqtt.publish:
                                                    topic: "entfernungsampel/chatgpt/color/dist"
                                                    payload: !lambda |-
                                                               return str_snprintf("%f", 32, id(sr04_sensor).state);
                                               - light.turn_on:
                                                   id: voyant_led
                                                   brightness: 40%
                                                   red: 0%
                                                   green: 100%
                                                   blue: 0%
                                         - if:
                                             condition:
                                               and:
                                                 - lambda: "return (id(sr04_sensor).state > 0.5) && (id(sr04_sensor).state <= 0.8);"
                                                 - lambda: 'return (strcmp(id(cur_led).c_str(), "yellow")<0 || strcmp(id(cur_led).c_str(), "yellow")>0 );'
                                             then:
                                               - globals.set:
                                                   id: cur_led
                                                   value: '"yellow"'
                                               - output.turn_on: yellow_led
                                               - output.turn_off: green_led
                                               - output.turn_off: red_led
                                        #       - light.addressable_set:
                                        #          id: voyant_led
                                        #          range_from: 0
                                        #          range_to: 5
                                        #          red: 100%
                                        #          green: 100%
                                        #          blue: 0%
                                        #          color_brightness: 30%
                                  
                                               - mqtt.publish:
                                                   topic: "entfernungsampel/chatgpt/color/leds"
                                                   payload: "yellow"
                                               - mqtt.publish:
                                                    topic: "entfernungsampel/chatgpt/color/dist"
                                                    payload: !lambda |-
                                                               return str_snprintf("%f", 32, id(sr04_sensor).state);
                                               - light.turn_on:
                                                   id: voyant_led
                                                   brightness: 40%
                                                   red: 100%
                                                   green: 100%
                                                   blue: 0%
                                         - if:
                                             condition:
                                                and:
                                                 - lambda: "return id(sr04_sensor).state <= 0.5;"
                                                 - lambda: 'return strcmp(id(cur_led).c_str(), "red")<0 || strcmp(id(cur_led).c_str(), "red")>0 ;'
                                             then:
                                               - globals.set:
                                                   id: cur_led
                                                   value: '"red"'
                                               - output.turn_off: yellow_led
                                               - output.turn_off: green_led
                                               - output.turn_on: red_led
                                         #      - light.addressable_set:
                                         #         id: voyant_led
                                        #          range_from: 0
                                         #         range_to: 5
                                         #         red: 100%
                                         #         green: 0%
                                         #         blue: 0%
                                         #         color_brightness: 30%
                                  
                                               - mqtt.publish:
                                                   topic: "entfernungsampel/chatgpt/color/leds"
                                                   payload: "red"
                                               - mqtt.publish:
                                                    topic: "entfernungsampel/chatgpt/color/dist"
                                                    payload: !lambda |-
                                                               return str_snprintf("%f", 32, id(sr04_sensor).state);
                                               - light.turn_on:
                                                   id: voyant_led
                                                   brightness: 40%
                                                   red: 100%
                                                   green: 0%
                                                   blue: 0%
                                  
                                  output:
                                   - platform: gpio
                                     pin: D3
                                     id: red_led
                                   - platform: gpio
                                     pin: D4
                                     id: green_led
                                   - platform: gpio
                                     pin: D5
                                     id: yellow_led
                                  
                                  

                                  1 Reply Last reply Reply Quote 1
                                  • liv-in-sky
                                    liv-in-sky last edited by liv-in-sky

                                    habe nun ein script - mit dem ausschalten nach einer bestimmten zeit, wenn keine bewegung stattfindet

                                    script auf github:
                                    https://github.com/liv-in-sky/esphome-park-ampel-wemos_d-lx53l0x/blob/main/README.md
                                    im einsatz:
                                    https://www.youtube.com/shorts/nFh81V3uW6I

                                    1 Reply Last reply Reply Quote 0
                                    • First post
                                      Last post

                                    Support us

                                    ioBroker
                                    Community Adapters
                                    Donate
                                    FAQ Cloud / IOT
                                    HowTo: Node.js-Update
                                    HowTo: Backup/Restore
                                    Downloads
                                    BLOG

                                    879
                                    Online

                                    31.9k
                                    Users

                                    80.1k
                                    Topics

                                    1.3m
                                    Posts

                                    6
                                    55
                                    3458
                                    Loading More Posts
                                    • Oldest to Newest
                                    • Newest to Oldest
                                    • Most Votes
                                    Reply
                                    • Reply as topic
                                    Log in to reply
                                    Community
                                    Impressum | Datenschutz-Bestimmungen | Nutzungsbedingungen
                                    The ioBroker Community 2014-2023
                                    logo