Difference between revisions of "RF: Sending Signals + Arduino"

From ESE205 Wiki
Jump to: navigation, search
(Implementing Radio Frequency)
(Setting Up Circuit)
Line 6: Line 6:
 
* 2 LEDs<br />
 
* 2 LEDs<br />
 
== Setting Up Circuit ==
 
== Setting Up Circuit ==
After you obtain the parts, the first step to using radio frequency is to make sure your circuitry is correct. Here are images of the Pin Assignments for the Transmitter and the Receiver:
+
After you obtain the parts, the first step to using radio frequency is to make sure your circuitry is correct. <br />
Radio Transmitter: Attach the 'Data In' of the transmitter to pin 12 on the arduino and an LED powered by pin 11.<br />
+
 
 +
'''Radio Transmitter:''' Attach the 'Data In' of the transmitter to pin 12 on the arduino and an LED powered by pin 11.<br />
 
[[File:Rftransmitter.png|thumb|left]]<br />
 
[[File:Rftransmitter.png|thumb|left]]<br />
 
<br />
 
<br />
Line 18: Line 19:
  
  
Radio Receiver: Attach the linear out to pin 11 on the arduin and an LED powered by pin 13. Note that digital output is ignored in this example and can be utilized in further applications of radio frequency. <br />
+
'''Radio Receiver:''' Attach the linear out to pin 11 on the arduin and an LED powered by pin 13. Note that digital output is ignored in this example and can be utilized in further applications of radio frequency. <br />
 
[[File:Rfreceiver.png|thumb|left]]
 
[[File:Rfreceiver.png|thumb|left]]
 
<br />
 
<br />

Revision as of 17:16, 5 December 2017

Required Parts

  • RF Link Receiver - 4800bps (434MHz) [1]
  • RF Link Transmitter - 434MHz [2]
  • 2 Arduino Unos
  • 2 LEDs

Setting Up Circuit

After you obtain the parts, the first step to using radio frequency is to make sure your circuitry is correct.

Radio Transmitter: Attach the 'Data In' of the transmitter to pin 12 on the arduino and an LED powered by pin 11.

Rftransmitter.png










Radio Receiver: Attach the linear out to pin 11 on the arduin and an LED powered by pin 13. Note that digital output is ignored in this example and can be utilized in further applications of radio frequency.







Implementing Radio Frequency

For both the receiver and the transmitter, the ANT pin (antenna) can be a wire about 13 cm long to help the two communicate over a longer distance. Once you have the two wired correctly, it’s time to use them in code to send the signal you want. For this tutorial, a simple example using Arduino will suffice to help.

1.Download the VirtualWire library. Go to http://www.airspayce.com/mikem/arduino/VirtualWire/index.html and download the library into your Arduino IDE. To install, unzip the library into the libraries sub-directory of your Arduino application directory. Then launch the Arduino environment; you should see the library in the Sketch->Import Library menu, and example code in File->Sketchbook->Examples->VirtualWire menu.

2.Once you’ve downloaded the library, you can follow the given examples using the 'receiver' and 'transmitter' code.