Bluetooth works, uploading sketches does not.

I have an Ardweeny (uno-compatible) Solarbotics Ardweeny - Solarbotics Ltd.
I have a TTL Bluetooth Adapter http://www.geeetech.com/serial-ttl-bluetooth-module-p-601.html

The first thing I want to say, is that they work. I have tested the bluetooth adapter on a USB-TTL connector. I have connected the Bluetooth to the TTL connector on the Ardweeny, and everything works well. I have been able to write test sketches and communicate both ways over bluetooth with my Windows Vista laptop. Everything works.

Except uploading sketches via Bluetooth. I've tried everything I can think of, and I can't get it to work. The correct COM port is selected, as well as the baud rate of 115200. I can click on "serial monitor" and communicate both ways if I have a sketch uploaded the old fashioned wired way beforehand. But clicking "upload" gives me "avrdude: stk500_getsync(): not in sync: resp=0x00" I've been searching the web for a solution, but nothing stands out yet.

Has anyone else had this problem with Bluetooth and the Arduino IDE?

I don't think your bluetooth module has a DTR pin which is needed for the autoreset to work during programming.

You might get lucky if you press reset manually during upload.
You're supposed to reset the board when the sketch size is reported in the IDE and you will mostly likely need to try a couple of timnes before you get it right.
The easiest way is to hold down the reset button when you strat the upload from the IDE and you release the rest button when the sketch size appears.

http://blog.iteadstudio.com/warless-program-your-iteaduino-bt-2/

Works fine with mine, I am using 100nF capacitor there and 115k2 speed (uno)..

I am getting the same problem with upload.

perhof: You may be right. The only pin it has that I cannot understand is the "CLR" pin. I'm not quite sure what it does, but it does not work the same way as the DTR pin on my USB to TTL. Any ideas?

Pito, thanks for that link. I went over that, and I'm not sure your adapter has the same firmware as mine. I looked through my adapter's manual, and pin 32 is only labelled as "programmable I/O". Perhof may be right, my adapter may not allow DTR, so I will need to buy another Bluetooth adapter if I want to upload sketches. I wonder, is there any way to test if PIN32 on my Bluetooth adapter functions as DTR? It's so tiny and I'm afraid to solder anything.

GordonShumway:
perhof: You may be right. The only pin it has that I cannot understand is the "CLR" pin. I'm not quite sure what it does, but it does not work the same way as the DTR pin on my USB to TTL. Any ideas?

You could use manual reset as I described earlier. It's not hard when you get the hang of it.
Mayb not so pretty but at least it would allow you to upload your code.

perhof, I tried the manual reset in different combinations for about half an hour with no success. My last attempt will be to find a way to test the dtr solder point on the bluetooth module to see if it does anything, and if not, I'll order a more expensive bluetooth adapter that is known to work. thanks for your advice.

Where I work we have an assembly line that reaches a point where the embedded devices (some of which come from different manufacturers depending on the customer specs) in our product need to be programmed. We use a bluetooth device that is fairly common in our industry to program them (since the assembly line is moving it is easier than having wires hanging from the ceilings). 80 percent of the time I'd say it goes without a hitch, but one particular vendor's firmware fails to program much more than another's. We think it may have something to do with it not handling a interruption in programming very well or maybe it tries way too hard to handle an interruption in programming, we're not sure. They also make a diagnostic program that is used after the entire product is assembled and stress tested. This diagnostic program also can use the same bluetooth device as the other part and it also seems to struggle mainly on the initial connection and once connected it seems to hold it steady.

I guess it is to be expected. At any given time we could have up to 20 of those devices in use along with several wifi networks used for computers and other devices.

As always when dealing with wifi or bluetooth issues, I recommend eliminating all sources of interference, portable phones, other networks, etc.

Hi Gordon

Could you please share your connection setup from the arduino to the bee and your code?

Other bluetooth device to arduino/bee works the other way round not.

And yeah, I have to plug out the bee whenever I want to upload a new sketch...

Thanks

DTR,CTS, RTS signals do not work with those BT modules. The mod described in the link I posted sets the I/O port to toggle when the connection is initiated. That is supported by IDE 1.5+. It works. p.

Partial success. I have been able to program my Ardweeny using my Bluetooth module, using manual reset method. The trick is to press and hold the reset button, and let go the moment the connection LED on the bluetooth module goes from flashing to solid. Works every time.

In other news, the manufacturer of the Bluetooth module got back to me, and said it does support DTR on pin 25 (PIO2) of the module. I have been experimenting with this, with so far no successes.

I have downloaded the latest beta IDE, and will soon be attempting Pito's work around. I'll post my progress here.