Simple RF

Heya, thought I would start a new thread as this could be helpful for everyone looking at the same stuff;

http://www.jamiewilson.co.nz/wp-content/gallery/class/schematic.png

How easy / hard is it to send and receive data using these: from seeedstudio http://www.seeedstudio.com/depot/433mhz-rf-link-kit-p-127.html

I would make two of these exactly the same.

I want to be able to output onto the screen if there is another arduino close, and what strength the signal is. The arduino will be outputting it’s ID. Ie, on the screen “ID: 01; ST: 100%;”

Cheers :slight_smile:

How easy / hard is it to send and receive data using these: from seeedstudio

I don’t know but we really need someone to try them with the VirtualWire library so we know if it works with it or not. :slight_smile:

–Phil.

I have a pair of these but have not got round to testing them yet, if no one has posted here by the time I do I’ll let you know what I find.

out of interest - will virtualWire work for arduino-Pc rf communication? or is it just for ard-ard comms

So have tested them to a point, and they appear to be working. Well as far as i can tell.

The receiver picks up EVERYTHING no matter what baud rate you set it to, i have posted this issue in a separate thread under Hardware Interfacing as well.

But they seem to be very very simple to connect up and very easy to programme, I am staying away from VirtualWire because it appears to suck quite a lot, and you don’t seem to gain much from using it… The tutorial for Sparkfun works as far as I can tell for now:

Will keep you updated if anything arises from this

I am staying away from VirtualWire because it appears to suck quite a lot, and you don’t seem to gain much from using it.

What gives you that impression?

My understanding was VirtualWire provides reliable communications due to its use of error correction and signal balancing. Sans one IDE issue VirtualWire worked well out of the box and is extremely well documented.

Thus, I’m intrigued how you arrived at your assessment of VirtualWire.

–Phil.

It just seemed to fail from the outset. I’ll give it another go :slight_smile: - But in the first instance, this code:

#include <VirtualWire.h>
int LED = 13;
int counter = 0;

void setup()
{
vw_setup(2000); //Bits per sec
pinMode(LED, OUTPUT);

}

void loop()
{
digitalWrite(LED, HIGH);
delay(1000);
digitalWrite(LED, LOW);
delay(1000);
}

Doesn’t execute, the light should flash. Basically anything after vw_setup(2000); fails. Any ideas why?

Did you get any compilation errors?

Did you try the sample code?

Did you connect it as per the docs?

If it doesn’t get past that point it may well not being compatible.

–Phil.

No compilation errors,

This is the sample code (more or less),

Connected as per the dots.

Damn. - In another thread someone suggested it could be not enough power - could that be the case with the transmitter? Or is that just a receiver issue?

I’ve run into a few places where a line of code seems to stop everything working after it. In my case I had some stuff physically hooked up wrong, and at that certain line of code, I was shorting something out and the board was auto-resetting to save itself. See if the power light flickers at all, and maybe double check connections. You could put some other known code above the suspect line and see if that executes. It might be not enough power as you suggest, if you’re using a Duemilanove it shuts down if you pull too much power I think.

Are you trying to do this with both devices connected to one Arduino?

–Phil.

Nope, just the transmitter… Should i be using both?

So having a play around today trying to figure out why the VirtualWire code won’t work, i went and commented out the entire contents of the vw_send() function. It still stops the board from continuing.

Not sure what this means but i’ll keep this updated :slight_smile:

Should i be using both?

No. I just asked the question after looking at your original schematic.

–Phil.