HomeGenie Forum

Automation Program Plugins and Wizard Scripting => Help => Topic started by: maxflax on December 18, 2015, 02:15:22 AM

Title: Plugin development
Post by: maxflax on December 18, 2015, 02:15:22 AM
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.


Title: Re: Plugin development
Post by: maxflax on January 04, 2016, 03:04:41 AM
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();
Title: Re: Plugin development
Post by: maxflax on January 05, 2016, 01:53:57 AM
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.

Title: Re: Plugin development
Post by: bkenobi on January 05, 2016, 05:55:07 AM
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.
Title: Re: Plugin development
Post by: dani on January 05, 2016, 03:02:26 PM
Can you join you src code of program and widget ?
Title: Re: Plugin development
Post by: maxflax on January 06, 2016, 01:30:46 AM
I did my best problem solving technique on it, "went to sleep", and solved it.. It never fails me this sleeping thingy :)