LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

COM Ports and Bluetooth - Help on connecting LabView to my Arduino??

Hello,

I am currently trying to send data from my Arduino Due to LabView using a Seeed Studio Bluetooth shield.  From the research I have done, this is more than possible using a Bluetooth dongle that installs on Windows (which mine does).

 

So far, I have been able to get my PC to recognize the BT device, install necessary drivers, and establish a comm connection.  I have been looking at COM ports using the program SSCOM3.2.  From here, I have been able to send information back and forth between the PC and Arduino. 

 

The Bluetooth communicates on the COM5 port of my PC, so I have been trying to talk using the COM5 on LabView, but have had poor results.  I have been trying to Query and Parse using the Instrument I/O assistant.  Most of the time no connection is made betweent the two, but every once in a while (after many times of closing LabView and retrying) I am able to parse a string that can be seen by the Arduino. 

 

I think there is a problem with the COM port opening and closing, but I am not sure how to fix this.

 

Does anyone have any information that could help me? LabView itself is pretty new to me so any info helps.  It makes sense to me to think of the Bluetooth as creating a wireless COM port, so this definitely seems doable, especially since I can already see data talking back and forth on the COM ports!

 

Cheers!!

 

-LabViewer77

 

P.S. Here is a link to the shield I am using if anyone is interested.

 

**Using LabVIEW 2011**

0 Kudos
Message 1 of 8
(7,362 Views)

LabViewer77,

 

Here's a great DevZone document that talks about communicating with Bluetooth in LabVIEW. If the communication between the BT dongle and the Arduino is working successfully, then using LabVIEW to send commands should be possible.

 

http://zone.ni.com/devzone/cda/tut/p/id/3260

 

Hope this helps!

Robert B
RF Product Support Engineer
National Instruments
0 Kudos
Message 2 of 8
(7,331 Views)

Can you share some of your code?

 

The one time I tried a BlueTooth connection with a serial port, we found that there was a very high delay just from the converter.  So you need a high timeout or give a good wait before reading the data.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 3 of 8
(7,328 Views)

 

 

hello I've also worked with the device by connecting it with a usb dongle tramsmisor, you must first configure the drivers

1.jpg

 

USB Bluetooth Dongle (Genérico) http://depositfiles.org/files/5ilr2sujy

 

 

2.jpg

 

 

then you get the port address assigned by windows WILL NEED pair the devices from the computer, for that at all times the shield should be connected to the Arduino and Arduino with energy, do not forget to come junpers and configuration in the shield

0 Kudos
Message 4 of 8
(7,301 Views)

Hey guys.  Thanks for getting back to me.

 

So I found out the shield has a status pin that turns on when a connection is established, so I have been using it to test connectivity.  I ran the pin through an LED, which turns on when I connect to the COM port using that COM terminal program that I mentioned I used my posts, so I know there is a connection being made between Bluetooth and the dongle.  Now I need to figure out how to use it with LabView.

 

When I try to connect over Bluetooth to LabView, I go into the Instrument I/O Assistant to set the COM5 (the com port my BT shield is using).  Here is how I go about trying to connect:

 

1. I reset my BT shield to put it in an inquirable state

2.  I refresh the COM port list in order to select COM5 

 

[At this point, the status LED blinks on and then back off (making me think that it sees the connection, but then ends it).  It is also worth noting that when I click the Refresh button, LabView freezes for a few seconds while the LED blinks on and then off.]

 

I cannot open the properties of the COM I have selected (clicking the little blue hand next to my list of COM ports).  It says instead "Configure the selected instrument in Measurement & Automation Explorer in order to view its properties." which is confusing to me because isn't that the little blue hand that I clicked on?

 

Hopefully this information is helpful to you.  LabView is relatively new to me, so any information is helpful.  I  feel like I am really close.  Attached is the VI I am using.

 

Thanks,

LabViewer77

 

 

 

0 Kudos
Message 5 of 8
(7,243 Views)

LabViewer77,

 

I've found a Knowledge Base article that talks about using LabVIEW to connect with the Arduino over Bluetooth. Below is the link. It uses the LabVIEW Interface for Arduino (LIFA). I've included a link to that page as well. 

 

How Do I Setup the LabVIEW Interface for Arduino to use a Bluetooth Connection to my Arduino?

http://digital.ni.com/public.nsf/allkb/D86D6E2927F9C37A8625788E0077E86B?OpenDocument

 

LabVIEW Interface for Arduino

https://decibel.ni.com/content/groups/labview-interface-for-arduino

 

I hope this helps!

Robert B
RF Product Support Engineer
National Instruments
0 Kudos
Message 6 of 8
(7,209 Views)
Hi! Please I need your help. Well I'm using arduino (uploaded lifa base with out modifiy) a Bluetooth module (HC-06) connected to Arduino board and one ultrasonic sensor that activate or deactivated two relays, through android app I want to control that relays apart from labview.. I've done .vi that works with arduino for control manually the on /off of relays and works fine after probe the circuit with BT module and android app and works ok, the problem is when I want to join all.. BT module, arduino with lifa (modify) and labview.. There are no errors but the communication is not established.. Sorry for my english.
0 Kudos
Message 7 of 8
(6,059 Views)

Hi mdperez_ec,

 

I'd encourage you to post your question to the community group for the LabVIEW Interface for Arduino. The group is monitored by NI Developers who work with the interface and by other members of the LabVIEW community who are currently using it; you'll likely get a better response there than you will on this old thread.

 

Regards,

Ryan K.
Product Manager, ATCA and BEEcube
National Instruments
0 Kudos
Message 8 of 8
(6,013 Views)