How to turn on lights with apc220 radio frequency modules and arduino mini pro

In this tutorial we will use the radio frequency modules apc220 and arduino mini pro, to turn on lights or any other device, at a distance of up to one kilometer. This project is ideal for controlling devices, where there is no possibility of having internet to control them.

Plates and modules used in this project

Arduino mini pro

The Arduino Pro Mini is a microcontroller board based on the ATmega328.
It has 14 digital input/output pins (of which 6 can be used as PWM outputs), 6 analog inputs, an integrated resonator, a reset button and holes to mount pin headers. A six-pin header can be connected to an FTDI cable or Sparkfun connection board to provide USB power and communication to the board.
The Arduino Pro Mini is designed for semi-permanent installation in objects or exhibitions. The board comes without pre-assembled headers, allowing the use of various types of connectors or direct cable welding. The pin design is compatible with the Arduino Mini.
There are two versions of the Pro Mini. One runs at 3.3V and 8 MHz, the other at 5V and 16 MHz.

Microcontroller ATmega328 *
Board power supply 3.35-12 V (3.3 V model) or 5-12 V (5 V model)
Circuit operating voltage 3.3V or 5V (depending on model)
Digital I/O Pins 14
PWM pins 6 6
Uart 1
Spi 1
I2c 1
Analog input pins 6 6
External outages 2
DC current per I/O pin 40 mA
Flash memory 32 KB of which 2 KB used by the bootloader *
Sram 2 KB *
Eeprom 1 KB *
Clock speed 8 MHz (3.3V versions) or 16 MHz (5V versions)

Module Apc220

The APC220 radio data module is a highly versatile, high-power radio solution that is easy to set up and integrate into any project that requires a wireless RF link. It is perfect for robotic applications if you need wireless control. You can connect one of these modules to your MCU via the TTL interface, and connect to your PC with another APC220 module via a TTL/USB converter.

Specification

  • Working frequency: 420 MHz to 450 MHz
  • Power: 3.5-5.5V
  • Current: <25-35mA
  • Working temperature: -20oC + 70oC
  • Range: 1200 m line of sight (1200 bps)
  • Interface: UART/ TTL
  • Transmission speed: 1200-19200 bps
  • Transmission speed (air): 1200-19200 bps
  • Receive buffer: 256 bytes
  • Size: 37mm × 17mm × 6.6mm
  • Weight: 30g

You may be interested in projects in Arduino, pic, robotics, telecommunications, subscribe http://www.youtube.com/user/carlosvolt?sub_confirmation=1 videos with full source code and diagrams

SUSCRIBETE A NUESTRO CANAL DE YOUTUBE, TUTORIALES GRATIS

Pinout

Pin Definition Detail
1 Set Set parameters (low)
2 Aux UART signal- Transmission (low) Transmission (high)
3 Txd UART TX
4 Rxd UART RX
5 Is Turn off the device when you apply <0.5 V. Enable the device when you leave it offline or apply > 1.6 V
6 Vdc 3.3V-5.5V power
7 Gnd Earth 0V

Download RF-Magic

APC22X_V12A

Datasheet

APC220_Datasheet

Run APC22X_V12A.exe (RF-Magic) as an administrator if your system is not Windows XP.

NOTE: In the software you will recognize the APC220 module and COMX serial port automatically once we open it. Check in Device Manager to verify the correct COM port.

Configure RF-magic as in the red square frame below (default setting), and click Write W to enter your settings, then click Read R to read the parameters you have set.

Configuration

Writing and reading settings

Parameter Range Default
RF frequency 1KHz resolution, 100Hz ± accuracy 434MHz
TRx RF Rate 1200, 2400, 4800, 9600, 19200 bps 9600bps
RF power 0-9 9
Serial rate 1200, 2400, 4800, 9600, 19200, 38400, 57600bps 9600bps
NET ID 0-65535 (16-bit) 12345
NODE ID 123456789012
Patity Series Disable, the strange Patity, even Patity Disable

Configure the other APC220 module in the same way, with the same parameter settings.

8-channel Relay rele module

  • Operating Voltage: 5V DC
  • Control Signal: TTL (3.3V or 5V)
  • Number of Relays (channels): 8 CH
  • Max capacity: 10A/250VAC, 10A/30VDC
  • Max current: 10A (NO), 5A (NC)
  • Action time: 10 ms/5 ms
  • To activate output NO: 0 Volts

Emitting control circuit

The emitting circuit consists of the acp220 module, an Arduino mini pro and 8 Tact Switch type pushbuttons.

The apc220 can power them with 3.3 to 5.5 volts, this version of arduino mini pro is 5 volts so we will power the whole circuit with that voltage.

The Arduino transmitter pin must be connected to the receiver pin of the apc220 module, and vice versa, so that they can communicate with each other.

Source code issuing control

Receiver circuit with relay module

 

The receiver circuit also has an apc220 module and an Arduino mini pro, replaces the 8 pushbuttons with an 8-channel relay module for the control of the lights or any other device, 110/220 volts.

CAUTION: THIS MODULE WORKS WITH VERY DANGEROUS AC VOLTAGES, WHICH CAN CAUSE ELECTROCUTION AND VERY POSSIBLE DEATH, IF THE NECESSARY SAFETY MEASURES ARE NOT TAKEN. IF YOU HAVE NEVER WORKED WITH SUCH MODULES SEEK ADVICE FROM A QUALIFIED PROFESSIONAL, WE ARE NOT RESPONSIBLE FOR ANY DAMAGES YOU MAY SUFFER.

 

Receiver source code with relay module

Sample of the light-on system


SUBSCRIBE TO OUR NEWSLETTERS, RECEIVE IN YOUR EMAIL THE MOST OUTSTANDING NEWS, JUST BY ENTERING YOUR EMAIL

[wysija_form id=”1″]



RECOMMENDED PROJECT

Deja una respuesta