Jump to content

Can I run a program based on receiving a network message using Networking Module?


blueman2

Recommended Posts

The documentation on the networking module is rather sparse.  Does anyone know if the module allows you to trigger a program based on receiving a network command from another device (in my case, an IP camera program called iSpy which can send messages via http)?   

Link to comment

Sure. Use the REST API.

 

Create your program, then go to the Summary view (Programs tab, then Summary tab). Look for the ID of your program (right-most column).

 

To run a program with ID 002e, on a controller at IP address 1.2.3.4, for example:

 

    http: //userid:password@1.2.3.4/rest/programs/002e/run

 

(Remove the space after the colon, I put it there to keep the forum from truncating the URL...)

 

I have  a strange application for this. I use the ISY to maintain a variable with the on/off state of my cable box. Because my cable box is a stupid one that only has a "toggle" power function. (You can't command it specifically "on" or "off"...) The cable box is controlled by an IP-connected IR emitter. I use Roomie Remote (iPhone/iPad AV remote app) and it can send HTTP messages. And, so, to have Roomie Remote turn the cable box on or off, it runs a program on the ISY, and the program on the ISY turns the cable box on or off...

Link to comment

Neat!!  And I guess I do not even need the networking module in this case, right?  

 

Thanks.  And you have just made me think about about a half dozen other uses for this cool trick.  

 

 Blueman2

 

 

Sure. Use the REST API.

 

Create your program, then go to the Summary view (Programs tab, then Summary tab). Look for the ID of your program (right-most column).

 

To run a program with ID 002e, on a controller at IP address 1.2.3.4, for example:

 

    http: //userid:password@1.2.3.4/rest/programs/002e/run

 

(Remove the space after the colon, I put it there to keep the forum from truncating the URL...)

 

 

Link to comment

Correct, REST API doesn't need the network module.

 

However, my example above does, because my program has to access an IR emitter using HTTP. (I don't use the ISY IR option. I have a Global Cache' iTach IP2IR that has emitters on the A/V equipment (at least those components that don't have their own IP control).

 

So, really, just using the ISY as an intermediary between IP devices.

 

I also switch surround speakers between two rooms using an A/B speaker switch on one of the IR channels of the IP2IR. (wired, actually, but uses IR protocol). This speakers are switched based on Insteon lighting scenes. ("TV" or "Dine" scenes - screen can be swiveled between living room and dining room). In this case, if I want to use Roomie, it just changes the lighting scene, and then the speaker switch follows.

Link to comment

Archived

This topic is now archived and is closed to further replies.


  • Recently Browsing

    • No registered users viewing this page.
  • Who's Online (See full list)

    • There are no registered users currently online
  • Forum Statistics

    • Total Topics
      36.9k
    • Total Posts
      370.2k
×
×
  • Create New...