I have equipped two Arduino UNO R3s with a pair of 433mhz transmitter/receivers each (433MHz RF Transmitter Wireless Module for Arduino - Blue + Yellow - Free shipping - DealExtreme).
I am using the VCC (5V)/GND/data pins and connected the data pin of the transmitter to digital input 12 and the data pin of the receiver to digital input 11 (which seems to be the default expected by RadioHead:ask_reveiver example).
When using the RadioHead:ask:ask_receiver/ask_transmitter example this basic configuration still seems to work fine: I tested both directions, i.e. the example works correctly regardless of which of my 2 Arduino's is acting as a receiver/transmitter (i.e. the receivers/transmitters and my basic wiring seem to work for this very basic example).
But now to the problem: I tried next to use the RadioHead:ask:ask_reliable_datagram_* example but this one does NOT work. The server actually receives the request from the client but then fails with "sendtoWait failed". Any ideas what's going wrong? Am I missing songthing?
The example codes you are running "ask_reliable_datagram_server" and "ask_reliable_datagram_client" are not the issue.
You can confirm this by not using the radio modules, and running a two wires between two arduinos (pin 11 client to pin 12 server, and pin 12 client to pin 11 server.) for the RX/TX pairs. If you open two separate incidents of the IDE and load the client program to one and the server program to the other(on the correct com ports) you should be able to open two instances of the serial monitor and see both the server and client print outs.
If you experiment with pulling one or the other of the wires, you will see that the error message you see on the server only occurs when the Server TX/Client RX connection is broken.
Check your wiring and start swapping modules around, and you should be able to pinpoint which is defective.
I think there is in fact some issue with the "ask_reliable_datagram_server" and "ask_reliable_datagram_client" example or its default configuration when using the above kind of 433 Mhz modules:
I just noticed that when placing my two Arduinos right next to each other (10cm distance) the example actually works (there is an occasional "sendtoWait failed" but most of the time there is the correct "And hello back to you" answer). But as soon as I increase the distance between the server and the client to just >= 20cm the example always returns "sendtoWait failed".
To rule out the possibility that some of my receivers/transmitters or antennas might be bad I again reverted to the simple receiver/transmitter example. I again verified both directions and both transmitter/receiver pairs actually work even at much bigger distances (>10m through walls).
If I understand correctly, the problem statement is that there is reduced range when using the reliable datagram sketch compared to running either single rx/tx pair.
-
Do you have antennas soldered to the modules?
-
How are you powering the modules? Is it possible that the voltage is dropping when both units are running on the same arduino. The receivers should be close to 5v.
-
Have you tried a different tx/rx baud rate. The default is 2000, and you may have better range if you are faster or slower.
-
Yes it is possible that there is interference when trying to use these cheap module pairs as a low cost transceiver with bidirectional communication. The library handles a lot of issues, but there may be underlying hardware issues.
It's possible that when one unit is transmitting it may be driving the AGC down on its RX, and then when it is time for it to receive from the other transmitter, it may not respond correctly.
I don't know the ask_reliable_datagram library well enough to know if there are changes you can make to optimize.
You may have to the bullet and buy some true transceivers.
cattledog:
If I understand correctly, the problem statement is that there is reduced range when using the reliable datagram sketch compared to running either single rx/tx pair.
yes, that's correct.. reduced from >10m to < 10cm 
cattledog:
- Do you have antennas soldered to the modules?
yes, I am using a straight ~18cm steel wire on the transmitters and the same type of steel wire that I twisted into the coils of a ~10cm spring.
cattledog:
2. How are you powering the modules? Is it possible that the voltage is dropping when both units are running on the same arduino. The receivers should be close to 5v.
no idea.. I am powering both arduinos with a separate 9v power supply.
cattledog:
3. Have you tried a different tx/rx baud rate. The default is 2000, and you may have better range if you are faster or slower.
I had tried 1000 and it made no significant difference.
cattledog:
3. Yes it is possible that there is interference when trying to use these cheap module pairs as a low cost transceiver with bidirectional communication. The library handles a lot of issues, but there may be underlying hardware issues.
It's possible that when one unit is transmitting it may be driving the AGC down on its RX, and then when it is time for it to receive from the other transmitter, it may not respond correctly.
I don't know the ask_reliable_datagram library well enough to know if there are changes you can make to optimize.
You may have to the bullet and buy some true transceivers.
I had already previously tried some of these (http://www.volumerate.com/product/2-4ghz-nrf24l01-wireless-communication-module-for-arduino-2-pcs-383273) but when testing in the house their range was actually worse then for the above stuff.. I guess my next try will be with some of these: http://www.aliexpress.com/item/Y102-New-SI4432-470MHz-1000m-Wireless-Module-470M-433mhz-Wireless-Communication-Module-Hot-Sale/32282582069.html then..
(I'd like to establish a communication link from within the house to a green house which is located at a 30-40m distance.. but I'd like to avoid having to use a separate antenna on the outside of the house.. eventhough that might be a last resort if everything else fails..)
I'd like to establish a communication link from within the house to a green house
Why does it need to be bi-directional?
Edit 12:00
Have you tried using Virtual Wire, or Radio Head without the reliable datagram? I'm thinking that you can program the bi-directional communications, recognize who sent what, and reply all without the immediate ack. Recognize an appropriate received messaged and transmit a response. You can play with timing of when the return message is sent, and should be able to get a quiescent period between transmission and reception.
cattledog:
Why does it need to be bi-directional?
Actually I don't know yet if or which parts might need to be bi-directional. I've never used an Arduino before and in this phase I am just trying to get a feel for what might or might not be useful for my project. Once I have a better idea of the capabilities/limitations/costs of the components involved I'll decide what kind of topology I am going to use.
(Things that I'd like to do: Monitor soil humidity and air temperature and store that data in some DB for archiving and offline analysis. Based on the respective sensor input automatically control the irrigation and the opening/closing of windows). Re-configure the setup or the used strategy at runtime (e.g. to account for crop changes). Manually override the automatic strategy if needed, e.g. when windows need to stay closed on a very windy day..)
I´m having almost the same issue and it doesn´t seem to be interference. I have changed boards (svr/client) keeping the hardware simetrical and still have this msg (sendtowaitfailed). I noticed svr receives "0x1: Hello World and client receives "ox2: And Hello back to you", but that error message still appears. Do anyone know how to fix it? Regards" Plinio.