Moderated by: ident |
Author | Post | |||||||||
---|---|---|---|---|---|---|---|---|---|---|
david8811 Member
|
http://www.arduinostarterskit.com/sale-7641832-lightweight-four-channel-relay-module-for-arduino-red-board.html I am trying to wire up my Comfort Output to my 4 channels Relay to switch on the light in the event of PIR is being activated. Refer to above link for details of my 10A 250V relay. How do I connect the output and 12v from Comfort panel to the relay input? Q1 Is it correct to connect the 12V of the Output to DC+ of the relay module? Q2 then connect the OP1 of the Ouput to IN1(Input 1 ) of the relay? And accordingly OP2 to IN2 and so on? Q3 How about the DC- of the relay? Where to connect to or leave it unconnected? Would appreciate your support and sharing. Last edited on Monday Nov 19th, 2018 05:04 am by david8811 |
|||||||||
Swiss-Toni UCM Pi Users
|
Last edited on Monday Nov 19th, 2018 06:11 am by Swiss-Toni |
|||||||||
slychiu Administrator
|
I would guesss that you need to set low level trigger option and connect Comfort Output to the trigger inputThen connect 12V to positive wireBut that is only a guess |
|||||||||
david8811 Member
|
May I know why you suggested Low level trigger setting? Was it because Comfort output is designed for Low level trigger? Another way to put it. Is Comfort output Control signal is programmed/set to Low level trigger or to activated at 0 / false / ground, when an output signal is generated ( in my case ,PIR is activated)? Last edited on Tuesday Nov 20th, 2018 06:08 am by david8811 |
|||||||||
slychiu Administrator
|
The Comfort Output is an Open-collector transistor output. That means that when not activated the output is floating.When an Output is turned on, the Comfort Output will go to a low level, thus supplying 12V between 12V and Common. Hence it is activve low level This is designed to drive 12V relaysIf you were using the RLY01, yiu would not have this problem. The outputs can be coonnected direct to the relay inputs pin for pin |
|||||||||
david8811 Member
|
Thank you for your response. I read in another blog, the DC- terminal is supposed to be connected to the Arduino panel Ground terminal. In my case, which one is the “Ground†terminal of Comfort panel? See the link here https://blog.siliconstraits.vn/relay-what-is-it-and-how-to-use-it/ Last edited on Tuesday Nov 27th, 2018 10:58 pm by david8811 |
|||||||||
slychiu Administrator
|
The Ground can be found in Comfort 12V/COM/S12V centre terminal |
|||||||||
david8811 Member
|
I just tested my relay by connecting the DC+ and DC- of the relay to the +ve and -ve poles of my 12V 20A 240W (18 channels) DC external power supply. Set the Relay to Low Level Trigger. Then I connected the relay output 1 to a light bulb with external 240V AC power supply. When I connected (jumped) the Relay Input 1 to DC- terminal of the Relay, the Relay activated and the light on. Now, I intended to power up my Relay using external power supply to reduce the loads to my Comfort system power supply. To do this, I connect my Relay DC+ and DC- to the +ve and -ve poles of my 12V 20A 240W (18 channels) DC external power supply. Similarly, the Relay ouput1 to a light bulb with 240V AC power supply. To enable Comfort system to activate the Relay and switch on the light when my PIR sensor is activated, I will connect my Relay Input 1 to my my Comfort OP1 (Output1) terminal. Leave the 12V “free†unconnected as my Relay is drawing power from the external DC supply as explained above. Q1 . Will this configuration work? If yes, Do I have to connect my Comfort system Ground (COM) to the -ve pole of my external 12V 20A 240W (18 channels) DC external power supply to create a common ground? PS : The 12V 20A 240W (18 channels) DC external power supply is also used to power up 8 units of my NVR cameras Last edited on Wednesday Nov 28th, 2018 02:56 am by david8811 |
|||||||||
slychiu Administrator
|
Yes you need to connect the ground of the power supply to the ground for Comfort (centre of 12V/COM/S12V terminal) |
|||||||||
david8811 Member
|
Mr Chiu, http://www.cytech.biz/temp/appman.pdf I am trying to set up the project : Switch on a light when movement is detected at night as per above link example 1.4. ( This example used OP5, I changed the programming from OP5 to OP3) I tested the circuit as per your suggestion, Unfortunately it didn’t work. Then, I reconnected the Relay power supply directly to Comfort panel, which is DC+ to 12V between OP3 and OP4. The DC- to COM between S12V and 12V. With DC+ and DC- connected, the Relay green LED on indicate power on. When I connected the Relay Input IN3 to Comfort OP3, the Relay immediately activated and the light connected to the Relay output was lighted up. The Relay activated without the PIR being activated. Furthermore, the Relay continued activated and failed to switch off despite this project Response is programmed to 5 minutes. When I disconnected the IN3 cable from Relay to OP3, the Relay deactivated, but the Relay remained power on. When I reconnected the IN3 cable to OP3, the Relay activated again, light on and failed to switch off. Despite PIR is not even activated. I also tested the above based on Zone type 5 and 24. Same result. Zone type 8 ( despite the example used zone type 8) cannot be used as it caused F32 to announce the zone. Would appreciate if you could help to address my problem. Last edited on Tuesday Dec 11th, 2018 03:09 am by david8811 |
|||||||||
slychiu Administrator
|
It is very difficult to check what you have done without a cclx file The Output 3 may be On but you may have some other event which causes it to turn on we also cannot verify that you have programmed correctly There is also the problem whether your connection of the relay to the light is correct the Relay deactivated, but the Relay remained power on. When I reconnected the IN3 cable to OP3, the Relay activated again, light on and failed to switch off. "relay deactivated but relay remain power on " does not make sense we cannot advise properly, I suggest you get an electrician to help. Last edited on Tuesday Dec 11th, 2018 05:17 am by slychiu |
|||||||||
John W UCM Pi Users
|
David, break it down into two parts: the comfort config, and relay wiring. To check you have got the comfort output switching properly you can stick a meter between the output and 0v, or better still an led between 12v and the output with a resistor to current limit it. e.g. https://www.laser.com/product_info.php/item/LP01-Comfort_Test_Lamps_12v/cPath/96_162/products_id/930 That will prove you have the output switching on when you want it to. If you are using Comfigurator you can actually watch the output status change, so you can see if it is on or off easily. Wiring wise, The relay board you are using has configurable switch inputs using the jumpers. Have you got them set for triggering high or low ? Will it accept an open collector 'input', and does it have an integral pull-up resistor to pull the input high itself, or does it need an external one. I would test it as follows: This assumes using 3rd relay/channel being used. Mains side: live feed to 'comm3', output to light to 'NO3' (normally open). DC Side: DC+ to positive supply, DC- to negative supply. With nothing connected to the input, turn the DC power on. Does the relay close or not ? Ideally it shouldn't do. Set the jumper to trigger low. Connect a wire to 'IN3' and connect it to DC-. This should turn the output on. If it has internal pull-ups when you disconnect the wire from DC- it should turn off. If you find this doesn't happen reliably it probably means the input is floating (no pull-up) and needs say a 10k ohm resistor between IN3 and DC+ to pull it high. ---- To connect to the comfort panel: DC+ to positive supply (12v on comfort pcb), DC- to negative supply (comm next to it). Comfort OP3 to the relay board IP3. I hope that is of some help. |
|||||||||
david8811 Member
|
Hi John, Thank you for your response. My wiring circuit is exactly what you suggested. I also did the test you suggested i.e connect and disconnect IN3 with DC-, the Relay was activated and deactivated accordingly. It concluded that Relay is working perfectly. Objective: Comfort turn on light ( connected to OP3) if the time is between 7 pm to 6am. The light will be turned off after 5 minutes if no further movement is detected. Similar to the example 1.4 of application manual. Refer the link above. I had actually at the next stage of the problem. I have wired my PIR to zone 17 with zone type 24 with Response 45 On. Response 45 action codes are as follow:- 73, 3, 69, 19, 70, 6, 193, 74, 5, 194, 1, 1, 44, 6, 255. To test it, I changed my Comfort system time to 8pm. When I walked past the PIR, the PIR activated the relay and the light switched on. The problem is, the Relay and of course the light would not deactivated or switches off after 5 minutes. I changed Response 45 5 minutes interval time to 5 seconds with Action Code 73, 3, 69, 19, 70, 6, 193, 74, 5, 194, 1, 0, 5, 6, 255. Similar result as above. It can only be turned off when I reset the Comfort system reset button. It appaeared that Response 6 to turn off Output 3 is not activated. When I measured the volatage across DC+ and IN3, the voltage remain 12V. I am using Comfort 2 system whereas the example in 1.4 of Application.manual is for Comfort 1. Not sure they are compatible. I read in Action Codes manual page 60, couldn’t find any issue so far. Would appreciate your help. Last edited on Wednesday Dec 12th, 2018 03:21 am by david8811 |
|||||||||
slychiu Administrator
|
your Response 6 is supposed to turn off the output You need to check what is response 6 action Do you have Comfort 2 Optimum or Ultra? Last edited on Wednesday Dec 12th, 2018 06:54 am by slychiu |
|||||||||
david8811 Member
|
Response 6 Action codes is default setting, which are 128, 3, 0, 255. I just reconfirmed the action codes for Response 6 a while ago. My Comfort System Control Number obtained from Engineer Menu 743 is 743361. Not sure it is Ultra or Optimum Last edited on Wednesday Dec 12th, 2018 10:46 am by david8811 |
|||||||||
slychiu Administrator
|
If you have programmed everything correctly then it should work We are not able to check for you as you are not able to save the cclx file so you wil have to check all the responses yourself, with a good understanding of actions and responses Check the action codes manual as a start http://www.cytech.biz/action_codes_reference.html make a control menu to turn on and off the output |
|||||||||
david8811 Member
|
For Comfort Ultra 194, 01, 00, 05, 107, 03 Start Timer 1, count = 5 seconds, and Do Response 875 (3 x 256 + 107) Above statement is from Comfort Action Codes Manual, page 60. It says For Comfort Ultra, .....What is the last action code 03 means? There are 6 action codes here compared to mine is only 5 action codes. Could it be I missed something here as my Comfort is ultra I Guess. |
|||||||||
slychiu Administrator
|
Action Code: 194 Parameter 1: Timer 1 to max Parameter 2: timer count high byte - Seconds/256 (0 to 254) 66 Parameter 3: timer count low byte - remainder Seconds (0 to 254) Parameter 4: Response 00 to 255 Parameter 5: Response High Byte for Comfort Ultra only. The Timer value in seconds is entered in action codes 3 and 4 (16-bit value) 194, 01, 00, 05, 107, 03 Start Timer 1, count = 5 secondResponse = 3 x 256 + 107 = ??? |
|||||||||
david8811 Member
|
Hi Chiu, Q1 Can you explain to me the difference between timer 1, 2 or 3? Are these timers need to be preprogrammed? Q2 From Action Codes Manual, Page 60. “Avoid 255 in the Response high byte and low byte as this will terminate the Response entry.†What is that means? Last edited on Thursday Dec 13th, 2018 03:28 am by david8811 |
|||||||||
slychiu Administrator
|
Please see this topic about timers http://www.comfortforums.com/forum92/4062.html |
|||||||||
david8811 Member
|
Hi Mr Chiu, Thank you for your response. I am using Engineer Menu Programming, the link you sent seemed to be not addressing my questions. To diagnose why Response 6 is not activated, I decided to carry out a test without the Start Timer Response 194 code, but added in action code 116 to played warning message. So I changed Response 45 from 73, 3, 69, 19, 70, 6, 193, 74, 5, 194, 1, 0, 5, 6, 255. To 73, 3, 69, 19, 70, 6, 193, 74, 5, 74, 116, 74, 6, 255. Step 1 - When I walked past the PIR, the PIR triggered and it’s LED activated, Relay activated, Bulb lighted up, warning message played on keypad, but bulb didn’t turn OFF. Step 2 - When I walked backwards to trigger the PIR again, the Relay deactivated, warning message played again on keypad, bulb turn OFF. Then, I walked past PIR again, Step 1 repeated. If I walk backwards to trigger the PIR again, step 2 repeated. It seemed that Output 3 requires Retriggering of PIR to activate Responses 5 and 6 alternately. Why is it behaving this way? Strangely, Step 2 wouldn’t happen to Response 45 with original codes of 73, 3, 69, 19, 70, 6, 193, 74, 5, 194, 1, 0, 5, 6, 255. Last edited on Thursday Dec 13th, 2018 11:40 pm by david8811 |
|||||||||
david8811 Member
|
Hi Mr Chiu, I changed and repositioned Response 45 Action Codes by including Start Timer Action Code 190 for 10 seconds before Keypad plays warning message and switch OFF Output 3. Thus, Response 45 was revised from 73, 3, 69, 19, 70, 6, 193, 74, 5, 74, 116, 74, 6, 255. To 73, 3, 69, 19, 70, 6, 193, 74, 5, 190, 0, 10, 74, 116, 74, 6, 255. When I walked past PIR, Relay was activated, bulb lighted up, but NO warning message played on keypad and Response 6 to switch OFF output 3 was not activated too. This test concluded that the system is unable to execute Start Timer Action Codes, Both 190 and 194. Appreciate if you could advise the solution to this problem. |
|||||||||
slychiu Administrator
|
Your problem is that your actions are wrong 73,3, 142,10,19, 143,7,6, 193, 74,5, 74,116, 74,6, 255means If Hours < 19 Then If Hours >= 6 Then Exit Response Do Output3ON Do Reminder8OnKeypa Do Output3OFF End If End If Exit response ends the response so the following actions have no effect If what you want is If Hours < 19 Then If Hours >= 6 Then Do Output3ON Do Reminder8OnKeypa Wait 1 Seconds Using Timer01 Do Output3OFF End If End If The actions are73,3, 142,13,19, 143,10,6, 74,5, 74,116, 190,1,0,1, 74,6, 255 The 2nd set of actions73, 3, 69, 19, 70, 6, 193, 74, 5, 190, 0, 10, 74, 116, 74, 6, 255 Is also wrong action 190 should be190, timer#, timerhi, timerloyou may have wanted 190,1,0,10, NOT 190,0,10 That is the problem with trying to write raw action codes. you need to have a good knowledge of the actions These errors would not have happened using Comfigurator Last edited on Friday Dec 14th, 2018 04:41 am by slychiu |
|||||||||
david8811 Member
|
Thank you Mr. Chiu, This new Action Codes 73,3, 142,13,19, 143,10,6, 74,5, 74,116, 190,1,0,1, 74,6, 255 that you suggested didn’t activate any actions at all. Then I tried my earlier Action Codes with correction on the Timer Number that I missed out. and brought foraward Response 116 before Start Timer 190. Here is the Action Codes 73, 3, 69, 19, 70, 6, 193, 74, 5, 74, 116, 190, 1, 0, 10, 74, 116, 74, 6, 255 Step 1- When tested, it triggered the Relay, bulb lighted up and warning message played on keypad, but it didn’t switch OFF Output 3. Step 2- When I walked backwards to retrigger the PIR, then it replayed the warning message and switched OFF output 3 and the bulb. Step 1 and 2 can be repeated to switch On and Off the light. Why the Timer function is not responding? Last edited on Saturday Dec 15th, 2018 12:56 am by david8811 |
|||||||||
slychiu Administrator
|
I still do not know what firmware you haveYou may have Optimum which has different actions Take a photo of the Main Board. check the label on the IC which says "ULT" or "OPT" If we do not know this then and do not have a cclx time we are wasting time |
|||||||||
david8811 Member
|
My system is ULT , 7,xxx |
|||||||||
slychiu Administrator
|
There is something that you have programmed wrongly or reported inaccurately or missed out It is not possible for us to help from here You will need to go through all your responses and actions and find out exactly what each action means, and check all the called response numbers. If you had UCM you could send the cclx file and we could analyse it. but if you program by keypad we cannot help much |
|||||||||
david8811 Member
|
What is teh difference of using Timer No. 1 or 2 or 3 in a Start Timer Action Codes? |
|||||||||
slychiu Administrator
|
You can use any timer.There is no difference between timers Just use one timer for 1 function Do not use the same timer for different functions see http://www.comfortforums.com/view_topic.php?id=4062&forum_id=92 for fuller explanation Timers are a well established function and have been used in many installations for 20 years. There is no problem with operation of timers if the actions are coded correctly Last edited on Saturday Dec 15th, 2018 06:50 am by slychiu |