Description:
RF modules are widely used for wireless data transfers and remote control applications. These days, cost of RF modules are very low and are compact in size. Most of these RF modules are operating around 433MHz. Amplitude Shift Keying (ASK) or Frequency Shift Keying (FSK) are mainly used for wireless data transfers.
Technical parameters of the transmitter head
Receiver module parameters:-
here a circuit example for interfacing RF module using HT12E/D encoder decoder pair. The circuit attached here can be used to transfer data using the RF module. As I have explained earlier RF module mentioned here is having a single channel. So we can use only serial data transfers. This example uses HT12E/D encoder-decoder pair for converting the parallel data to serial and back.
Note:
If you are looking into wireless communication between two Arduino modules, this project might be helpful. It uses low costs RF transmitter and receiver from Electronics-DIY.com to establish radio link between two Arduino boards up to 500 ft. Data can be transferred serially at the maximum rate of 2400 bps. The schematic shows how receiver and transmitter is hooked up to two different Arduino boards. When wiring the receiver / transmitter you only need to give them power / ground and then a pin for the TX (serial transmit) or RX (serial receive) pin. I also wired a button to the Arduino doing the transmitting, and used the LED on pin 13 that is built into my Arduino boards on the receiver so I could test this setup. The test app just flashes LED on the receiving board when a button is pressed on the transmitting board.
Kit include:
Mikroelectron Code:
Here is the full code for the main application
code 1 *
// Used Arduino 0017
// This is a simple test app for cheap RF transmitter and receiver hardware.
// 433MHz RF Transmitter: http://electronics-diy.com/product_details.php?pid=250
// 433MHz RF Receiver: http://electronics-diy.com/product_details.php?pid=251
//This says whether you are building the transmistor or reciever.
// Only one of these should be defined.
//#define TRANSMITTER
#define RECEIVER
// Arduino digital pins
#define BUTTON_PIN 2
#define LED_PIN 13
// Button hardware is setup so the button goes LOW when pressed
#define BUTTON_PRESSED LOW
#define BUTTON_NOT_PRESSED HIGH
void setup() {
pinMode(BUTTON_PIN, INPUT);
pinMode(LED_PIN, OUTPUT);
digitalWrite(LED_PIN, LOW);
Serial.begin(1200); // Hardware supports up to 2400, but 1200 gives longer range
}
#ifdef TRANSMITTER
void loop() {
static int prev_button = BUTTON_NOT_PRESSED; // Previous button press value
int cur_button; // Current button press value
cur_button = digitalRead(BUTTON_PIN);
if ((prev_button == BUTTON_NOT_PRESSED) && (cur_button == BUTTON_PRESSED)) {
writeUInt(271); // Put any number you want to send here (71 is just a test)
}
delay(50); // Debounce button
prev_button = cur_button;
}
#endif //TRANSMITTER
#ifdef RECEIVER
void loop() {
boolean light_led = false;
if (readUInt(true) == 271) // Check to see if we got the 71 test number
{
light_led = true;
}
if (light_led)
{
digitalWrite(LED_PIN, HIGH);
delay(1000);
digitalWrite(LED_PIN, LOW);
}
}
#endif //RECEIVER