©Parallax, Inc. • 433.92 MHz RF Transmitter and Receiver (#27980, #27981) • v1.0 1/06 Page 8 of 8
RFmoduleRX.java
/***
RFmoduleRx.java
This code is for simple demonstration of the Parallax 433.92 Mhz RF Reciever (#27980)
Connect Javelin I/O pin 7 to the RF Rx module DATA line.
Connect +5v (Vdd) to the RF Rx module 5v line.
Connect ground (Vss) to the RF Rx module GND line.
This code will receive at 9600 baud, inverted.
This code is meant to run in conjunction with RF Tx module (#27981) running code set
to transmit at 9600 baud.
***/
import stamp.core.*;
public class RFmoduleRx {
static Uart rxUart = new Uart (Uart.dirReceive, CPU.pin7, Uart.invert,
Uart.speed9600, Uart.stop1);
static StringBuffer buffer = new StringBuffer(128);
static byte c;
static byte x = 0; static byte y = 0;
static void bufferMessage(){
c=0;
do{
c = (byte)rxUart.receiveByte();
} while (c != 33);
x = (byte)rxUart.receiveByte();
y = (byte)rxUart.receiveByte();
} //end bufferMessage
public static void main() {
while(true) {
buffer.clear();
bufferMessage();
System.out.println(x);
System.out.println(y);
} //end while
} //end main
} //end class
FCC Notice and Liability Disclaimer
These modules (boards) are not FCC approved. They are designed to comply with FCC Part 15 Rules and
Regulations. They are not in a finished product form. They are strictly intended for experimental
purposes only. If you wish to use these modules in an actual product (a non-experimental capacity), the
module must first be designed into the product then the whole product must be approved by the FCC.
Parallax, Inc. is not responsible for special, incidental, or consequential damages resulting from any
breach of warranty, or under any legal theory, including lost profits, downtime, goodwill, damage to or
replacement of equipment or property, and any costs of recovering, reprogramming, or reproducing any
data stored in or used with Parallax products.