spacejunk Posted June 21, 2017 Posted June 21, 2017 Greetings, Been trying to write a program and am baffled as to why it doesn't work. My Then statement - Then Set ' Porch Light ' Fast On Resource ' Diveway Motion ' Wait 3 minutes Set ' Porch Light ' Fast Off So when this runs it turns on an Insteon 2477D wall switch and then plays an MP3 file on a Raspberry Pi through Kodi. The light turns on fine and the MP3 file is heard on the speaker but then the program terminates before the three minutes are up and doesn't turn the switch back off. If I remove the network resource line the program works fine. I might add that if I right-click on the program and select Run Then it works as you would expect, just when it runs automatically is when it misbehaves. Thanks for any help you can offer me!
Techman Posted June 21, 2017 Posted June 21, 2017 Greetings, Been trying to write a program and am baffled as to why it doesn't work. My Then statement - Then Set ' Porch Light ' Fast On Resource ' Diveway Motion ' Wait 3 minutes Set ' Porch Light ' Fast Off So when this runs it turns on an Insteon 2477D wall switch and then plays an MP3 file on a Raspberry Pi through Kodi. The light turns on fine and the MP3 file is heard on the speaker but then the program terminates before the three minutes are up and doesn't turn the switch back off. If I remove the network resource line the program works fine. I might add that if I right-click on the program and select Run Then it works as you would expect, just when it runs automatically is when it misbehaves. Thanks for any help you can offer me! Do you have anything programmed in your IF statement? What are you using to trigger the THEN statement?
spacejunk Posted June 22, 2017 Author Posted June 22, 2017 Do you have anything programmed in your IF statement? What are you using to trigger the THEN statement? Yes, I did not include the IF portion for simplicity but it checks that a Insteon 2844 motion sensor is on AND from sunset to sunrise the next day.
paulbates Posted June 22, 2017 Posted June 22, 2017 When the conditions in the 'IF' statement become false, the program stops dead in its tracks. Thats where techman was going. If your motion sensor is set to send on and off commands, and the timer is <3 minutes, this is what's stopping the program. You can: put the sensor in linking mode, go to its settings in the admin console and select "Send on commands only" Paul Yes, I did not include the IF portion for simplicity but it checks that a Insteon 2844 motion sensor is on AND from sunset to sunrise the next day.
G W Posted June 22, 2017 Posted June 22, 2017 Have your first program call a second program. Move the Then statements from the first program to the second program. Sent from my Nexus 6P using Tapatalk
spacejunk Posted June 22, 2017 Author Posted June 22, 2017 When the conditions in the 'IF' statement become false, the program stops dead in its tracks. Thats where techman was going. If your motion sensor is set to send on and off commands, and the timer is <3 minutes, this is what's stopping the program. You can: put the sensor in linking mode, go to its settings in the admin console and select "Send on commands only" Paul I do not have the property "send on commands only" checked but I do have jumper #4 open on the MS to send an ON command only. What bothers me is the program times out normally if I am activating just the wall switch and nothing else in the THEN statement.
larryllix Posted June 22, 2017 Posted June 22, 2017 I do not have the property "send on commands only" checked but I do have jumper #4 open on the MS to send an ON command only. What bothers me is the program times out normally if I am activating just the wall switch and nothing else in the THEN statement. If jumper 5 is installed, then none of the other jumpers function, and all functions can be set via the admin console.
spacejunk Posted June 22, 2017 Author Posted June 22, 2017 If jumper 5 is installed, then none of the other jumpers function, and all functions can be set via the admin console. Yes I opened that jumper also.
KeviNH Posted June 22, 2017 Posted June 22, 2017 When the conditions in the 'IF' statement become false, the program stops dead in its tracks. Thats where techman was going. Specifically, the program will stop when the conditions in the 'IF' statement become false during a Wait or Repeat. I do not have the property "send on commands only" checked but I do have jumper #4 open on the MS to send an ON command only. What bothers me is the program times out normally if I am activating just the wall switch and nothing else in the THEN statement. Does the program that works also have a Wait statement? Please post the full programs -- both the version that works and the one that doesn't, with the "If" clause intact.
spacejunk Posted June 25, 2017 Author Posted June 25, 2017 When the conditions in the 'IF' statement become false, the program stops dead in its tracks. Thats where techman was going. If your motion sensor is set to send on and off commands, and the timer is <3 minutes, this is what's stopping the program. You can: put the sensor in linking mode, go to its settings in the admin console and select "Send on commands only" Paul This was actually what the problem was. I put jumper #5 back in checked "send on commands only" and the MS turns the wall switches on and the program times out as it should, turning the switches back off. Now I need to figure out what keeps setting the LED on levels to zero on my keypadlincs.
larryllix Posted June 25, 2017 Posted June 25, 2017 As per KeviNH, please post your programs, so we can stop guessing what may be happenning. Right click on each program, and select "copy to clipboard". Then paste here.
Recommended Posts
Archived
This topic is now archived and is closed to further replies.