Navigation

    Logo
    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unread
    • Categories
    • Unreplied
    • Popular
    • GitHub
    • Docu
    • Hilfe
    1. Home
    2. Deutsch
    3. Visualisierung
    4. [Vorstellung] Meine zweite Visualisierung

    NEWS

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

    • ioBroker goes Matter ... Matter Adapter in Stable

    • Monatsrückblick - April 2025

    [Vorstellung] Meine zweite Visualisierung

    This topic has been deleted. Only users with topic management privileges can see it.
    • BBTown
      BBTown @Pat1968 last edited by BBTown

      @Pat1968 sagte in [Vorstellung] Meine zweite Visualisierung:

      Bei falls hast du Wert stehen. Wie bekomme ich den, denn bei mir steht nichts mit Wert

      Das ist der Baustein "ObjectID" unter der Rubrik "Trigger"
      Beim Klick auf "ObjectID" kann "Wert" ausgewählt werden

      Pat1968 1 Reply Last reply Reply Quote 0
      • Pat1968
        Pat1968 @BBTown last edited by

        @BBTown

        Hab es gefunden .Danke. Das einschalten funktioniert aber das ausschalten geht nicht. Einmal eingeschaltet bleibt der Rahmen immer grün

        BBTown 1 Reply Last reply Reply Quote 0
        • BBTown
          BBTown @Pat1968 last edited by

          @Pat1968
          hmmm .... habe ich mir das zu einfach gemacht?
          dann versuche es so
          4b02b074-e277-4fbc-898a-098f0818a5c5-image.png

          Pat1968 1 Reply Last reply Reply Quote 0
          • Pat1968
            Pat1968 @BBTown last edited by

            @BBTown

            Das wars. Top Danke Dir

            1 Reply Last reply Reply Quote 0
            • O
              Oli last edited by

              @Kuddel ,

              kannst du mir bitte sagen, wo ich das Script finde, um die JS-Controllerversion auszulesen.

              Danke!!

              1 Reply Last reply Reply Quote 0
              • Glasfaser
                Glasfaser @Kuddel last edited by

                @Oli

                Er nimmt ein Shell Skript :

                @Kuddel sagte in [Vorstellung] Meine zweite Visualisierung:

                @Saschag

                In der Debian VM läuft ein Shell-Skript, welches ich per Crontab laufen lasse.


                Versionen abfragen:

                #ioBroker Version
                iobroker=$(iobroker version)
                iobroker state set javascript.0.Versionen.JS-Controller $iobroker
                
                #Node Version
                node=$(node -v)
                iobroker state set javascript.0.Versionen.Node $node
                
                #NPM Version
                npm=$(npm -v)
                iobroker state set javascript.0.Versionen.NPM $npm
                

                Crontab Eintrag

                #Abfrage der Versionen von ioBroker, Node und NPM
                * * * * * sudo /opt/iobroker/skripts/iobroker_versionen.sh
                

                O 1 Reply Last reply Reply Quote 0
                • O
                  Oli @Glasfaser last edited by

                  @Glasfaser

                  alles klar, danke, gibt es keine andere Möglichkeit, Shell-Skripte und ich, sind keine Freunde 🙂 ?

                  Glasfaser 1 Reply Last reply Reply Quote 0
                  • Glasfaser
                    Glasfaser @Oli last edited by Glasfaser

                    @Oli
                    Cron einstellen und den Datenpunkt !

                    1.JPG

                    <xml xmlns="http://www.w3.org/1999/xhtml">
                     <variables>
                       <variable type="" id="EE|8^;,}a,GYPGgn26|)">result</variable>
                     </variables>
                     <block type="schedule" id="M[#,#R:FmG:eOdafWIr." x="212" y="13">
                       <field name="SCHEDULE">* * * * *</field>
                       <statement name="STATEMENT">
                         <block type="exec" id="ol{Jh*]]dr6sxi,eh|SB">
                           <mutation with_statement="true"></mutation>
                           <field name="WITH_STATEMENT">TRUE</field>
                           <field name="LOG"></field>
                           <value name="COMMAND">
                             <shadow type="text" id="L,~P%61NDv)f_nrg+Afs">
                               <field name="TEXT">iobroker version</field>
                             </shadow>
                           </value>
                           <statement name="STATEMENT">
                             <block type="update" id="1{}L6QIWBOXXy91YSQ*t">
                               <mutation delay_input="false"></mutation>
                               <field name="OID">Object ID</field>
                               <field name="WITH_DELAY">FALSE</field>
                               <value name="VALUE">
                                 <block type="variables_get" id="?(d[K|PLj8%AWdxf5N4Y">
                                   <field name="VAR" id="EE|8^;,}a,GYPGgn26|)" variabletype="">result</field>
                                 </block>
                               </value>
                               <next>
                                 <block type="debug" id="Vd+yOIBcsZzv2L)]4hj#">
                                   <field name="Severity">log</field>
                                   <value name="TEXT">
                                     <shadow type="text" id="(eGJn]m(|hG3f$bZEf%J">
                                       <field name="TEXT"></field>
                                     </shadow>
                                     <block type="variables_get" id="Z7v0JT`(YZ/?Iy+q.1SL">
                                       <field name="VAR" id="EE|8^;,}a,GYPGgn26|)" variabletype="">result</field>
                                     </block>
                                   </value>
                                 </block>
                               </next>
                             </block>
                           </statement>
                         </block>
                       </statement>
                     </block>
                    </xml>
                    

                    Oder den Adapter SystemInfo installieren

                    2.JPG

                    O K 2 Replies Last reply Reply Quote 0
                    • O
                      Oli @Glasfaser last edited by

                      @Glasfaser

                      danke, hat funktioniert.

                      1 Reply Last reply Reply Quote 0
                      • K
                        Kuddel @Glasfaser last edited by Kuddel

                        @Glasfaser sagte in [Vorstellung] Meine zweite Visualisierung:

                        @Oli
                        Cron einstellen und den Datenpunkt !

                        1.JPG

                        <xml xmlns="http://www.w3.org/1999/xhtml">
                         <variables>
                           <variable type="" id="EE|8^;,}a,GYPGgn26|)">result</variable>
                         </variables>
                         <block type="schedule" id="M[#,#R:FmG:eOdafWIr." x="212" y="13">
                           <field name="SCHEDULE">* * * * *</field>
                           <statement name="STATEMENT">
                             <block type="exec" id="ol{Jh*]]dr6sxi,eh|SB">
                               <mutation with_statement="true"></mutation>
                               <field name="WITH_STATEMENT">TRUE</field>
                               <field name="LOG"></field>
                               <value name="COMMAND">
                                 <shadow type="text" id="L,~P%61NDv)f_nrg+Afs">
                                   <field name="TEXT">iobroker version</field>
                                 </shadow>
                               </value>
                               <statement name="STATEMENT">
                                 <block type="update" id="1{}L6QIWBOXXy91YSQ*t">
                                   <mutation delay_input="false"></mutation>
                                   <field name="OID">Object ID</field>
                                   <field name="WITH_DELAY">FALSE</field>
                                   <value name="VALUE">
                                     <block type="variables_get" id="?(d[K|PLj8%AWdxf5N4Y">
                                       <field name="VAR" id="EE|8^;,}a,GYPGgn26|)" variabletype="">result</field>
                                     </block>
                                   </value>
                                   <next>
                                     <block type="debug" id="Vd+yOIBcsZzv2L)]4hj#">
                                       <field name="Severity">log</field>
                                       <value name="TEXT">
                                         <shadow type="text" id="(eGJn]m(|hG3f$bZEf%J">
                                           <field name="TEXT"></field>
                                         </shadow>
                                         <block type="variables_get" id="Z7v0JT`(YZ/?Iy+q.1SL">
                                           <field name="VAR" id="EE|8^;,}a,GYPGgn26|)" variabletype="">result</field>
                                         </block>
                                       </value>
                                     </block>
                                   </next>
                                 </block>
                               </statement>
                             </block>
                           </statement>
                         </block>
                        </xml>
                        

                        Oder den Adapter SystemInfo installieren

                        2.JPG

                        Ich bin gerade dabei meinen ioBroker von einer Debian VM auf eine neue Ubuntu VM umzuziehen.

                        Die Javascript-Adapter Version ist auf beiden Systemen gleich (4.1.12).

                        Auf Debian funktioniert die Abfrage der Uptime meiner CCU, auf Ubuntu nicht.

                        ssh root@192.168.4.5 uptime | awk '{print $3_$4_$5}'
                        

                        1da9506a-0257-4e8d-af25-8e15b3f88ede-grafik.png

                        Damit wollte ich mein Shell-Skript ablösen und alles einheitlich in Blockly abbilden

                        Wenn ich den Befehl in der Kosole eingebe, bekomme ich die gewünschte Ausgabe:

                        root@ioBroker-MASTER:~# ssh root@192.168.4.5 uptime | awk '{print $3_$4_$5}'
                        120days,1:36,
                        root@ioBroker-MASTER:~#
                        
                        
                        Glasfaser 1 Reply Last reply Reply Quote 0
                        • Glasfaser
                          Glasfaser @Kuddel last edited by Glasfaser

                          @Kuddel

                          Kommt dann nur eine leere Ausgabe ohne Wert :?

                          CCU Uptime: 
                          

                          Nachtrag: sehe gerade du hast ein Thread eröffnet . Link Text

                          K 1 Reply Last reply Reply Quote 0
                          • K
                            Kuddel @Glasfaser last edited by

                            @Glasfaser ja eine leere Ausgabe.

                            habe parallel ein neues Thema dazu eröffnet:

                            Probleme mit Exec

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

                              Hallo @Kuddel

                              Ich würde gerne diese Grafik vom NUC etwas mit leben füllen.

                              81a9181a-fae8-4f7b-a371-c34db0de3639-image.png

                              Hast du das Skipt noch.

                              javascript.0.ressourcen.esx.esx-nuc_datastore_freespace

                              VG

                              K crunchip 2 Replies Last reply Reply Quote 1
                              • K
                                Kuddel @Uli977 last edited by

                                @Uli977 hier das Powershell Skript.

                                Geht sicherlich auch per Blockly und Exec, aber das habe ich noch nicht umgesetzt.

                                Import-Module VMware.PowerCLI
                                cls
                                
                                Connect-VIServer 192.168.4.45 -user root -Password ******************
                                cls
                                
                                #ESX-NUC Infos Abfragen
                                $esx_nuc_infos = get-vmhost
                                #Freier RAM ESX-NUC
                                $esx_nuc_ram = $esx_nuc_infos.MemoryUsageMB
                                Invoke-WebRequest -Uri http://192.168.4.30:8087/set/javascript.0.ressourcen.esx.esx-nuc_mem_usage?value=$esx_nuc_ram | Out-Null
                                $esx_nuc_ram_usage_percent = $esx_nuc_infos.MemoryUsageMB / $esx_nuc_infos.MemoryTotalMB
                                $esx_nuc_ram_usage_percent = $esx_nuc_ram_usage_percent * 100
                                $esx_nuc_ram_usage_percent = [math]::Round($esx_nuc_ram_usage_percent,0)
                                Invoke-WebRequest -Uri http://192.168.4.30:8087/set/javascript.0.ressourcen.esx.esx-nuc_mem_usage_percent?value=$esx_nuc_ram_usage_percent | Out-Null
                                       
                                #CPU Auslastung
                                $esx_nuc_cpu_usage = [INT]$esx_nuc_infos.CpuUsageMhz
                                Invoke-WebRequest -Uri http://192.168.4.30:8087/set/javascript.0.ressourcen.esx.esx-nuc_cpu_usage?value=$esx_nuc_cpu_usage | Out-Null
                                $esx_nuc_cpu_usage_percent = $esx_nuc_infos.CpuUsageMhz / $esx_nuc_infos.CpuTotalMhz
                                $esx_nuc_cpu_usage_percent = $esx_nuc_cpu_usage_percent * 100
                                $esx_nuc_cpu_usage_percent = [math]::Round($esx_nuc_cpu_usage_percent,0)
                                Invoke-WebRequest -Uri http://192.168.4.30:8087/set/javascript.0.ressourcen.esx.esx-nuc_cpu_usage_percent?value=$esx_nuc_cpu_usage_percent | Out-Null
                                       
                                
                                #Speicherauslastung SSD
                                $datastore = Get-Datastore SSD
                                $datastore_usage_percent = $datastore.CapacityGB - $datastore.FreeSpaceGB
                                $datastore_usage_percent = $datastore_usage_percent / $datastore.CapacityGB
                                $datastore_usage_percent = $datastore_usage_percent * 100
                                $datastore_usage_percent = [math]::Round($datastore_usage_percent,2)
                                Invoke-WebRequest -Uri http://192.168.4.30:8087/set/javascript.0.ressourcen.esx.esx-nuc_datastore_usage_percent?value=$datastore_usage_percent | Out-Null
                                #Freier Speicher in GB
                                Invoke-WebRequest -Uri http://192.168.4.30:8087/set/javascript.0.ressourcen.esx.esx-nuc_datastore_freespace?value=$($datastore.FreeSpaceGB) | Out-Null
                                

                                Uli977 K 4 Replies Last reply Reply Quote 0
                                • Uli977
                                  Uli977 @Kuddel last edited by

                                  @Kuddel Was ist das? ein normales Javaskript?

                                  1 Reply Last reply Reply Quote 0
                                  • Uli977
                                    Uli977 @Kuddel last edited by

                                    @Kuddel Ach ne, über console

                                    1 Reply Last reply Reply Quote 0
                                    • Uli977
                                      Uli977 @Kuddel last edited by

                                      @Kuddel Ääää, wo muss ich das verwenden?

                                      1 Reply Last reply Reply Quote 0
                                      • K
                                        Kuddel @Kuddel last edited by

                                        @Kuddel sagte in [Vorstellung] Meine zweite Visualisierung:

                                        @Uli977 hier das Powershell Skript.

                                        Das ist ein Powershell Skript und muss auf Windows laufen

                                        Uli977 1 Reply Last reply Reply Quote 0
                                        • Uli977
                                          Uli977 @Kuddel last edited by

                                          @Kuddel Ah, danke!

                                          1 Reply Last reply Reply Quote 0
                                          • crunchip
                                            crunchip Forum Testing Most Active @Uli977 last edited by

                                            @Uli977 liefert die Werte nicht der info Adapter

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

                                            Support us

                                            ioBroker
                                            Community Adapters
                                            Donate

                                            601
                                            Online

                                            31.6k
                                            Users

                                            79.6k
                                            Topics

                                            1.3m
                                            Posts

                                            template vis
                                            148
                                            1324
                                            437789
                                            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