Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Infrared Remote Control Decoder & Switcher Project

Infrared remote controllers are everywhere around us. The majority of home appliances are controlled using infrared remote controls. In this article/video, we learn to build a device that can decode (almost) any IR remote control and use the instructions to switch the relays (loads). So we can use this feature in a variety of applications without buying a new IR remote control and expensive hardware, such as turning ON/OFF the lights, opening/closing the curtains, ... etc. I have used an ATTiny85 microcontroller as the heart of the circuit. The device can record up to three IR codes in the EEPROM memory and switch 3 separate devices. Each relay can handle the currents up to 10A. The load switching mechanism (momentary ON/OFF, toggling, .. etc) can be programmed by the user.

I used Altium Designer 21.4.1 and the SamacSys component libraries (SamacSys Altium Plugin) to design the Schematic and PCB. I also used the Siglent SDS2102X Plus/SDS1104X-E to analyze the IR signals.

The device works stable and reacts well to the transmitted IR signals. So let’s get started and build this puppy!


3uJE3Yy




2SR1vFQ



References

Original Article: https://bit.ly/3vNcEGa

[1]: Altium Designer electronic design CAD software: https://www.altium.com/altium-designer

[2]: SamacSys Altium plugin: https://www.samacsys.com/altium-designer-library-instructions

[3]: ATTiny85 schematic symbol, PCB footprint, 3D model: https://componentsearchengine.com/part-view/ATTINY85-20SUR/Microchip

[4]: TS2937-5.0 schematic symbol, PCB footprint, 3D model: https://componentsearchengine.com/part-view/TS2937CW-5.0 RP/Taiwan Semiconductor

[5]: L7805 schematic symbol, PCB footprint, 3D model: https://componentsearchengine.com/part-view/L7805CV/STMicroelectronics

[6]: SI2302 schematic symbol, PCB footprint, 3D model: https://componentsearchengine.com/part-view/SI2302DDS-T1-GE3/Vishay

[7]: FDN360P schematic symbol, PCB footprint, 3D model: https://componentsearchengine.com/part-view/FDN360P/ON Semiconductor

[8]: Siglent SDS2102X Plus oscilloscope: https://siglentna.com/products/digital-oscilloscope/sds2000xp-series-digital-phosphor-oscilloscope

[9]: Siglent SDS1104X-E oscilloscope: https://siglentna.com/digital-oscilloscopes/sds1000x-e-series-super-phosphor-oscilloscopes
 

KlausST

Super Moderator
Staff member
Joined
Apr 17, 2014
Messages
19,989
Helped
4,373
Reputation
8,755
Reaction score
4,359
Trophy points
1,393
Activity points
132,306
Hi,

The clearance between relay contact traces and control circuit seems not enough for line voltage.
Did you follow clearance and creepage distance rules?

Klaus
 

Hesambook

Member level 4
Joined
Sep 26, 2007
Messages
78
Helped
1
Reputation
4
Reaction score
5
Trophy points
1,288
Activity points
2,326
Hi,

The clearance between relay contact traces and control circuit seems not enough for line voltage.
Did you follow clearance and creepage distance rules?

Klaus

I agree that the creepage can be increased, however, the distance is enough to satisfy the requirement. As a rule of thumb, 1.6kv/mm or 40V/mil should be the minimum creepage (UL796 Standard)
 

KlausST

Super Moderator
Staff member
Joined
Apr 17, 2014
Messages
19,989
Helped
4,373
Reputation
8,755
Reaction score
4,359
Trophy points
1,393
Activity points
132,306
Hi,

I guess you looked at the "functional isolation", but you need to apply "safety isolation".

Just to clarify: If somebody gets hurt or dies because you did not apply the correct value, you are reponsible for that.

Klaus
 

Hesambook

Member level 4
Joined
Sep 26, 2007
Messages
78
Helped
1
Reputation
4
Reaction score
5
Trophy points
1,288
Activity points
2,326
Hi,

I guess you looked at the "functional isolation", but you need to apply "safety isolation".

Just to clarify: If somebody gets hurt or dies because you did not apply the correct value, you are reponsible for that.

Klaus

Don't worry, that mostly applies to SMPS designs with high voltage/transient peaks. Also, the distance between mains contacts is huge and more than enough.
 

FvM

Super Moderator
Staff member
Joined
Jan 22, 2008
Messages
48,527
Helped
14,273
Reputation
28,809
Reaction score
12,977
Trophy points
1,393
Location
Bochum, Germany
Activity points
280,640
If the control circuit is accessible to the user (e.g. connected to your computer by the programming interface), it must provide double or reinforced insulation to the mains circuit. The required PCB creepage distance for 230 VAC (150 - 300 V phase to neutral) is 3 mm (e.g. according to IEC 1010, similar requirements in other standards), respectively the design won't pass a safety approval.
 

Hesambook

Member level 4
Joined
Sep 26, 2007
Messages
78
Helped
1
Reputation
4
Reaction score
5
Trophy points
1,288
Activity points
2,326
If the control circuit is accessible to the user (e.g. connected to your computer by the programming interface), it must provide double or reinforced insulation to the mains circuit. The required PCB creepage distance for 230 VAC (150 - 300 V phase to neutral) is 3 mm (e.g. according to IEC 1010, similar requirements in other standards), respectively the design won't pass a safety approval.

Where is the neutral line here?!!
 
Last edited:

KlausST

Super Moderator
Staff member
Joined
Apr 17, 2014
Messages
19,989
Helped
4,373
Reputation
8,755
Reaction score
4,359
Trophy points
1,393
Activity points
132,306
Hi,

safety regulations don´t care whether you switch phase or neutral ... in any case you have to follow the same clearance and creepage distance values.

The regulations usually take the phase-to-neutral-voltage for determine minimum distance values.

Klaus
 

Hesambook

Member level 4
Joined
Sep 26, 2007
Messages
78
Helped
1
Reputation
4
Reaction score
5
Trophy points
1,288
Activity points
2,326
Hi,

safety regulations don´t care whether you switch phase or neutral ... in any case you have to follow the same clearance and creepage distance values.

The regulations usually take the phase-to-neutral-voltage for determine minimum distance values.

Klaus

This is the whole standard. As I said before I followed the UL table. You can follow what you like in your own design.

pcbtracespacing.png
 

KlausST

Super Moderator
Staff member
Joined
Apr 17, 2014
Messages
19,989
Helped
4,373
Reputation
8,755
Reaction score
4,359
Trophy points
1,393
Activity points
132,306
Hi,

I agree that you follow UL table.
This is the whole standard. As I said before I followed the UL table. You can follow what you like in your own design.

Maybe I'm wrong. What I see: The minimum distance on your PCB is somewhere between 1.5 and 2.0 mm
Post#1, blue layer, smallest distance relay center contact copper trace to copper area.
According the regulations and the tables this maybe is sufficient for functional isolation.

But we talk about two isolated nets.
Two isolated nets sometimes are named as primary and secondary.
Here you need to prevent from electric shock, (safety isolation) apply the rules for "reinforced isolation",.
Some rules say you need to double the table values.
Please confirm that you understood the regulations and designed the PCB according reinforced isolation rules.

Klaus

It's not my intention to cause problems, but to prevent you from problems.
 

LaTeX Commands Quick-Menu:

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Top