| 
    
     | 
       
        | Author |  |  
        | raven77 Groupie
 
  
  
 Joined: January 02 2007
 Location: United States
 Online Status: Offline
 Posts: 44
 | 
          I have been playing around with macros trying to flash a switchlink for a given amount of time...I am not having much luck.
           | Posted: January 06 2007 at 17:01 | IP Logged |   |  
           | 
 |    any pointers?
 thanks!
 |  
        | Back to Top |     |  
        |  |  
        | raven77 Groupie
 
  
  
 Joined: January 02 2007
 Location: United States
 Online Status: Offline
 Posts: 44
 | 
          I tried this but it didnt work...any clues?
           | Posted: January 12 2007 at 03:49 | IP Logged |   |  
           | 
 |  :)
 Thanks
 
 insert into macroheader values ('KFLASH','FLASH THE KITCHEN LIGHTS',0,0,1);
 insert into macrodetail values ('KFLASH',1,10,'MS13ATIME',NULL,'ph_relativetime ( now(),60 ) ',0,'');
 insert into macrodetail values ('KFLASH',2,26,'',NULL,'start',0,'');
 insert into macrodetail values  ('KFLASH',3,42,'',NULL,'INSTEON+KITCHENLIGHTS+FASTON',0,'');
 insert into macrodetail values ('KFLASH',4,31,'',NULL,'.2',0,'');
 insert into macrodetail values  ('KFLASH',5,42,'',NULL,'INSTEON+KITCHENLIGHTS+FASTOFF',0,'') ;
 insert into macrodetail values ('KFLASH',6,31,'',NULL,'.2',0,'');
 insert into macrodetail values ('KFLASH',7,16,'',NULL,'if( {MS13ATIME} >= now(),"start","done")',0,'');
 insert into macrodetail values ('KFLASH',8,26,'',NULL,'done',0,'');
 
 |  
        | Back to Top |     |  
        |  |  
        | raven77 Groupie
 
  
  
 Joined: January 02 2007
 Location: United States
 Online Status: Offline
 Posts: 44
 | 
          wow forget it, I actually got it to work!
           | Posted: January 12 2007 at 03:58 | IP Logged |   |  
           | 
 |  I changed "jump" to "go to label" and it works!
 |  
        | Back to Top |     |  
        |  |  
        | dhoward Admin Group
 
  
  
 Joined: June 29 2001
 Location: United States
 Online Status: Offline
 Posts: 4447
 | 
          Raven,
           | Posted: January 17 2007 at 22:20 | IP Logged |   |  
           | 
 |  
 Sorry to take so long in getting to you.  Glad you were able to figure it out though.
 
 Let me know if you have any other questions or problems.
 
 Dave.
 
 |  
        | Back to Top |       |  
        |  |  
        | ginigma Senior Member
 
  
 
 Joined: June 18 2006
 Location: United States
 Online Status: Offline
 Posts: 127
 | 
          Where is "Device Control" (when used in a macro) defined/documented?
           | Posted: July 12 2007 at 23:58 | IP Logged |   |  
           | 
 |  
 I'm trying to create a macro which flashes the KPL LED's to indicate my garage door is open.  I tried using Insteon Group and Insteon Group Raw but they flash too slow.
 
 I know it's possible to do what I want because in the PLC Groups tab in Insteon Explorer, on the Control button, if I Flash the group, it blinks quickly, which is what I want.
 
 
 __________________
 Insteon (40 devices) ^ PowerHome (435 links) ^ Logitech Harmony 880
 |  
        | Back to Top |       |  
        |  |  
        | ginigma Senior Member
 
  
 
 Joined: June 18 2006
 Location: United States
 Online Status: Offline
 Posts: 127
 | 
          Bump.  Anyone?  Tony?
           | Posted: July 23 2007 at 14:20 | IP Logged |   |  
           | 
 |  
 __________________
 Insteon (40 devices) ^ PowerHome (435 links) ^ Logitech Harmony 880
 |  
        | Back to Top |       |  
        |  |  
        | TonyNo Moderator Group
 
  
  
 Joined: December 05 2001
 Location: United States
 Online Status: Offline
 Posts: 2889
 | 
          I don't have any KPL's.
           | Posted: July 23 2007 at 17:59 | IP Logged |   |  
           | 
 |    
 Wait... Do you want to flash just the KPL or the controlled lights?
 |  
        | Back to Top |       |  
        |  |  
        | ginigma Senior Member
 
  
 
 Joined: June 18 2006
 Location: United States
 Online Status: Offline
 Posts: 127
 | 
          I want to flash the KPL (the LED's behind the KPL buttons).  I don't want to flash the lights/loads.
           | Posted: July 23 2007 at 18:21 | IP Logged |   |  
           | 
 |  In my macro I tried using Insteon Group and Insteon Raw Group (doesn't make a difference) and turning on/off the group I assigned to the KPL buttons.  It does turn them on and off, but slowly, meaning too long a delay between on & off.  I don't have any delays in the macro.
 
 __________________
 Insteon (40 devices) ^ PowerHome (435 links) ^ Logitech Harmony 880
 |  
        | Back to Top |       |  
        |  |  
        | dhoward Admin Group
 
  
  
 Joined: June 29 2001
 Location: United States
 Online Status: Offline
 Posts: 4447
 | 
          Ginigma,
           | Posted: July 24 2007 at 16:58 | IP Logged |   |  
           | 
 |  
 Device Control within a macro uses the same device control strings that are available as a Timed Events action (and other screens).  The easiest way to see what is going on is to go to Timed Events, change the action type to "Device Control" and then double-click the action field to display the Device Control builder.  Build a few samples and you'll quickly see what the Device Control strings consist of.
 
 However, I dont think it would be what you're looking for fast group transitions.  The "Flash" on the Device Control window in Insteon Explorer is using a special direct controller mode (which is timing critical) to attempt to flash the lights as quickly as possible.  What I would try using is the ph_insteonrawgroup function and add 2000 to the Cmd1 parameter.
 
 What I think is happening in your situation is that you've most likely got "Group Cleanups" turned on.  That means that every time you send a group command, it will be followed by a direct group cleanup command.  This takes a bit of time and your flashing will be relatively slow.  However, you can on a per command basis, force PowerHome to NOT send group cleanups if you have them turned on (or vice versa if they're turned off).
 
 What I would do is create a macro that looks like this.  In my example, my Insteon controller ID is "SDM" and the PLC group I want to flash is 5:
 
 
 
| Code: 
 
    
    | 
      
       | 10 Jump if(ph_ismacrowaiting("THIS_MACRO_ID") = 0,1,999)
 20 Formula Immediate ph_insteonrawgroup("SDM",5,2018,0)
 30 Wait 0.3
 40 Formula Immediate ph_insteonrawgroup("SDM",5,2020,0)
 50 Wait 0.3
 60 Jump - 4
 
 |  |  |  
 I would launch the above macro anytime I want to flash the lights.  To stop the flashing, use the function ph_killmacrowait.
 
 This should flash the group as fast as PowerHome possibly can.  You can try smaller Wait values, but you run the risk of overrunning the pitiful SDM buffer.
 
 Let me know how it works out.
 
 Dave.
 
 |  
        | Back to Top |       |  
        |  |  
        | ginigma Senior Member
 
  
 
 Joined: June 18 2006
 Location: United States
 Online Status: Offline
 Posts: 127
 | 
          Well, I guess it's faster than what I was doing.  And yes, I do have PLC Group Cleanup enabled, so I can understand why that slows things down.
           | Posted: July 24 2007 at 20:55 | IP Logged |   |  
           | 
 |  
 It's still not as fast as I'd like.  I want to flash the group as an indicator that my garage doors are open.  If you have any other suggestions, I'm open to them.
 
 Thanks,
 Charles
 
 __________________
 Insteon (40 devices) ^ PowerHome (435 links) ^ Logitech Harmony 880
 |  
        | Back to Top |       |  
        |  |  
        | keepersg Newbie
 
  
 
 Joined: July 23 2007
 Location: United States
 Online Status: Offline
 Posts: 29
 | 
          I tried this last night, as its something I'm interested in.  The LED on my KPL flashed at a rate a little slower than 2/second so it would work well for signalling.  I did have PLC group clean up enabled.
           | Posted: July 25 2007 at 13:02 | IP Logged |   |  
           | 
 |  
 |  
        | Back to Top |     |  
        |  |  
        | dhoward Admin Group
 
  
  
 Joined: June 29 2001
 Location: United States
 Online Status: Offline
 Posts: 4447
 | 
          Charles,
           | Posted: July 26 2007 at 17:26 | IP Logged |   |  
           | 
 |  
 Did you try moving the Wait parameter down to something like .2 or .15?  It may be worth a try to see if any extra speed is picked up but if it seems to get slower or react sporadically, then you're probably going faster than the SDM can take it.
 
 I'll play with it some tonight and let you know what speed I can get.  I would think that you should be able to get about 3 transitions per second.
 
 Dave.
 
 |  
        | Back to Top |       |  
        |  |  |  |