Bluetooth issue Hydra 4.2 (October 12)

Hi,

I am strugling having my Hydra using the very last 4.2 SDK getting connected via Bluetooth on my PC (Samsung Serie 9, Win7 , BT : Intel Centrino Wireless Bluetooth).

I tried simple example from https://gadgeteerbluetooth.codeplex.com/ and from http://www.tinyclr.com/forum/topic?id=5552&page=1, but in both case same resut :

BTSate +3:
Connect FAIL

Is there an issue with the GHI BT module and Hydra SDK 4.2 ?

PS : the very same module is working perfectly on a Spider using SDK 4.1

Hi,
I think you should post your code.

@ RoSchmi,

thanks for you reply, In fact I am using the code from Eduardo Velloso :

https://gadgeteerbluetooth.codeplex.com/SourceControl/changeset/view/18482

This code is working on 4.1, I have just change the Framework to 4.2 (October SDK) and add the library Gadgeteer.Serial into the Bluetooth.cs reference. No compilation problem and the program is running ok but no way to get connected :frowning:

Using mainboard GHI Electronics FEZHydra version 1.2
Reader Thread

WORK:SLAVER

+BTSTATE:0

Program Started
Client Mode
E:

Received: E:

+STWMOD=0

Received:
+STWMOD=0

+BTSTATE:3

Received:
+BTSTATE:3

OK

Received:
OK

CONNECT:FAIL

Received:
CONNECT:FAIL

WORK:SLAVER

Received:
WORK:SLAVER

+BTSTATE:0

Received:
+BTSTATE:0

+BTSTATE:1

Received:
+BTSTATE:1

+BTSTATE:3

Received:
+BTSTATE:3

CONNECT:FAIL

Received:
CONNECT:FAIL

+BTSTATE:1

Received:
+BTSTATE:1

I was wondering if anyone make the bluetooth module working with Hydra on 4.2 Oct SDK ? If so how ?

Hi,
sorry, I have only a spider. There are no problems with SDK 4.2.
Roland

If you’re using Eduard’s driver, then you might want to check out the comments I’ve made in this project http://www.tinyclr.com/codeshare/entry/446

The thing I found was that you needed to wait for the driver to stabilise before attempting pairing

@ Brett,

Thanks for that. I did tried your program, after porting to 4.2, as your code was in 4.1 although I had Gadgeteer.serial, but still same result.

@ RoSchmi,

Which driver did you use for your Spider ?

@ ALL

Does someone has sucessfully use the BT module with a Hydra (4.2 SDK October)

PS : Windows7 BT did recognized the Hydra and appairing it properly.

So can you articulate what part of the connection you don’t think is working?

You said it is pairing properly; I don’t understand what else you need? You also said it worked on 4.1 fine, do you mean the same code worked in the same way, but now doesn’t?

I don’t have 4.2 nor a need to do an upgrade just yet, so I can’t test an actual app. I think for us to help you more we’re going to need more info

@ Brett,

Sorry for being unclear.

When I ran “gdgtr_min_bluetooth” Windows asking me to input the code for appairing and it seems to work as I see the Gadgeteer on the BT device window, but the VS output display print is :
Program Started
Reader Thread
§SER
+BTSTATE:0
+BTSTATE:1
+BTSTATE:3
Client Mode
Enter Pairing Mode

Recieved:
OK
Recieved:
OK
OK
Recieved:
OK
WORK:SLAVER
Recieved:
WORK:SLAVER
+BTSTATE:0
New state:0
Recieved:
+BTSTATE:0
+BTSTATE:1
New state:1
Recieved:
+BTSTATE:1
+BTSTATE:3
New state:3
Recieved:
+BTSTATE:3
Le thread ‘’ (0x3) s’est arrêté avec le code 0 (0x0).
CONNECT:FAIL
Recieved:
CONNECT:FAIL
+BTSTATE:1
New state:1
Recieved:
+BTSTATE:1

And when I press the Joystick (the BT module is blinking red and blue, the VS Output print is :
Enter Pairing Mode

Recieved:
+INQ=1
Recieved:
+INQ=1
OK
Recieved:
OK
+BTSTATE:2
New state:2
Recieved:
+BTSTATE:2

Answer : YES

So I am stuck :frowning:

So I think the log you show shows it going into pairing mode, but it seems you’re not connecting to it.

A quick test as I dash out the door. Opened my minimal BT connection program, deploy to Fez Hydra. This is the first time I’ve used this on this PC (new Win8 build).

Without entering pairing mode (no joystick press): nothing visible to connect to in Win8; here’s the log

[quote]Using mainboard GHIElectronics-FEZHydra version 1.0
Program Started
Reader Thread

+BTSTATE:1

+BTSTATE:3

Client Mode
Enter Pairing Mode

+STWMOD
Recieved:
+STWMOD

OK

Recieved:
OK

OK

Recieved:
OK

OK

Recieved:
OK

OK

Recieved:
OK

+BTSTATE:2

New state:2
Recieved:
+BTSTATE:2

WORK:SLAVER

Recieved:
WORK:SLAVER

+BTSTATE:0

New state:0
Recieved:
+BTSTATE:0

+BTSTATE:1

New state:1
Recieved:
+BTSTATE:1

+BTSTATE:3

New state:3
Recieved:
+BTSTATE:3

CONNECT:FAIL

Recieved:
CONNECT:FAIL

+BTSTATE:1

New state:1
Recieved:
+BTSTATE:1[/quote]

Blue light only flashing.

Hit Joystick; blue/red flashing; log shows:

That’s before I connect at the PC side… Then on the PC I connect to the device, put in the PIN, and blue/red still stays flashing. Once drivers load, I can see device manager has the serial ports I want, so I open Tera Term and set up the serial port the way I want, connect, and hey presto:

I don’t think your experience will be different given only the 4.1 → 4.2 change. Did anything else on your PC change besides 4.2?

Thanks Brett.
Actually my mistake was to use a 4.1 and “just” change the Framework from 4.1 to 4.2. The solution was to create a new shell then cut and paste the appropriate code. Re-Reading your comment on your CodeShare post (http://www.tinyclr.com/codeshare/entry/446) help me to find the solution. Thanks Again
:slight_smile: