Shop OBEX P1 Docs P2 Docs Learn Events
433MHz Transceiver Issue with bs2 — Parallax Forums

433MHz Transceiver Issue with bs2

Dan_NSCCDan_NSCC Posts: 1
edited 2013-02-04 21:07 in Accessories
I am using a BS2 developer board connected with a 433 mhz wireless transceiver (27982). I have two seperate boards connected by way of the serin and serout commands communicating successfully using the wireless transceivers, however, I have noticed that when in receive mode, one transceiver is consistently receiving garbage bytes from an unknown source. A spectrum analyzer was unable to locate any radio interference in the room, and even with the antenna off the receiver, it was still spitting out junk data. While the two transceivers are capable of communicating, and transferring data, while using a serin command with a wait modifier to ensure I do not receive the junk data, I cannot use a timeout function on this serin, because the junk data prevents it from timing out.

This happened using both transceivers in the same position, with the other one completely off, and no detected radio inteference by the spectrum analyzer. I also tried connecting it to a board that didn't have my other components connected to it, to remove that as a possible problem, still did the same thing.

Is there any additional infromation on the transceiver that I don't know about? Are they maybe, designed to never output nothing on the serial connection? As long as that serin command is unable to timeout, I am unable to interrupt my wait for the information from the sending transceiver. If an error occured during transmission both systems would lockup waiting for input data from eachother.

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2011-11-22 10:43
    The receiver portion of the transceiver is pretty sensitive and has an automatic gain control so that the receiver gain increases if there's no signal received. You may notice that the demo programs all have the transmitter turn on for a short period of time prior to transmitting data. This is to cause the receiver to reduce its gain to where the noise is overwhelmed by the data signal. This is a characteristic of many receivers with automatic gain control. You may have a noisy environment (which may not show up on the spectrum analyzer) or there may be noise on the power supply lines or this may simply be noise internal to the transceiver. As you've noticed, you can't use the timeout on the SERIN and you have to use the WAIT modifier.

    Another option, since the noise pulses are short, would be to put a tight loop in your program before the first SERIN that would look for a period of time (a certain number of successful loops) with a high signal from the sync pulse. Every time a low signal comes in, the counter would get reset to zero. Once the counter gets high enough, the loop would exit to a SERIN with a timeout which should work at that time. Your sync pulse would have to be a couple of character times long (2ms each at 4800 Baud) to ignore unexpected data transmissions.

    You could also look at the voltage on the RSSI line. You'd have to do some experimenting to see what sort of voltage is present with a sync pulse of a particular width. You could set up a simple comparator or use the RCTIME statement to read the voltage and use that to indicate when the sync pulse is present (see here, follow links to "app-notes" and "RCTIME command").
  • FXDWGFXDWG Posts: 3
    edited 2013-02-04 16:01
    I am doing an entry level BS2 projct myself. All I am trying to do is send a from one board that will light up a LED on the other. Would you happen to have any exaples that I could use as a foundation?

    Thanks
    FXDWG
  • Mike GreenMike Green Posts: 23,101
    edited 2013-02-04 21:07
    Have you looked at the documentation for the transceiver? There's a simple example there and the webstore page for the transceiver has more complex examples that include error checking and correction.
Sign In or Register to comment.