Announcement

Collapse
No announcement yet.

Command Line Arguments - Remote Server

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Tase
    replied
    I appreciate both of your responses. Thanks!

    Leave a comment:


  • jasv
    replied
    The IP address for the Abstract Plugin is a protected property. Not an ideal way to do it but I simply added the address to my HSPI() constructor right under LogDebug property. Obviously the IP address is the remote HS4 server. I am hoping at some point HS will make it a public attribute again.

    Code:
            public HSPI() {
                //Initialize the plugin
    
                //Enable internal debug logging to console
                LogDebug = true;
                //Setup anything that needs to be configured before a connection to HomeSeer is established
                // like initializing the starting state of anything needed for the operation of the plugin
    
                //Such as initializing the settings pages presented to the user (currently saved state is loaded later)
    [COLOR=#B22222][B]           IpAddress = "192.168.12.174";[/B][/COLOR]
                InitializeSettingsPages();
    
                //Or adding an event action or trigger type definition to the list of types supported by your plugin
                ActionTypes.AddActionType(typeof(WriteLogSampleActionType));
                TriggerTypes.AddTriggerType(typeof(SampleTriggerType));
            }

    Leave a comment:


  • Michael McSharry
    replied
    I did this when I first started with HS4, but been too long and don’t have remnants. What I think you need to do is overload the abstract plugin Connect method and pass the parameter at that point. I always hard coded the IP when I was testing so did not actually parse command line. Worth a try.

    If I remember correctly when the plugin connects the HS4 prints something like server = xxxx which implies there is some logic that it is using to get the remote IP.

    Leave a comment:


  • Tase
    started a topic Command Line Arguments - Remote Server

    Command Line Arguments - Remote Server

    To debug in HS3, I connect to a remote server. I've always passed along "server=192.168.1.xxx" in the command line. I am tinkering with one of the HS4 sample plugins and this appears to no longer work. I would appreciate help in resolving my issue.
Working...
X