MQTT Plugin (2 Viewers)

charli181

Retired Team Member
  • Premium Supporter
  • August 3, 2007
    800
    111
    Sydney
    Home Country
    Australia Australia
    just tried on new machine with MP1.30 and still the same error. any chance on getting the dll file put onto repo so I can manually install.
     

    ajs

    Development Group
  • Team MediaPortal
  • February 29, 2008
    15,620
    10,548
    Kyiv
    Home Country
    Ukraine Ukraine
    • Thread starter
    • Moderator
    • #22
    Very strange, maybe not enough rights or the file is broken? In the archive of the plugin library, put in "...\MediaPortal\plugins\process\".
     

    Attachments

    • MQTTPlugin.zip
      91 KB

    charli181

    Retired Team Member
  • Premium Supporter
  • August 3, 2007
    800
    111
    Sydney
    Home Country
    Australia Australia
    tried mpe1 1.0.0.5 and the install went perfect.... awesome work thanks.


    Now I have a new issue (Minor one) - when I send a message , in the MP log i see an error when I send a message through from HA.The message comes up and disappears as expected, just htis error is printed in the logs everytime a message comes through.

    Mediaportal.log extract

    [2022-07-02 11:46:18,932] [Error ] [57 ] [ERROR] - LoadSkin: Running on wrong thread - StackTrace: ' at System.Environment.GetStackTrace(Exception e, Boolean needFileInfo)
    at System.Environment.get_StackTrace()
    at MediaPortal.GUI.Library.GUIWindow.LoadSkinBool()
    at MediaPortal.GUI.Library.GUIWindow.AllocResources()
    at MQTTPlugin.QueueHandler.ShowQueue()
    at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
    at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
    at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
    at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
    at System.Threading.ThreadHelper.ThreadStart()'

    MQTTPlugin.log extract
    2/07/2022 11:46:18 AM[Debug] Message to be sent: Mediaportal/HTPC_J3710/Player/totaltime - 217
    2/07/2022 11:46:18 AM[Debug] Message with Id: 693 published.
    2/07/2022 11:46:18 AM[Debug] Message 693 sended.
    2/07/2022 11:46:18 AM[Debug] Message sended: 694: Mediaportal/HTPC_J3710/Player/remainingtime - 8 - 2 - True
    2/07/2022 11:46:18 AM[Debug] Message with Id: 694 published.
    2/07/2022 11:46:18 AM[Debug] Message 694 sended.
    2/07/2022 11:46:18 AM[Debug] Message sended: 695: Mediaportal/HTPC_J3710/Player/totaltime - 217 - 2 - True
    2/07/2022 11:46:18 AM[Debug] Message with Id: 695 published.
    2/07/2022 11:46:18 AM[Debug] Message 695 sended.
    2/07/2022 11:46:18 AM[Debug] Message received: [Mediaportal/HTPC_J3710/Command/message]: {"header":"Motion Detected - Front Yard","line1":"line1","line2":"line2","timeout":120,"image":"http://192.168.0.103:8123/api/frigate/notifications/1656725115.26113-vf2zg7/snapshot.jpg"}
    2/07/2022 11:46:18 AM[Debug] Message to received...
    2/07/2022 11:46:18 AM[Debug] Add Message to Queue...
    2/07/2022 11:46:18 AM[Debug] Dialog is not busy, fire ShowQueue Thread
    2/07/2022 11:46:18 AM[Debug] Mark message dialog busy
    2/07/2022 11:46:18 AM[Debug] Number of messages in queue: 1
    2/07/2022 11:46:18 AM[Debug] Message Header: Motion Detected - Front Yard
    2/07/2022 11:46:18 AM[Debug] Message Line 1: line1
    2/07/2022 11:46:18 AM[Debug] Message Line 2: line2
    2/07/2022 11:46:18 AM[Debug] Message given image: http://someserver/api/frigate/notifications/1656725115.26113-vf2zg7/snapshot.jpg
    2/07/2022 11:46:18 AM[Debug] Message processed image: C:\ProgramData\team mediaportal\mediaportal\thumbs\MQTTPlugin\MQTTPluginIcon.png
    2/07/2022 11:46:18 AM[Debug] Message timeout: 120
    2/07/2022 11:46:18 AM[Debug] Showing Message Dialog
    2/07/2022 11:46:18 AM[Debug] Message to be sent: Mediaportal/HTPC_J3710/Message/Displaying/message - Motion Detected - Front Yard
    2/07/2022 11:46:18 AM[Debug] Displaying Message Trigger: Motion Detected - Front Yard
    2/07/2022 11:46:18 AM[Debug] Message sended: 696: Mediaportal/HTPC_J3710/Message/Displaying/message - Motion Detected - Front Yard - 2 - True
    2/07/2022 11:46:18 AM[Debug] Message with Id: 696 published.
    2/07/2022 11:46:18 AM[Debug] Message 696 sended.
    2/07/2022 11:46:19 AM[Debug] Message to be sent: Mediaportal/HTPC_J3710/Player/playtime - 210
    2/07/2022 11:46:19 AM[Debug] Message sended: 697: Mediaportal/HTPC_J3710/Player/playtime - 210 - 2 - True
    2/07/2022 11:46:19 AM[Debug] Message to be sent: Mediaportal/HTPC_J3710/Player/remainingtime - 8
    2/07/2022 11:46:19 AM[Debug] Message to be sent: Mediaportal/HTPC_J3710/Player/totaltime - 218
    2/07/2022 11:46:19 AM[Debug] Message with Id: 697 published.
    2/07/2022 11:46:19 A
     

    charli181

    Retired Team Member
  • Premium Supporter
  • August 3, 2007
    800
    111
    Sydney
    Home Country
    Australia Australia
    Another question - do you know if the image can handle a url or does the image need to be stored on the cleint itself?. Reason is I can have HA send a notification message when there is motion detected by Frigate (Video Security) and it has a snapshot of the object it has detected. It would be good to show this in the GUIDialog but jsutt need to know what the image paramter supports.
     

    ajs

    Development Group
  • Team MediaPortal
  • February 29, 2008
    15,620
    10,548
    Kyiv
    Home Country
    Ukraine Ukraine
    • Thread starter
    • Moderator
    • #26
    Thank you, it's good when there are those who use it, i can catch more errors. I'll try to see.
    Regarding pictures, MP dialog, as far as I remember, supports both local and URL. But it is not exactly. We must check.
     

    ajs

    Development Group
  • Team MediaPortal
  • February 29, 2008
    15,620
    10,548
    Kyiv
    Home Country
    Ukraine Ukraine
    • Thread starter
    • Moderator
    • #27
    @doskabouter
    It seems to me that we solved the problem of calling the dialog box from another thread, but I can't find where or how.
    Can you remember where? :) Or maybe you have an idea how? To avoid the error: LoadSkin: Running on wrong thread - StackTrace
     

    ajs

    Development Group
  • Team MediaPortal
  • February 29, 2008
    15,620
    10,548
    Kyiv
    Home Country
    Ukraine Ukraine
    • Thread starter
    • Moderator
    • #29
    If I remember I'll post it here, but don't hold your breath...
    Maybe i need add Application.Current.Dispatcher.Invoke(somemethod); and in this method try show Dialog?
     

    Users who are viewing this thread

    Top Bottom