LabVIEW for LEGO MINDSTORMS and LabVIEW for Education

cancel
Showing results for 
Search instead for 
Did you mean: 

Data logging using Blue Thooth


@Kjeld Petersen/SDU/DK wrote:
HI Bill

I stumbled upon the Download Driver SDK (fantomSDK1.0.2f0.zip 2.21MB) 
from
http://mindstorms.lego.com/Overview/NXTreme.aspx

And actually it not only contains c++ code for accessing the NXT device, but also *.vi blocks.

Regards Kjeld







Hi Kjeld,

Yes! We are on the same hunt! I found the same file last week and was delighted to discover some vi's in the package.

(now I just need my mid-term examinations to go away so I can continue to play with the NXTs!)

-Bill =]
0 Kudos
Message 11 of 24
(7,660 Views)
Hi All:

I have also followed this discussion on the Club LEGO message board that mentions using Microsoft Robotics Studio to communicate sensor values via BlueTooth:




I have successfully tried duplex bluetooth communication by using Microsoft Robotics Studio. Basically, they have provided a program that you run on NXT as a proxy which collecting sensor inputs and send through bluetooth, while it also keep watching the inbox of bluetooth. On your computer side, MS Robotics Studio also provides a proxy that listen to a bluetooth serial port and communicate with you.

The programming interface is based on .Net Framework and is message driven. Which is very good. You register your handler with events(mostly sensor inputs) and send command to rotors whenever you want. It is very convenient way to program and gives you the full power of your computer.



-Bill =]
0 Kudos
Message 12 of 24
(7,648 Views)

@Kjeld Petersen/SDU/DK wrote:
HI Bill

I stumbled upon the Download Driver SDK (fantomSDK1.0.2f0.zip 2.21MB) 
from
http://mindstorms.lego.com/Overview/NXTreme.aspx

And actually it not only contains c++ code for accessing the NXT device, but also *.vi blocks.

Regards Kjeld







Hi Kjeld,

I had some time to tool around with the fantom.zip file you link above.

I'm a bit confused that the c++ code is only displayed as HTML help files, but I guess it would be a simple matter to copy and paste the commands into .cpp files and link to the header files that are included.

The LabVIEW files require access to the fantom.dll file, but only a fantom.lib file is included in the zip. The lib file opens in binary in Visual Studio 2005, but being an ANSI C dinosaur, I don't know to unpack or access any dlls it may contain.

Am I being totally dense on how to make this work, or is this resource kit un/intentionally obfuscated?

-Bill =]
0 Kudos
Message 13 of 24
(7,635 Views)
Bill:

Parts of the Fantom SDK are intentionally obfuscated to protect NI's intellectual property, but the main idea is to offer an easy way for users such as yourself to leverage the Fantom framework.  Hopefully I can help you understand how all the pieces fit together.  Which files you need depends on whether you are writing C++ code or LabVIEW code.

If you're going with C++, there are headers included in the Fantom SDK (includes/fantom/*.h) to provide an interface for you to compile against.  You're right that the example code provided is only included in the HTML and CHM formats, so you'll have to copy and paste into your own text file to compile that code yourself.  Once you've gotten your code compiling, you'll need to link against the *.lib file buried in the targets directory hierarchy (or the *.framework for the Mac folks).  You don't need the DLL until you're ready to run your code.  Our assumption was that all Fantom SDK users would have already purchased and installed the LEGO MINDSTORMS NXT Software and Fantom driver, so we didn't provide a duplicate DLL in the Fantom SDK.

