Maker.io main logo

433MHz 4-Channels Wireless Switcher Circuit

2023-07-31 | By Hesam Moshiri

License: Attribution-NonCommercial-ShareAlike

433MHz/315MHz remote controls are everywhere around us, used to control devices such as turning ON/OFF the lights or a TV, or in applications such as opening/closing parking or villa entrance, … etc. Such remotes are available in the market in various shapes and sizes; however, most are equipped with four buttons. In this article/video, I introduce a full featured four channel wireless switcher device that can be paired with the majority of 433MHz or 315MHz wireless remotes in the market. The board can store up to 80 remote control buttons/codes (20 remotes with four buttons) in its EEPROM memory. You can easily record, delete, decode, and assign any individual remote-control button.

The board is compact and equipped with a small 2*8-character LCD, enhancing the user experience. Any remote-control button can be assigned to any of the four relays to activate and deactivate the devices. An ATMega8 microcontroller is the heart of the circuit. I used the Arduino IDE to develop the code. The most challenging part of this project was dealing with EEPROM memory. Eventually, I decided to use the structures to tackle it. Powering the board is as simple as connecting a 9V-1A power adapter.

For the schematic and PCB design, I utilized Altium Designer 23 and shared the project with my friends for feedback and edits using Altium-365's secure cloud space. I am confident that this circuit meets your requirements for a compact switcher board.

 

Specifications

Input Power: 9V-1A (DC)

Controlling Range: 30-60m (it varies by the condition)

Number of Relays: 4

Features: record/delete/decode/assign

Current consumption (max): 400mA (all Relays are ON)

Operation Frequency: 315MHz or 433MHz

 

Circuit Analysis

Figure 1 shows the schematic diagram of the 433MHz 4-Channels Wireless Switcher. As it is clear, the controller is an ATMega8-16PU chip [1].

433mhz ask switcher relay

Figure 1, schematic diagram of the 433MHz 4-Channels Wireless Switcher

 

A. Power Supply

I have decided to use two separate regulators to power the relays and MCU. REG2, an SMD L7805 regulator [2], is responsible for powering the relays, while REG1, a 78L05 SOT-89 SMD regulator [3], powers the MCU and the LCD. CON1 is used to connect a 9V-1A power adaptor to the board. FB1 [4], C9, and C10 are used to reduce the input noise. R7, C6, and C7 create a low-pass filter to further reduce the input noise to REG1. C8, C11, and C12 are used to stabilize the output voltage of the regulators.

 

B. Microcontroller

As mentioned earlier, the MCU used in this project is ATMega8 (U1). Y1 is an SMD 16MHz crystal [5] providing a clock source for the microcontroller. C4 and C5 are decoupling capacitors, and R6 is a pull-up resistor to prevent unwanted triggering of the RESET pin. ISP provides the necessary pins to connect your AVR ISP programmer to the board and flash the MCU.

 

C. ASK Receiver Module

To receive the transmitter remote control signals, we should naturally use an RF receiver module. Depending on the frequency of your remote controls, you should choose either a 315MHz or a 433MHz module. There are various modules available on the market that differ in quality and size. My selected module is RXB45, which is relatively cheap and easy to find. Occasionally, the module may receive some random codes; I'm not sure what the main root of this behavior is—whether it's the antenna or the quality of the module. However, since the switcher only reacts to the recorded codes, it is unlikely that this could cause a problem. Nevertheless, you can opt for other modules with higher quality. Figure 2 illustrates such a receiver module.

315mhz 433mhz ask receiver

Figure 2, A picture of the RXB45 433MHz receiver module

 

D. LCD

The LCD used in this project is an 8*2 display with a green backlight. Since D0 ... D4 pins of the LCD are not employed (4-bit), I implemented 4 pull-down resistors (R1 to R4) to prevent any potential instability. Figure 3 shows an image of the LCD used in this project.

lcd 8020 character

