- Sun Jun 20, 2010 4:57 am
#103442
Hi,
Background - I've just a pair of low cost RF Transmitter & Receiver (http://www.sparkfun.com/commerce/produc ... ts_id=8946, and http://www.sparkfun.com/commerce/produc ... ts_id=8950
Issue - I've set them up for the test program (see code below), however I'm not seeing any response from the receiving Arduino. I note that when I put a multimeter on the transmitter the +ve voltage on VCC is OK, and when I look at teh DATA line I see it stays at around VCC voltage but the needle moves a little every second, so it seems as if it getting the transmit signal ok. I don't have antenna wires on them, but they are only a few centimeters apart so this should be ok no?
Question - Any advice on how to trouble shoot in this situation? I only order one of each of the units.
Transmitter Code
Receiver Code
Background - I've just a pair of low cost RF Transmitter & Receiver (http://www.sparkfun.com/commerce/produc ... ts_id=8946, and http://www.sparkfun.com/commerce/produc ... ts_id=8950
Issue - I've set them up for the test program (see code below), however I'm not seeing any response from the receiving Arduino. I note that when I put a multimeter on the transmitter the +ve voltage on VCC is OK, and when I look at teh DATA line I see it stays at around VCC voltage but the needle moves a little every second, so it seems as if it getting the transmit signal ok. I don't have antenna wires on them, but they are only a few centimeters apart so this should be ok no?
Question - Any advice on how to trouble shoot in this situation? I only order one of each of the units.
Transmitter Code
Code: Select all
/* * Simple Transmitter Code
* (TX out of Arduino is Digital Pin 1)
* (RX into Arduino is Digital Pin 0) */
byte counter;
void setup(){
//2400 baud for the 434 model
//Serial.println("setup");
Serial.begin(4800);
counter = 0;
}
void loop(){
//send out to transmitter
digitalWrite(13, HIGH); // Flash a light to show transmitting
Serial.print(counter);
counter++;
delay(50);
digitalWrite(13, LOW);
delay(1000);
}
Receiver Code
Code: Select all
thanks/* * Simple Receiver Code
* (TX out of Arduino is Digital Pin 1)
* (RX into Arduino is Digital Pin 0) */
int incomingByte = 0;
void setup() {
//2400 baud for the 434 model
Serial.begin(4800);
//Serial.println("setup");
}
void loop(){
// read in values, debug to computer
if (Serial.available() > 0) {
digitalWrite(13, HIGH); // Flash a light to show receiving
incomingByte = Serial.read();
Serial.println(incomingByte, DEC);
digitalWrite(13, LOW);
}
incomingByte = 0;
}