• Recent
    • Tags
    • Popular
    • Register
    • Login
    1. Home
    2. mkart.vrn

    Please Note This forum exists for community support for the Mango product family and the Radix IoT Platform. Although Radix IoT employees participate in this forum from time to time, there is no guarantee of a response to anything posted here, nor can Radix IoT, LLC guarantee the accuracy of any information expressed or conveyed. Specific project questions from customers with active support contracts are asked to send requests to support@radixiot.com.

    Radix IoT Website Mango 3 Documentation Website Mango 4 Documentation Website Mango 5 Documentation Website
    M
    • Profile
    • Following 0
    • Followers 0
    • Topics 1
    • Posts 7
    • Best 0
    • Controversial 0
    • Groups 0

    mkart.vrn

    @mkart.vrn

    0
    Reputation
    5
    Profile views
    7
    Posts
    0
    Followers
    0
    Following
    Joined Last Online

    mkart.vrn Unfollow Follow

    Latest posts made by mkart.vrn

    • RE: Help a newbie figure out time-related functions.

      Thanks a lot! Yes, everything works as it should. Now I have almost completely understood the use of scripts.
      And there remains one more not completely clear point.
      What is a CONTEXT object? Is there a help page for CONTEXT.? What other methods can you use with it?

      Now I'm solving another problem,
      How to execute a script at a precisely specified time from the current moment? How can I cancel its launch during the waiting time?
      Are there any other ways to change the value of points after a given time?
      Thank you!

      posted in Dashboard Designer & Custom AngularJS Pages
      M
      mkart.vrn
    • RE: Help a newbie figure out time-related functions.

      Thanks for such a quick response!

      Context points are data points that trigger a script run based upon fhe setting of a data point's value being logged, updated, or changed.

      I can do something similar through a script in an event handler. But I just can’t figure out how to run a data point script on such events.

      I'll get something together based off of your dashboard with the scripting datasource used instead of the ui for you

      I would really appreciate your help!
      Thank you!

      posted in Dashboard Designer & Custom AngularJS Pages
      M
      mkart.vrn
    • RE: Help a newbie figure out time-related functions.

      Thanks for your answer and advice! Intuitively, I understood that it would be more correct to implement all actions in the system through scripts. But, unfortunately, I cannot find examples of solving any problems using scripts. I managed to figure out a little how to use scripts to handle events. But I absolutely cannot figure out how to use the script data points. I don't understand when these scripts are executed? Only by cron? How to process a button click in it? Is there an example somewhere using the script data points? I've tried many times to read the mango documentation about using script data points and meta data points, but without working examples I can't figure out how to use them.

      posted in Dashboard Designer & Custom AngularJS Pages
      M
      mkart.vrn
    • RE: Help a newbie figure out time-related functions.

      I finally solved my problem.
      The page is working, all the required results have been obtained. However, I can't remove the extra 1 in the number of days when displaying Duration. How can this be done?
      And I would very much like to understand how correct and optimal the methods I applied.
      To start a page, paste next text into a blank new page in the page editor in mango

      <div class="ma-designer-root" id="11c26dc1-8e3d-475e-ba22-1b6d9c37eb0c" style="width: 1366px; height: 768px; position: relative; background-color: rgb(204, 204, 255);">
      
          <ma-get-point-value point-xid="startTime" point="_startTime"></ma-get-point-value>
          <ma-get-point-value point-xid="stopTime" point="_stopTime"></ma-get-point-value>
          <ma-get-point-value point-xid="Start" point="_Start"></ma-get-point-value>
      
          <ma-switch id="0022dde1-a203-4176-a0eb-9b120feb36a3" style="position: absolute; left: 220px; top: 60px; font-weight: bold; font-family: fantasy; text-align: center; width: 100px; height: 70px; background-color: rgb(153, 153, 255); color: rgb(0, 0, 0);" display-type="switch" point="Start" label="NAME" point-xid="Start" ng-click="_Start.value ? (_stopTime.setValue(_stopTime.time)) :  (_startTime.setValue(_startTime.time))">Start</ma-switch>
          
              <ma-now update-interval="1 SECONDS" output="time" browser-timezone="browserTz"></ma-now>
       
          <div id="7ebdece1-8366-4df8-b660-62c0c19da235" style="position: absolute; left: 10px; top: 10px; width: 170px; height: 30px; font-weight: normal; line-height: 13px; font-size: 20px; font-family: fantasy;">{{time|maMoment:'format':' DD.MM.YY HH:mm:ss  '}}</div>
          <div id="b554c70c-e4ab-49f8-89be-0b1348180c96" style="position: absolute; left: 370px; top: 70px; width: 210px; height: 30px;">Start time:  {{_startTime.value|maMoment:'format':' DD.MM.YY HH:mm:ss '}}</div>
          <div id="55e794bb-b763-4d59-b2c7-b03bfac43d87" style="position: absolute; left: 370px; top: 100px; width: 210px; height: 30px;" ng-show="_Start.value === false">Stop time :{{_stopTime.value|maMoment:'format':' DD.MM.YY HH:mm:ss '}}</div>
          <div id="36cc40c9-66d1-4369-9b29-b18edf4cb066" style="position: absolute; left: 670px; top: 90px; width: 210px; height: 30px;" ng-show="_Start.value === false">{{(_stopTime.value-_startTime.value)/1000}}{{"sec = "}} {{((_stopTime.value-_startTime.value))|maMoment:'tz':'UTC'|maMoment:'format':'DDDD[day] HH:mm:ss '}}</div>
      
      <ma-indicator id="af49567e-6576-49f5-9bdd-8d8808324cbc" style="position: absolute; width: 30px; height: 30px; left: 330px; top: 80px;" color-false="#ff0000" color-true="#00f500" toggle-on-click="true" point="_Start"></ma-indicator>
          <div id="fe605657-ed93-4361-9755-7d4ff023ed1f" style="position: absolute; left: 670px; top: 90px; width: 140px; height: 30px;" ng-show="_Start.value">{{(_stopTime.time-_startTime.value)/1000}}sec</div>
          <div id="fffc771a-27b3-463b-b464-fdaf9db2841d" style="position: absolute; left: 590px; top: 90px; width: 150px; height: 30px;">Duration:</div>
      </div>
      
      

      and import the file export_Time_Demo.json into Data integration->Configuration Import/Export.
      Looking forward to your comments. Thank you.

      posted in Dashboard Designer & Custom AngularJS Pages
      M
      mkart.vrn
    • RE: Help a newbie figure out time-related functions.

      Thank you for your response! Over time, I have made significant progress in learning the tools and solving the problem. Currently, I am working on creating the final version of the demo page and would like to ask you to evaluate the correctness and effectiveness of the methods used. Thanks.
      Mike

      posted in Dashboard Designer & Custom AngularJS Pages
      M
      mkart.vrn
    • Help a newbie figure out time-related functions.

      Hey folks, I'm just getting started with Mango Automation. Trying to build a control page for this Modbus serial thing. I'm on Mango Automation V5.0.3, using Win10 and Chrome Version 120.0.6099.217.

      Most of it makes sense, but I'm stuck on dealing with time data. I can't figure out how to set up a page with a simple on/off switch (Start/Stop), and three fields for showing start time, stop time, and uptime, even during those Start/Stop switches. And, oh, I also want to show the Duration, both in time format and as a plain old integer counting seconds.

      What virtual data points do I need, and how should I format them? Anyone out there who can lend a hand to this newbie coder?

      Thanks a bunch, coding wizards! 🚀
      Mike

      posted in Dashboard Designer & Custom AngularJS Pages
      M
      mkart.vrn