more G-Labs products

Author Topic: Plugin development  (Read 1596 times)

December 18, 2015, 02:15:22 AM
Read 1596 times

maxflax

  • ***
  • Information
  • Full Member
  • Posts: 90
Hi Gene,

Im in the first phase of developing a plugin with functionality I need for my HG program. So my question is how I can connect to the functions in the plugin from my HG program. I have made a skeleton project based on the MQTT service plugin so the pure plugin is working now Im going to add the functions. I can tell that it has an interface for networking api calls but wondering if it's loaded into HG so I can access the dll directly with code?

And do you have any example code of interfacing with a plugin from a HG app?

Couldn't find any doc of the plugins so thats the reason for the inquery.



January 04, 2016, 03:04:41 AM
Reply #1

maxflax

  • ***
  • Information
  • Full Member
  • Posts: 90
Anyone?

Is making a call like this the only option or is there a better way?

Net.WebService("192.168.1.2/api/MIGService.Interfaces/HomeAutomation.MyService/dosomething")
                 .AddHeader("Content-Type", "application/json")
                 .Post(data)
                 .Call();
« Last Edit: January 04, 2016, 11:10:00 PM by maxflax »

January 05, 2016, 01:53:57 AM
Reply #2

maxflax

  • ***
  • Information
  • Full Member
  • Posts: 90
There must be a more conform way that I can't find in any docs or in the programs.

It really baffles me that this seems to be unknown to all, what am I missing?

Been battling this for a while now so if I sound harsh it's not intended.


January 05, 2016, 05:55:07 AM
Reply #3

bkenobi

  • *****
  • Information
  • Global Moderator
  • Posts: 1525
There aren't that many people who have posted custom plugins so that might be part of it.  It's similar to widgets in that only a couple have been posted so the knowledge base may be small.  I have no experience with either so you'll have to wait for someone that has constructed a plugin to see the thread.

January 05, 2016, 03:02:26 PM
Reply #4

dani

  • *****
  • Information
  • Global Moderator
  • Posts: 535
Can you join you src code of program and widget ?

January 06, 2016, 01:30:46 AM
Reply #5

maxflax

  • ***
  • Information
  • Full Member
  • Posts: 90
I did my best problem solving technique on it, "went to sleep", and solved it.. It never fails me this sleeping thingy :)