Figure 3, 8 (columns) * 2 (rows) character LCD.

 

E. Relays

The switcher has four relays, and all relay drivers are identical. Let's take a closer look at one of the relay drivers. K1 is an LM1-5D relay [6]. To protect the MOSFET and the rest of the circuit from reverse currents of the relay, I used the D2 diode (1N4007) [7]. Additionally, C13 is employed to damp relay noises. Q1 is a Si2302 [8] MOSFET used for driving the relay. To prevent any unwanted triggering of the gate pin of the Q1, R8 is included as a pull-down resistor.

 

F. Push Buttons

SW1 and SW2 are tactile push buttons to record or delete any remote-control key. R12 and R13 are pull-up resistors and C17 and C18 are used to debounce the push-buttons.

 

PCB Layout

Figure 4 shows the PCB layout of the device. It’s a two layers PCB board and I used a mixture of SMD and through-hole components to design the board. Figure 5 shows the assembly drawings.

pcb layout altium designer

Figure 4, PCB layout of the 433MHz 4-Channels Wireless Switcher Board

 

assembly drawing 433mhz receiver relay

Figure 5, Assembly drawings of the 433MHz 4-Channels Wireless Switcher Board

 

Code

You can download the compiled HEX file for the project from here [9]. Configure the Fuse Bits of the microcontroller for a high-frequency external crystal oscillator (16MHz), also, enable the CKOPT. The clock division fuse (CKDIV8) bit must be disabled (no clock division). Please watch the YouTube video completely, I have explained the code there.

 

Assembly and Test

Figure 6 shows the assembled PCB board. If you don’t have time, no access to the used components, or the competence to solder and build the PCB board yourself, you can order it assembled. In the YouTube video, I have explained how you can store/assign/delete any remote-control button from the memory and how you can work with the device, so I just skip that.

remote control switcher ask

Figure 6, Assembled PCB board of the 433MHz 4-Channels Wireless Switcher Board

 

Bill of Materials

Figure 7 illustrates the bill of materials (BOM) for the project.

BOM

Figure 7, Bill of materials

 

References

[1]: ATMega8-16PU: https://www.digikey.com/en/products/detail/microchip-technology/ATMEGA8-16PU/739787

[2]: L7805, TO-263: https://www.digikey.com/en/products/detail/stmicroelectronics/L7805ABD2T-TR/585694

[3]: 78L05, SOT-898: https://www.digikey.com/en/products/detail/texas-instruments/UA78L05ACPK/440626

[4]: Ferrite Bead: https://www.digikey.com/en/products/detail/BLM31PG121SN1L/490-1056-1-ND/584502

[5]: 16MHz Crystal

[6]: LM1-5D Relay

[7]: 1N4007, DO-214AC

[8]: Si2302 MOSFET: https://www.digikey.com/en/products/detail/SI2302CDS-T1-E3/SI2302CDS-T1-E3CT-ND/3305362

[9]: Compiled HEX File: https://drive.google.com/file/d/1wm8I2fo9fK3qfPuP2C78JVWS1taanHFh/view?usp=sharing

制造商零件编号 ATMEGA8-16PU
IC MCU 8BIT 8KB FLASH 28DIP
Microchip Technology
制造商零件编号 L7805ABD2T-TR
IC REG LINEAR 5V 1.5A D2PAK
STMicroelectronics
制造商零件编号 UA78L05ACPK
IC REG LINEAR 5V 100MA SOT89-3
Texas Instruments
制造商零件编号 BLM31PG121SN1L
FERRITE BEAD 120 OHM 1206 1LN
Murata Electronics
制造商零件编号 SI2302CDS-T1-E3
MOSFET N-CH 20V 2.6A SOT23-3
Vishay Siliconix
Add all DigiKey Parts to Cart
TechForum

Have questions or comments? Continue the conversation on TechForum, DigiKey's online community and technical resource.

Visit TechForum