Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

HomeSeer plugins are developed using the dotNET Framework and can be written using any language that is compatible with version 4.6.2.  Follow these steps to get started developing your own plugin.


Install HomeSeer HS4

Plugins rely on certain packages contained within the HomeSeer installation directory.  Before you can begin developing a plugin for HS4, you will need to make sure that you have a registered copy of the latest version of the platform installed on your computer.


Info

Download the latest installer from the forums.


Info

HS4 Alpha installations will currently only work with trial licenses that expire after 30 days.

Download the Source for the Sample Plugin

The source code for sample plugins can be downloaded through GitHub.

Info

You can find a sample plugin here, which demonstrates how to integrate with the various components of the HomeSeer platform.

For a VB.NET version of the same plugin, go here.

Specify the HomeSeer Root Directory

The sample plugins are all configured to automatically deploy the executable and any content needed for feature pages directly to the local HomeSeer instance when you are using the "DirectToHs" build configuration as long as few paths are set up correctly within the project's MSBuild process.  Open up the plugin's solution file in your preferred IDE, and then open up the project file so that you can edit it directly.

Note

If  you are using Microsoft Visual Studio, you will need to unload the project before you can edit the file directly.

At the top of the "Project" tag, you will see a property group with a label of "HomeSeer Properties."  This group contains two values, the ID of the plugin, and the relative path from the project to the HomeSeer instance.  Adjust the HomeSeerRoot tag so that it points to your local HomeSeer installation. Info

The "HomeSeerRoot" tag must be a relative path to the HomeSeer installation; this takes care of mapping all of the dependencies and the deployment of the plugin.

For Example:

If the plugin root directory is located at C:\Users\Homeseer\dev\SamplePlugin\

And the HomeSeer root directory is located at C:\Program Files (x86)\Homeseer HS4\

Then the HomeSeerRoot tag's value should be ..\..\..\..\Program Files (x86)\Homeseer HS4\

Save the file, reload the project, and then build it.  If the dependencies do not load successfully, check your relative path and try again.

Restore PluginSDK Nuget Package

The new HomeSeer PluginSDK is available for download and inclusion as a dependency in your project through nuget and can be found here or by searching for "HomeSeer Plugin SDK" in the nuget browser in your IDE.

Test the Plugin

Stop HomeSeer if it was previously running, and then start it again.  Once it is running, go to the Plugins menu at the top of HomeSeer's web console and click Manage.  Click the toggle switch next to the sample plugin to enable it.

You can now view the various sample pages registered by the sample plugin through the Plugins menu.

.


Create a new plugin

If you are looking for instructions on how to create a new plugin for the HS4 platform, check out the Creating a Plugin guide.


Try the sample plugins

There are a few sample plugins developed by HomeSeer, open-sourced, and available for your use in developing plugins.  You can find a list of the available samples and instructions on how to use them on the Sample Plugins page.


Migrate an existing HS3 plugin


Info

Documentation on this subject will be coming soon.


Report issues and contribute updates to the SDK

The Plugin SDK has been open-sourced and is available on GitHub: HomeSeer/Plugin-SDK


Please report any issues you are experiencing there.  Contributions are welcome; create a pull request.