• Recent
    • Tags
    • Popular
    • Register
    • Login

    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

    maEventAudio issues

    User help
    2
    8
    2.6k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • B
      Balistar
      last edited by Balistar

      Hi,

      I am trying to get ma-event-audio to work in a custom web app (in overrides).

      The ONLY reference I could find anywhere is on the API Documents:

      <ma-event-audio audio-files="{CRITICAL: '/audio/critical.mp3'"></ma-event-audio>
      

      does not work. Nor does:

      <ma-event-audio audio-files="{CRITICAL: '/audio/critical.mp3'}"></ma-event-audio>
      

      Note the added closing "}"

      Nor:

      <ma-event-audio audio-files="./audio/critical.mp3" event-level="'URGENT'"></ma-event-audio>
      

      I have have a working event table on the same page:

      <md-card flex="100" flex-xs="100" style="padding: 0px;">
        <ma-events-table  limit="5" alarm-level="'URGENT'" acknowledged = "'false'" from="from" to="to"></ma-events-table>
      </md-card>
      
      1 Reply Last reply Reply Quote 0
      • Jared WiltshireJ
        Jared Wiltshire
        last edited by

        @balistar said in maEventAudio issues:

        <ma-event-audio audio-files="{CRITICAL: '/audio/critical.mp3'}"></ma-event-audio>

        This is the correct syntax. Unfortuantely there is a bug in this component, I have fixed it for the next release. Thanks for making me aware.

        As a work around this should get it fixed:

        <ma-event-audio audio-files="{CRITICAL: '/audio/critical.mp3'}" read-aloud="{}"></ma-event-audio>
        

        Developer at Radix IoT

        1 Reply Last reply Reply Quote 0
        • B
          Balistar
          last edited by Balistar

          Thanks Jared,

          Your work around works perfectly.

          Alarms goes off on Events. This makes it even more clear to me that I must be missing something in my event table configuration.

          <ma-events-table  limit="5" alarm-level="'URGENT'" acknowledged = "'false'" from="from" to="to"></ma-events-table>
          

          The now working ma-event-audio is sounding on events, but those events are not updated on the Event Table list. Only on a page refresh. I have a 20 datapoints on the same page that are updated every minute.

          For that matter. The Acknowledge "box" is not showing any events, even though there are "not-acknowledged" events in the table (after page page refresh).

          0_1513729664410_Image 2.jpg

          core 3.2.2

          Jared WiltshireJ 1 Reply Last reply Reply Quote 0
          • Jared WiltshireJ
            Jared Wiltshire @Balistar
            last edited by

            @balistar said in maEventAudio issues:

            The now working ma-event-audio is sounding on events, but those events are not updated on the Event Table list. Only on a page refresh. I have a 20 datapoints on the same page that are updated every minute.
            For that matter. The Acknowledge "box" is not showing any events, even though there are "not-acknowledged" events in the table (after page page refresh).

            Glad you got the audio working. Its curious that your events page is not showing the events as it uses the same mechanism to get events as the audio component (websocket). Do you have your event table filters set correctly? I have fixed at least one bug on this table for 3.3 so hopefully that will fix your issue.

            Developer at Radix IoT

            1 Reply Last reply Reply Quote 0
            • B
              Balistar
              last edited by

              When I added

              date-filter="true"
              

              events started to get listed without having to refresh the page. Thanks.

              My table now is:

              <ma-events-table  limit="5" alarm-level="'URGENT'" acknowledged = "'false'" date-filter="true" from="from" to="to"></ma-events-table>
              

              The "Acknowledge Box" still only shows 0 events.

              Another issue with maEventAudio is that on an Android there is no sound. I (nor you guys I suspect) have much experience with mobile. Perhaps it is related to the longstanding HTLM5 audio issues that mobile apps have. Permissions etc...

              PS what is the deal with "'xxx'" vs "xxx"? Your documentation and examples sometimes conflict.

              Jared WiltshireJ 1 Reply Last reply Reply Quote 0
              • Jared WiltshireJ
                Jared Wiltshire @Balistar
                last edited by

                @balistar said in maEventAudio issues:

                When I added
                date-filter="true"

                events started to get listed without having to refresh the page. Thanks.

                OK thats odd. I'll take a look at that.

                @balistar said in maEventAudio issues:

                The "Acknowledge Box" still only shows 0 events.

                OK yeah that might be a bug.

                @balistar said in maEventAudio issues:

                Another issue with maEventAudio is that on an Android there is no sound. I (nor you guys I suspect) have much experience with mobile. Perhaps it is related to the longstanding HTLM5 audio issues that mobile apps have. Permissions etc...

                Yeah we use the standard HTML5 audio interfaces. It does seem that Chrome on Android blocks audio unless its a direct reaction to a user event.
                https://bugs.chromium.org/p/chromium/issues/detail?id=178297
                From reading the comments it seems that if you add Mango to your homescreen the audio might just work.

                @balistar said in maEventAudio issues:

                PS what is the deal with "'xxx'" vs "xxx"? Your documentation and examples sometimes conflict.

                Typically attributes are evaluated as expressions. So the value of the variable will be passed through to the directive/component in this example

                <tag attribute="variableName"></tag>
                

                However you can just pass a string through like this -

                <tag attribute="'string value'"></tag>
                

                However some attributes are treated as plain strings, so the directive in this case would just receive the string value "ONE".

                <tag-2 attribute="ONE"></tag-2>
                

                If you want to evaluate an expression for these types of attributes you can use the curly braces

                <tag-2 attribute="{{ myVariable }}"></tag-2>
                

                So yes, all in all it can be a little confusing. If you have any examples of directives where the documentation isn't clear let me know. We do need to have a bit of a push on documentation.

                Developer at Radix IoT

                1 Reply Last reply Reply Quote 0
                • Jared WiltshireJ
                  Jared Wiltshire
                  last edited by

                  @balistar
                  I came checked into this and if you use acknowledged="false" instead of acknowledged="'false'" you should get the correct result.

                  Developer at Radix IoT

                  B 1 Reply Last reply Reply Quote 0
                  • B
                    Balistar @Jared Wiltshire
                    last edited by

                    @jared-wiltshire said in maEventAudio issues:

                    @balistar
                    I came checked into this and if you use acknowledged="false" instead of acknowledged="'false'" you should get the correct result.

                    Thanks, that worked. "Acknowledge Box" shows all filtered events.

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