Hi Folks,
does anyone have any idea how to program a bluetooth interface under windows. Is it the same like programing a serial interface like com1, com2 etc.
If anyone has some code or hint would be very helpfull. Many thanks for help.
Programing Bluetooth
- Joakim Christiansen
- Addict
- Posts: 2452
- Joined: Wed Dec 22, 2004 4:12 pm
- Location: Norway
- Contact:
I ask the same question, I saw some C# application using calls like these:
I wonder how to do the same in PB.
Code: Select all
using System.IO.Ports;
static SerialPort MyPort = new SerialPort();
MyPort.Write(...)
I like logic, hence I dislike humans but love computers.
And what about Serial Port library?Joakim Christiansen wrote:I ask the same question, I saw some C# application using calls like these:I wonder how to do the same in PB.Code: Select all
using System.IO.Ports; static SerialPort MyPort = new SerialPort(); MyPort.Write(...)
BlueTooth ports are serial ports (com).
@TheMaster,
I have some code here from a project which I started & abandoned which may or may not be of use to you.
There are several bluetooth stacks available which makes it pretty much impossible to program an application to generically connect to a bluetooth device. The code I have partially ported is for the BlueSoleil products, which is useless if you happen to be using a device on your computer using say the Widcomm stack or the M$ stack versions. ( Hence the main reason why I abandoned the project.
)
I had it connecting to my Bluesoleil dongle & able to seek, find, get information about remote bluetooth devices, etc. I ran into problems with some of the bluetooth callback threads with what I believe was a limitation with PB at the time. ( I just can't remember exactly what the problem was atm, except that it was something to do with external threads created by the bluesoleil dll which I was unable to ID or something such for it. )
So, if you happen to be using a BlueSoleil bluetooth device, I am happy to pass what code I have here for you to continue with. ( There is approx 1,000 lines of code including constants, prototypes, structures, test code etc. )
Just let me know here if you would like a look at the code & I will organise a way to get it to you.
I have some code here from a project which I started & abandoned which may or may not be of use to you.
There are several bluetooth stacks available which makes it pretty much impossible to program an application to generically connect to a bluetooth device. The code I have partially ported is for the BlueSoleil products, which is useless if you happen to be using a device on your computer using say the Widcomm stack or the M$ stack versions. ( Hence the main reason why I abandoned the project.

I had it connecting to my Bluesoleil dongle & able to seek, find, get information about remote bluetooth devices, etc. I ran into problems with some of the bluetooth callback threads with what I believe was a limitation with PB at the time. ( I just can't remember exactly what the problem was atm, except that it was something to do with external threads created by the bluesoleil dll which I was unable to ID or something such for it. )
So, if you happen to be using a BlueSoleil bluetooth device, I am happy to pass what code I have here for you to continue with. ( There is approx 1,000 lines of code including constants, prototypes, structures, test code etc. )
Just let me know here if you would like a look at the code & I will organise a way to get it to you.