As Kjeld pointed out, though, we also included a LabVIEW interface for the Fantom driver.  These are the VIs located in [includes/labview/...].  The LabVIEW interface happens to be platform specific, so be careful that you are using the right VIs for your target platform.  (If you're developing cross-platform, use the macosx VIs.)  If you choose to develop your application purely in LabVIEW, you won't need the header files or the *.lib file.  But, you will need the DLL installed as you are developing.  Otherwise, the Fantom VIs that access that DLL won't compile, and you'll be staring at broken arrows in all of your application VIs.

I hope this helps.  Since we've started to stray a little from the original topic of Bluetooth logging, you might consider starting a new Fantom SDK discussion thread if you have additional questions.
------
James Blair
NI R&D
0 Kudos
Message 14 of 24
(7,624 Views)
James!

You, my friend, are a gentleman and a scholar. While I'm a complete idiot.

We have a segmented network here at school to separate faculty and student resources. I have two complete systems on my desk, one connected to each. I installed the NXT system on my laboratory computer. I was surfing the net, looking for solutions on my faculty computer when I came across the Fantom SDK. (you can see where this is headed)

I have been tooling with the Fantom SDK on my faculty system (w/o the fantom.dll) and was totally stumped as to how to proceed.

All is clear.... I can keep on going now. Thanks!

-Bill =]
0 Kudos
Message 15 of 24
(7,612 Views)
Let's open a new forum for Fantom SDK.

Regards Kjeld
0 Kudos
Message 16 of 24
(7,610 Views)
Hi Bill

You tried for some time ago to install the BlueSolei friver from Abe?

My problem is that I have a computer with only Windows 2000 installed, and that does not have it own bluetooth driver included.
So I tried to install the BlueSolei program/driver, and I got connection to the NXT, well that is I got connection from the BlueSolei program, but not from LEGO Mindstorm program.

Did you get your NXT connected to the LEGO Mindstorm program using the Abe BlueSolei driver?

Do you have any idea about what I can do to get it to work. I also have to use LabView later on.

One possible solution is to install Win XP, but since it is the IT-service that has to do that, I would see if I had other options first.

Kind Regards
Kjeld
0 Kudos
Message 17 of 24
(7,547 Views)

Hey Kjeld,

Sorry, no...  I did not get the BlueSoleil driver to work with the NXT.  I followed the instructions to disable the WinXP drivers and installed the BlueSoleil, but as you discovered, I could get the driver to recognize the NXT unit as a BlueTooth client, but it did not provide the required connection to the fantom.dll used by NXT-G.

Only after removing the BlueSoleil software and turning WinXP back on did it function.  .......and then armed with a working solution, I stopped looking into the BlueSoleil compatibility problem.

Any other readers have success with this?

Also... as I mentioned on the FantomSDK discussion, we have recently been able to talk to all of the sensors of the NXT (motor tachs, touch, light, sound, and sonar) and command the motors using USB and Bluetooth communication....  in response to your original question about gathering data from the NXT using BlueTooth.

We did not use the message box system, but completed it using only the sendDirectCommand calls to the fantom.dll.  The LabVIEW code does not look that presentable, but I hope to clean it up a bit and post it in case it is of use.

Thanks!

-Bill  =]

0 Kudos
Message 18 of 24
(7,544 Views)
Hello everyone! I'm new on this forum.

I tried to connect to my NXT by bluetooth, and i was using Bluesoleil driver at start too, and i was able to connect to NXT brick to Bluesoleil console, but connecting to Lego program was impossible, i tried to connect to MS robotics studio too, but it failed again. I uninstalled Bluesoleil drivers and just sticked BT dongle again and windows drivers made connection possible.
I think it works that way that every aplication is counted as a device, and NXT has only 1 slot for slave conection, so if you connect NXT to computer by bluesoleil you are making line busy, maybe you should connect then somehow to this blusoleil console, but much easier is just get windows drivers for BT and let each aplications you use to conect directly to NXT.

best regards,

Miki
0 Kudos
Message 19 of 24
(7,518 Views)
Hi All

I have had the same problem with the Abe / BlueSolei BlueTooth dongles, that they do not work properly under Windows2000.

I have now tried with a IOGear and a Typhoon V1.2. Both are working just fine.
The software for both are totally different from the Solei software. It works as a service (I think) instead of an application.
I haven't tried to use the Abe / BlueSolei with the IOGear or Typhoon software, but it could be nice to se if that would work.

Regards Kjeld


NB: The IOGear was lend, and I didn't write down the type of it.
0 Kudos
Message 20 of 24
(7,494 Views)