spyfish007 Posted January 20, 2018 Share Posted January 20, 2018 (edited) I purchased an IOLINC to control my hot water re-circulation pump. I am replacing my previous standalone controller, because I wanted more specific control that the ISY could provide me. Here is the program I wrote for the control. When I test the Then clause, the program executes exactly like I am seeking, so no problems with it. Hot Water Control - [iD 0004][Parent 0001] If Control 'Mechanial Room / io.Hot H20 Control-Sensor' is switched On Or $v_hot_water_control is 1 Then $v_hot_water_control = 1 $v_hot_water_calls += 1 Set 'Mechanial Room / io.Hot H20 Control-Relay' On Wait 30 seconds Set 'Mechanial Room / io.Hot H20 Control-Relay' Off Wait 20 minutes $v_hot_water_control = 0 $v_hot_water_calls Init To $v_hot_water_calls Else - No Actions - (To add one, press 'Action') // $v_hot_water_control is used to keep wait command from retriggering if condition // // * Goal is to no retrigger the pump unless the loop as gone cold // Flow is the following: // A) Sensor triggers start // Run the pump via relay 30 seconds // C) Wait for 20 minutes So the problems are 100% in the sensor side. The water flow sensor I have does trigger the IOLINC because the green LED on the IOLINC comes on. I can query the IOLINC when the sensor is on and the green LED is confirming the sensor is triggered (circuit is closed) and I always get this response: Sat 01/20/2018 01:54:04 AM : [ 44 34 81 1] ST 0 I don't see any issues with when I go into the extended communicates (level 3), but I am more a novice in that area. My reasons is that hops left never goes to zero from what I can tell. I can paste an excerpt if that would help. The fact that I query the IOLINC sensor manually and still get ST 0 is what has me concerned. So far I have used the restore device and then the factory reset with restore device and still no luck. Please help - I'm stuck! Edited January 20, 2018 by spyfish007 Link to comment
spyfish007 Posted January 20, 2018 Author Share Posted January 20, 2018 Well I think this is a signaling issue. If I short the sensor input to ground or use 100 ohm resistor, then I get ST 255 and DON signals on ISY. I measured my water flow sensor and the output is 2.2k, which is too high for sensor input. Looks like I need to make an add-on circuit to detect the 2.2k ohm and output a short. Link to comment
paulbates Posted January 20, 2018 Share Posted January 20, 2018 Hi and welcome to the UDI forums! What you're describing is a known problem with the io_linc and I've personally run into it I used x10 powerflash modules for years to sense my furnace runtime. I had power sensing doughnut sensors attached to the powerflash's leads. I attempted to use my first iolincs to replace the powerflash modules. No go. The iolinc's led would glow, but never contact. After a lot of help on another forum trying different sensors I gave up (I do this through my thermostat now) Hopefully you can find a way to convince the powerflash to register it I don't think you need the variable, BTW. Once the "switched on" is sensed by the program, you should be good. Paul Link to comment
kstock Posted January 20, 2018 Share Posted January 20, 2018 Well I think this is a signaling issue. If I short the sensor input to ground or use 100 ohm resistor, then I get ST 255 and DON signals on ISY. I measured my water flow sensor and the output is 2.2k, which is too high for sensor input. Looks like I need to make an add-on circuit to detect the 2.2k ohm and output a short. From a previous thread, the IOLinc triggers at about 800 ohms. Adding a 1000 ohm resistor in parallel to the circuit would bring the circuit resistance down to about 687 ohm when active, and would likely trigger the IOLinc. Link to comment
Brian H Posted January 20, 2018 Share Posted January 20, 2018 In my tests. Since the Green LED is on the sensor Input circuit. It can glow Green and still be not pulled down close enough to ground to trigger the sensor. Sounds like the water sensor may not pull it close enough to ground. I would also try the parallel resistor mentioned. The only thing is the Green LED may glow dimly even when the water sensor is not on. Link to comment
spyfish007 Posted January 21, 2018 Author Share Posted January 21, 2018 Thanks for the comments everyone. I wish they had put the green status LED after their internal detection circuitry. It gives off a false positive and I was looking in the wrong place - ISY traffic instead of input signal levels. I was also being lazy, so after I got over that and rolled up my sleeves I started figuring things out. I used my EE background, to develop a transistor circuit, because I never like the resistor in parallel trick. I used two resistors and a BJT - NPN transistor to solve the problem. If someone wants me to draw up the circuit, I can. I would have rather used a MOSFET, but I didn't have one hanging around. With respect to the variable in the program and the comment, would you please care to elaborate? My understanding was that the wait commands would retrigger the if statement for evaluation. My flow sensor may or may not still be detecting a hot water call at the time of re-evaluation (after the wait). I don't wish to exit out of the then statement, hence the variable. If the wait does not retrigger the if statement, I would not require the variable. Am I wrong the wait statement? Am I missing something else? I am new to programming in ISY and still getting my head around the structural changes from classic programming languages. Link to comment
oberkc Posted January 21, 2018 Share Posted January 21, 2018 If the wait does not retrigger the if statement, Waits do not retrigger the IF statement. Instead, waits allow a program to halt midway should the IF statement be retriggered by some other force. Link to comment
spyfish007 Posted January 21, 2018 Author Share Posted January 21, 2018 (edited) Waits do not retrigger the IF statement. Instead, waits allow a program to halt midway should the IF statement be retriggered by some other force. Ok so I think read part of the manual wrong. A series of statements within a Then clause (or within an Else clause), up to the next Wait or Repeat statement, are atomic. In other words, all such statements are executed before the conditions of the program are retested. The program's conditions are reevaluated each time a Wait or Repeat statement is encountered, and at the end of each iteration of a Repeat loop. I reread the manual based on your comment. I took it as the IF statement was re-evaluated for sure at the start of the wait. What you are saying is that program has the opportunity to evaluate the IF during the entire wait period. This behavior is certainly giving me issues. What I am seeking is a delay between operations and no allowed re-triggering of the IF condition. I literally want to run this pump for 30 seconds and then sit for 20 minutes regardless of the sensor. Said another way, I want to ignore the sensor for 20 minutes. I welcome help on how to achieve this with ISY programming. Edited January 21, 2018 by spyfish007 Link to comment
oberkc Posted January 21, 2018 Share Posted January 21, 2018 well, without getting into the variable discussion, or why (or if) your program is being retriggered, the simple solution is: If Control 'Mechanial Room / io.Hot H20 Control-Sensor' is switched On Or $v_hot_water_control is 1 Then run next program (then path) Next program: if nothing Then $v_hot_water_control = 1 $v_hot_water_calls += 1 Set 'Mechanial Room / io.Hot H20 Control-Relay' On Wait 30 seconds Set 'Mechanial Room / io.Hot H20 Control-Relay' Off Wait 20 minutes $v_hot_water_control = 0 $v_hot_water_calls Init To $v_hot_water_calls Else - No Actions - (To add one, press 'Action') Link to comment
spyfish007 Posted January 21, 2018 Author Share Posted January 21, 2018 well, without getting into the variable discussion, or why (or if) your program is being retriggered, the simple solution is: If Control 'Mechanial Room / io.Hot H20 Control-Sensor' is switched On Or $v_hot_water_control is 1 Then run next program (then path) Next program: if nothing Then $v_hot_water_control = 1 $v_hot_water_calls += 1 Set 'Mechanial Room / io.Hot H20 Control-Relay' On Wait 30 seconds Set 'Mechanial Room / io.Hot H20 Control-Relay' Off Wait 20 minutes $v_hot_water_control = 0 $v_hot_water_calls Init To $v_hot_water_calls Else - No Actions - (To add one, press 'Action') I tried this approach and the retriggering is the same as before. I did take your idea and modify it with a working solution. I am using the disable and enable functionality of a program. Hot Water Request - [iD 001A][Parent 0001] If Control 'Mechanial Room / io.Hot H20 Control-Sensor' is switched On Then Run Program 'Hot Water Run Pump' (Then Path) Else - No Actions - (To add one, press 'Action') New program just for running the pump. Hot Water Run Pump - [iD 001B][Parent 0001][Not Enabled] If - No Conditions - (To add one, press 'Schedule' or 'Condition') Then Disable Program 'Hot Water Request' $v_hot_water_calls += 1 Set 'Mechanical Room / io.Hot H20 Control-Relay' On Wait 30 seconds Set 'Mechanical Room / io.Hot H20 Control-Relay' Off Wait 20 minutes $v_hot_water_calls Init To $v_hot_water_calls Enable Program 'Hot Water Request' Else - No Actions - (To add one, press 'Action') // $v_hot_water_control is used to keep wait command from retriggering if condition // // * Goal is to no retrigger the pump unless the loop as gone cold // Flow is the following: // A) Sensor triggers start // Run the pump via relay 30 seconds // C) Wait for 20 minutes I think it now works. I might need a program to ensure the Hot Water Request program is enabled at start-up should something weird happen. Link to comment
oberkc Posted January 21, 2018 Share Posted January 21, 2018 I tried this approach and the retriggering is the same as before. Perhaps I was a little too quick to offer a solution. Yes, in retrospect, the first program would restart the second. It looks as if you have found a perfectly viable solution. As an alternative (and an exercise) you could also try: Hot Water Request - [iD 001A][Parent 0001] If Control 'Mechanial Room / io.Hot H20 Control-Sensor' is switched On and program 'Hot Water Run Pump' is false Then Run Program 'Hot Water Run Pump' (Then Path) Else - No Actions - (To add one, press 'Action') New program just for running the pump. Hot Water Run Pump - [iD 001B][Parent 0001][Not Enabled] If - No Conditions - (To add one, press 'Schedule' or 'Condition') Then $v_hot_water_calls += 1 Set 'Mechanical Room / io.Hot H20 Control-Relay' On Wait 30 seconds Set 'Mechanical Room / io.Hot H20 Control-Relay' Off Wait 20 minutes $v_hot_water_calls Init To $v_hot_water_calls Run Program 'Hot Water Request' (else path) Else - No Actions - (To add one, press 'Action') Link to comment
spyfish007 Posted January 22, 2018 Author Share Posted January 22, 2018 Perhaps I was a little too quick to offer a solution. Yes, in retrospect, the first program would restart the second. It looks as if you have found a perfectly viable solution. As an alternative (and an exercise) you could also try: Hot Water Request - [iD 001A][Parent 0001] If Control 'Mechanial Room / io.Hot H20 Control-Sensor' is switched On and program 'Hot Water Run Pump' is false Then Run Program 'Hot Water Run Pump' (Then Path) Else - No Actions - (To add one, press 'Action') New program just for running the pump. Hot Water Run Pump - [iD 001B][Parent 0001][Not Enabled] If - No Conditions - (To add one, press 'Schedule' or 'Condition') Then $v_hot_water_calls += 1 Set 'Mechanical Room / io.Hot H20 Control-Relay' On Wait 30 seconds Set 'Mechanical Room / io.Hot H20 Control-Relay' Off Wait 20 minutes $v_hot_water_calls Init To $v_hot_water_calls Run Program 'Hot Water Request' (else path) Else - No Actions - (To add one, press 'Action') Why would the run program ever come back false? There is nothing in the if condition. Link to comment
oberkc Posted January 22, 2018 Share Posted January 22, 2018 (edited) Why would the run program ever come back false? There is nothing in the if condition. Last line in the THEN section causes the ELSE PATH to run. (or at least that is what I intended with the last line.) Edited January 22, 2018 by oberkc Link to comment
Recommended Posts