Problems with serial via RF
I bought some RF transmitter/receiver pairs a while back and have just now started
experimenting with them on two BOEs (original BS2 installed).
I'm attempting to get them to send simple text from one to another... the problem is
the total lack of anything remotely accurate.
I know that both async serial and RF in general are not known for accuracy but I'd
like to try to get them somewhat usable.
Speed is not an issue so I've lowered the baud to as low as I think the BS2s can go.
I'm using the RF transmitter/receiver pair from Sparkfun.com:
http://www.sparkfun.com/commerce/product_info.php?products_id=7813
I've wired it according to their walkthrough available partway down the page.
The transmitting BOE·is running off a 9volt battery, the receiver is running off of 4 AAs.
Both transmitter and receiver are running from +5 regulated (VDD) on each board.
Umm... trying to think of any more info you may need to help me...
Each one has a 3 inch wire for an antenna.
They are near a broadband wireless router so there's a lot of "trash" data floating in the
air, so I use the WAIT keyword in my SEROUTs.
I also attempted to slow down the transmission in attempt to capture everything... I
added pauses of 1 second between each transmission with the effect of receiving
NOTHING during a test.
Normally (without the pauses) I receive test1, test3 then test5... each loop after that
only sends test2 and test4.
I know this is some kind of timing sync problem, but I can't figure out how to solve it.
Any advice you could offer would be greatly appreciated.
experimenting with them on two BOEs (original BS2 installed).
I'm attempting to get them to send simple text from one to another... the problem is
the total lack of anything remotely accurate.
I know that both async serial and RF in general are not known for accuracy but I'd
like to try to get them somewhat usable.
Speed is not an issue so I've lowered the baud to as low as I think the BS2s can go.
I'm using the RF transmitter/receiver pair from Sparkfun.com:
http://www.sparkfun.com/commerce/product_info.php?products_id=7813
I've wired it according to their walkthrough available partway down the page.
The transmitting BOE·is running off a 9volt battery, the receiver is running off of 4 AAs.
Both transmitter and receiver are running from +5 regulated (VDD) on each board.
Umm... trying to think of any more info you may need to help me...
Each one has a 3 inch wire for an antenna.
They are near a broadband wireless router so there's a lot of "trash" data floating in the
air, so I use the WAIT keyword in my SEROUTs.
I also attempted to slow down the transmission in attempt to capture everything... I
added pauses of 1 second between each transmission with the effect of receiving
NOTHING during a test.
Normally (without the pauses) I receive test1, test3 then test5... each loop after that
only sends test2 and test4.
I know this is some kind of timing sync problem, but I can't figure out how to solve it.
Any advice you could offer would be greatly appreciated.
Comments
It may be just me, of course. Everything else I've bought from Sparkfun works great, so it's a bit hard to believe that those RF units could really be that bad.
I have made a small amount of progress... I figured out that part of my problem was the delay that the debug commands
cause between each reception of data was causing it to miss some bytes.
I ended up buffering 4 sets of data and then after transmission was complete, to THEN display them with debug.
Using the info that Kenwtn's pdf mentioned, as well as several other sites... I figured out that it works better when there
is some "junk" data or unneeded data sent right before the important byte. The reason seems to be that it helps to
establish a connection between transmitter and receiver.
It still misses data from time to time. I know that the answer is most likely some form of repeating the message, but
my problem is how do I have it tell the difference between messages that are repeating to ensure reception... and messages
that I actually want processed repeatedly.
Any advice you guys may have is welcome.
PS: Sylvie369... remember, I think these things are designed to function as keyfob transmitters so I doubt that they are
designed to handle the amount, and kind, of data that you (or I) are using it for... so some degree of crappiness is to be
expected.