(Read 630 times)
Oct 22, 2013, 11:12 pm
Hello everybody! For a school competition I am designing a nunchuk controlled car. Now, I need to control it from a distance. I can be pretty close to the car, but to be safe I will say 4 feet away.
Currently, the nunchuk directly controls the servos through the same Arduino. I have read about the XBee shield, but I need to be cost efficient, and after watching a video tutorial, the person made it only send 1 number across serial, and he never explained what do for sending big strings across.
I also took a look at bluetooth, but don't know how reliable that is.
My car takes 2 analog pins, 3.3v, and ground directly through arduino. My servos use 4 PWM pins on the board, and a separate power supply.
Please reply what you think I should use, and any libraries and tutorials you suggest. I'm not very good with Serial communication, so thank you for reading!
Oct 23, 2013, 04:03 am
What are your 'nunchucks' - what sort of interface do they provide? If you already have a serial connection then you should be able to use bluetooth in place of the wired connection. Bluetooth would easily cope with a range of 4'. Bluetooth works just like a wired serial connection once you have set it up, and there are plenty of examples showing how to receive messages over a serial port.
I don't understand the references to servos and pwm pins, so it might be worth giving more detail on that part of your system.
Oct 23, 2013, 08:52 am
I would get it going with 2 Arduinos connected with wires first, this will give you some idea of what type of connectivity you need. You are right that Bluetooth and the like are serial but it is also possible to send analog over radio (e.g. Model Aircraft - at least the non digital type).
The thing with using serial comms is that you are going to have to send the data as digits, read this at the other end and drive the servos which, whilst not hard, is a reasonable bit of code to develop and test. I have used bluetooth in the past with Arduinos and I have found that the cheap bluetooth modules (ebay) are OK but they are electrically noisy and prone to failure after a few months. Google "wireless serial" for alternatives something like this http://shop.ciseco.co.uk/xrf-wireless-rf-radio-uart-rs232-serial-data-module-xbee-shape-arduino-pic-etc/ may do what you want.