rysw:
Hey guys. This seems like the right place to ask my question, but I may be mistaken. Anyway...
The "installation and troubleshooting" section, which right at the top says NOT for questions about your project? And you're asking a question.... about your project? Not the right section - project guidance, or maybe electrical questions. But not installation and troubleshooting! (but please do not go making a new thread there - that violates forum rules against making multiple threads on the same topic - report your post and ask mod to move it to appropriate section)
rysw:
I've made a program which makes the Arduino control a 4WD Mobile Platform. I have a problem with unplugging the USB cable from the device.
Basically, I want the code to initiate when I flick the switch on, which seems to be what the device in the following video is doing.
http://www.youtube.com/watch?v=uQ-f_V5A75w&feature=related
Right now, I need to keep the USB cable connected to the device and flick on the switch in order to get my motors moving, which is obviously problematic when the device moves. How can I upload the code to the board, disconnect the USB cable, flick on the switch and get the motors moving?
It sounds like you don't have another power source for the Arduino, so it's not powered when not plugged into USB. Either use a voltage 7~12v on the barrel jack, or external 5V into the USB port (or the 5v pin if it's a nano/pro mini - with the full sized boards and probably the micro, if you have it powered with 5v pin, and you plug in a USB cable, it will often damage the board - for supplying 5v to a full-sized board, I recommend a butchered USB cable, as that physically prevents you from connecting 5v external power and USB at the same time). Assuming your power source is >5v for the motors, if using a full-size board, I'd use one of those el-cheapo ebay buck converters with 5v output and a USB port - but really I'd just us a nano/pro mini (and power with an el-cheapo buck converter powering the 5v pin).
I almost never use full-size boards - expensive, bulky, and with that dodgy power switching circuit... And the official ones have the 16u2 as serial adapter, which is failure prone.