I have tried sending the output of the "Blink" arduino program over over RF and it worked and the receiver LED blinked properly. I also tried out a VirtualWire example program and it sent a text message properly.
Now I am trying to control a servo over RF. Ideally, the receiver end should be as lightweight and compact as possible. MCU should be avoided there if possible.
So I tried connecting a data pin from Arduino to the Tx Datapin and tried using the "Sweep" program that comes with arduino servo library. But now, the servo connected to the Rx data pin simply vibrated here and there ( should be from noise ). It was obvious the proper pulses didnt reach the servo. Are the pulses sent to the servo too fast or something?
Will using an encoder-decoder setup help solve this? I have an HT12E, HT12D pair, though I haven't gotten them to work yet ( I am not sure about the resistor to connect to their osc pins ).
The documentation on Seeedstudio mentions a couple of encoder/decoders. PT2272(Encoder) and PT2262(Decoder) . I suppose they have to be purchased separately ( I have found them on ebay ). By using those ICs or maybe by using this kit
Hello,
I had used a bitrate of 2000 bps I think. I was using the "transmitter" and "receiver" example sketches from the VirtualWire library. I have seen a few example circuits with PT2262 encoders used to transmit button presses. Isn't a servo PPM pulse essentially the same thing but being switched on and off a lot more faster?
As for using R/C gear, their availability as well as cost is prohibitive where I live. I know it would be greatly simplified to use R/C receivers directly rigged to servos, ESCs etc. and a transmitter with joysticks etc.
I just tried out he "Sweep" program again ( with no modifications ), connecting pin 9 to the data pin of the Tx and connecting the data pin of the Rx to the servo. I also gave 9V to the Tx VCC pin. An antenna is really essential to make sure it works properly.
The servo moves correctly. Noise can make it sort of jerk around. So I guess I can implement some kind of rudimentary 4ch radio using an encoder-decoder setup ( either HT12E/HT12D or PT2262/PT2272 ) . The encoder-decoder setup should take care of most of the noise.
Will an HT12E/HT12D setup work for RF? Or is it useful only for IR applications? Should the value of the resistor to be connected between OSC1 and OSC2 of the HT12E always be 1.1M ? Can I use some other value resistor here ? I understand that it is used to set the datarate of the encoder. Can someone explain about the value of the resistor I should use here ?
I doubt the PT2262/PT2272 would be suitable. They operate using frames that consist of four words where each word is something like 12 bits. Each bit is 4 clock cycles. To move a servo over steps of 1 degree requires pulse width steps of around 10 microseconds I doubt you could get the internal clock running fast enough to give you anywhere near that kind of control over those big frames.
From a quick look at the datasheet the HT12x looks like a clone of the PT22xx. These are not designed to handle switching at the rates you need for controlling servos. If you have the appropriate test equipment (scope or logic analyzer) then it could be interesting to have a look but I would be surprised if it would be practical.
Why do you not want to use a simple microcontroller at the remote end, one could drive all the servos and would not be more expensive than the HT12x or PT22xx chipsets.
If size isn't critical and you want to use a standard arduino controller then there are many runtime boards and kits available from various arduino suppliers ( I use this runtime board: http://www.nkcelectronics.com/arduino-runtime-board-rev-b.html)
I am wondering what your project is about, what do you want to control?
Hello,
My project is basically an R/C airplane. But I want to make it as cheap and flexible as possible. Having it controlled by arduino would mean I would be able to completely interface it with my PC or even with some other system I may make .
I am currently checking if it would actually turn out to be less of a bother to use a readymade R/C gear after all.
I have a question about R/c "modules". For example:
Do these modules simply take the PPM data and send them in the proper frequency? Or is that big box with joysticks etc. really needed for it to work? Could I, for example, hook up this module to an arduino, get a compatible receiver and directly have a working R/C setup controlled by the arduino ?
Please bear in mind that radio control aircraft can be dangerous to you and others. You will not do yourself or this hobby any favors if you lose control of your airplane and damages property or hurt someone. I would strongly encourage you to get something like a radio controlled car going first and then consider if your system is reliable enough to put something in the air. You should get an experienced RC flyer to look everything over before even considering taking your first flight.