Hey folks,
Webbot's Gait Designer is pretty awesome if you haven't tried it. My question is a bit more general, so other besides Webbot might have insights.
Basically, I can connect Gait Designer to my Axon with a USB2Serial connection, or USB-USBMini connection, but a bluetooth serial connection times out, and I'm wondering if anyone has any ideas why this is. Hyperterminal works for all methods. Read on for lotsa details.
*********** Observations that aren't really useful anymore start here **********
Gait Designer communicates with the Axon (or similar) via a serial connection to a PC. You specify the COM port and the baud, and put the necessary code on the MCU, and voila.
So I've successfully done this, e.g. my quadruped is controlled. I've accomplished this both with a USB cable to UART1, and a USB-to-Serial cable to UART2. What I'm trying to do is reduce the tethers on my bot while designing a gait, namely by using a bluetooth serial connection.
Specifically I'm using
this adapter. I've used it successfully in the past with other projects as well as the Axon.
With both the USB2Serial and BluetoothSerial connections, the Axon successfully outputs to hyperterminal. So I know baud rate (19200) is set correctly. I then disconnect in hyperterminal, and connect in Gait Designer. The connection is established successfully with USB2Serial method.
The bluetooth adapter flashes its LED when it is unpaired. When being connected (and when connected) the LED does not flash.
So when I click the Connect button in Gait Designer, the LED stops on the bluetooth adapter, then starts again when I get a "Connection Timed Out" error popup. This happens on both my Windows XP laptop and my Windows 7 desktop. Additionally, Windows 7 notifies me with tray popup that a connection has been established. I then get the "Connection timed out" error, and a disconnect notification.
I'm guessing it might be a problem with the RxTx package that
Webbot is using in GaitDesigner. Anyone heard of and solved this problem before? I just googled 'rxtx java bluetooth' and
this guy seems to have had the same problem with diff hardware.
****** And end here ********
So I did a bit more googling and testing after typing all of the above (*sigh*).
Now I know what the problem is.
Windows creates separate COM ports for incoming and outgoing serial connections over bluetooth (no idea why...), and I haven't seen a workaround. RXTX doesn't handle this. This archived email suggests it hasn't been fixed.
Both computers do indeed have two serial ports, and I was using the incoming ones, it looks like. On windows 7, trying to connect the outgoing one crashes Gait Designer (no errors, just gone). On XP, gait designer hangs indefinitely. I could test with Ubuntu (but I'm still bitter months afterwards, that I've been unable to get the wifi driver to work).
I now understand why I couldn't get loopback signals to work via bluetooth in hyperterminal, VB.NET, etc. Ultimately, I plan to use xbee wifi to communicate with my axon...
I don't think it's worth Webbot's time to fix this, but if he so chooses, it looks like *maybe*
this package for roomba communication works around the issue?
Back to tethering. At least I have plenty of USB extension cables to use x)