Can I have more than one Bluetooth Connection running?

This is where you talk about the NXJ software itself, installation issues, and programming talk.

Moderators: 99jonathan, roger, imaqine

Can I have more than one Bluetooth Connection running?

Postby Rickz2020 » Wed Jan 18, 2012 2:40 pm

Hi all.

Just started on my robot again after putting it off for a few months and have a quick question:

Can I have more than one BT device connected to the NXT simultaneously?

I have a BT GPS device and an Android phone - both of which I would like connected to the NXT at the same time.

Thanks,

Rich.
Rickz2020
Active User
 
Posts: 121
Joined: Thu Feb 10, 2011 5:47 pm
Location: London, Earth.

Re: Can I have more than one Bluetooth Connection running?

Postby gloomyandy » Wed Jan 18, 2012 2:48 pm

You can have one inbound and three outbound connections. In this context inbound means a connection that was made from another device to the NXT (i.e. the NXT used waitForConnection), while outbound means connections originated from the NXT to some other device (so in this case the NXT code used the connect method). In all cases the connections are full duplex so you can send data in both directions.

Note however that having more than one active connection, means that the NXT has to do a lot more work to manage the connections and so the data rate and the reliability of the connections will be reduced...

Andy
User avatar
gloomyandy
leJOS Team Member
 
Posts: 3967
Joined: Fri Sep 28, 2007 2:06 pm
Location: UK

Re: Can I have more than one Bluetooth Connection running?

Postby Rickz2020 » Wed Jan 18, 2012 4:13 pm

Thanks Andy.

I need to control the robot from the Android and the robot simply needs to receive GPS data from the BT GPS device.

So, which do you think would be better: OB for BT GPS Device and IB for Android connection, or IB for BT GPS Device and OB for Android connection.

Thanks for the warning about the data rate and reliability of the connections.

Rich
Rickz2020
Active User
 
Posts: 121
Joined: Thu Feb 10, 2011 5:47 pm
Location: London, Earth.

Re: Can I have more than one Bluetooth Connection running?

Postby gloomyandy » Wed Jan 18, 2012 4:24 pm

It probably depends on the devices you are using. I suspect that most Bluetooth gps devices require that the NXT connects to them. Certainly the simple Bluetooth GPS device that I have requires that. Not sure about the Android phone, it probably depends on the software you intend to run on that device...
User avatar
gloomyandy
leJOS Team Member
 
Posts: 3967
Joined: Fri Sep 28, 2007 2:06 pm
Location: UK

Re: Can I have more than one Bluetooth Connection running?

Postby Rickz2020 » Wed Jan 18, 2012 4:41 pm

Ok, I'm just going to use the dGPS from dexter industries rather. This will save some headaches I guess.
Rickz2020
Active User
 
Posts: 121
Joined: Thu Feb 10, 2011 5:47 pm
Location: London, Earth.


Return to NXJ Software

Who is online

Users browsing this forum: No registered users and 1 guest

more stuff