Results 1 to 4 of 4

Thread: Plugin ideas

  1. #1
    Join Date
    May 2016
    Posts
    19

    Lightbulb Plugin ideas

    I was thinking about working on a plugin to do simple HTTP GET or POST requests and organizing them similar to the simpleTransport plugin. My use case would be for DirecTV SHEF protocol control of a DirecTV DVR.

    I wasn't sure if this should be written as a separate plugin or if it would be better to modify the simpleTransport plugin to reuse some of the structure that is already in place. The major difference from simpleTransport is that this would be a new connection for each command/response, with the connection closed immediately after that. I'm not certain if that could work as another connection method added to simpleTransport or if it would be incompatible with the code already in place.

    This feature could also potentially be used for controlling Kodi via HTTP. However, I think having a preprocessor script for the data sent through simpleTransport would be even better for controlling Kodi over a simple TCP connection instead of via HTTP. But Kodi could be controlled with simpleTransport as it is now if the predefined commands contained properly encoded JSON and the transport type is set to PASSTHROUGH.

    I have been looking at the code for simpleTransport to see if these changes would be possible. Adding a preprocessor for the data to be sent seems like it would be quite simple to accomplish. I have not delved deeply enough to know if simpleTransport could also work with the one connection per transaction model required by the SHEF protocol. Perhaps you have some ideas about the best way to accomplish these goals?

  2. #2
    Join Date
    Mar 2005
    Posts
    724

    Default

    though I am not a expert I am pretty sure this can be a separate plugin as the concepts seems quite similar to the one I did for TCP Lightbulbs. have a look at the code http://www.promixis.com/forums/showt...t=tcp+lighting it is linked int he first post.

    Hope this helps,
    Yonu

  3. #3
    Join Date
    Jan 1998
    Location
    Jupiter, FL
    Posts
    13,553

    Default

    Yonu is right, forcing HTTP requests on the simple transport plugin would not be ideal. We have network.get/put/post available in Lua...
    Ron
    No support through PM

  4. #4
    Join Date
    May 2016
    Posts
    19

    Default

    Fair enough. What about the other idea about adding the ability to add a lua preprocessor for outgoing data?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •