Go Down

Topic: Final Year Project - control 10 aircons with Arduino (Read 1 time) previous topic - next topic

thank you all for the suggestions, i am still going through them

@PeterH & @CrossRoads for proposing the use of a Mega.
referring to (http://www.righto.com/2009/08/multi-protocol-infrared-remote-library.html)
Ken Shirriff: "My code won't work with an Arduino mega as it has a different processor and the pins are all different. (Sorry I didn't mention that in my original article.)"

However if sending IR with pin9 of Mega was/is possible, would it make sense to
1) have pin9 connected to multiple IR LED Anodes/+ve legs and
2)the Cathodes/-ve legs of the IR LEDs connected to their own individual digital pin, and control each individual IR LED by switching the corresponding pin "HIGH" or "LOW".?

CrossRoads

https://github.com/shirriff/Arduino-IRremote/blob/master/IRremoteInt.h

* Modified by Paul Stoffregen <paul@pjrc.com> to support other boards and timers
Quote

1) have pin9 connected to multiple IR LED Anodes/+ve legs and
2)the Cathodes/-ve legs of the IR LEDs connected to their own individual digital pin, and control each individual IR LED by switching the corresponding pin "HIGH" or "LOW".?

This would add quite a capacitive load to the driving pin as you are having the IR LEDs also connected via long wires.
I would use an external driver to drive the ganged up anodes.
Designing & building electrical circuits for over 25 years.  Screw Shield for Mega/Due/Uno,  Bobuino with ATMega1284P, & other '328P & '1284P creations & offerings at  my website.

thanks for the help. i have now successfully tested the IR over 30Meters cat5 cable and it works OK, for now.  before i start with final installation i need to pick up motion(high) and no motion(low) with ardiono using PIR motion detector (with 7 terminals not 3).
(http://www.thecrowgroup.com/Products_Systems/swan_quad/swan_quad/)

when using multi-meter and motion is detected (LED on motion detector goes on) i measure Open Cct (infinite resistance) on the 2 "RELAY" terminals & measure approx 40 Ohm when no motion is detected (LED on motion detector goes off) on 2 RELAY terminals.

does anyone know how can i use this Open Cct /40 Ohm to easily pick up (differentiate) high/ low on adrino digital input?

PS: detector has the following 7 terminals and i use external power (9V):
1) "-V"; 2) "+V"; 3&4) "two x TAMP";  5) "EOL"; 6&7) "two x RELAY".

Paul__B


does anyone know how can i use this Open Cct /40 Ohm to easily pick up (differentiate) high/ low on adrino digital input?


Yes, you would connect the two terminals to ground and an Arduino input, and in the program set the internal pull-up.

Then monitor the input to see whether the relay was open (logic high) or closed (logic low).

hi all who contributed,
thanks for all the replies as i could not have done it without you guys.
managed to get my degree (finally).
regards,

Go Up