LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Create Communication Reference for UART Serial COM and ETHERNET

Hi All,

 

I am developing a LV drivers for the device for which works on the both Serial COM and Ethernet. Commands used for both protocol are same just the commumcation choices are different.

 

As it would be difficult to maintain, I do not want to develope drivers separtely for Serail COM and Ethernet so I must use the communcation reference for that, I plan to generate this reference in Initialize.vi  and further this reference is used for the communcation.

 

How to generate this communcation rference ?

 

Thank you.

 

-Amit

-
Amit
CLAD
0 Kudos
Message 1 of 6
(3,302 Views)
Just use VISA. Hundreds of instrument drives are doing exactly that. They also support GPIB and USB. You've got the 34401 example to look at. Anyone who creates instrument drivers should be aware of VISA.
0 Kudos
Message 2 of 6
(3,291 Views)

Hi,

 

Thank you for your answer, I do not want to use ONLY VISA, I agree most of the driver user knows about VISA very well but here my concern is to

 

make the common driver both for COM port and Ethenet, just in Init.vi, I will select the COM or Ehtenet with proper inputs and accordingly

 

communciation reference will be generated and the same communcation reference I will use for the further functionality (at that time, I do not

 

care aobut what I am using COM or Ethernet as I have reference genered in Init,vi and I did input this reference for further VIs).

 

is it possible to do so  ?

 

Thank you.

 

-
Amit
CLAD
0 Kudos
Message 3 of 6
(3,267 Views)

@amitwadje wrote:

Hi,

 

Thank you for your answer, I do not want to use ONLY VISA, I agree most of the driver user knows about VISA very well but here my concern is to

 

make the common driver both for COM port and Ethenet, just in Init.vi, I will select the COM or Ehtenet with proper inputs and accordingly

 

communciation reference will be generated and the same communcation reference I will use for the further functionality (at that time, I do not

 

care aobut what I am using COM or Ethernet as I have reference genered in Init,vi and I did input this reference for further VIs).

 

is it possible to do so  ?

 

Thank you.

 


And VISA was speciifically designed to abstract the actual hardware interface away. It incidentially supports serial, GPIB, USB, AND TCP/IP for exactly that reason. Your Iniitilize.vi has to do only a little work to initialize certain aspects of VISA according to the used interface such as possible message termination and serial port parameters and the rest of the instrument driver simply gets the VISA reference and does its thing and doesn't have to worry at all if it should use the Serial COMM reference or rather the TCP/IP reference. In LabVIEW accessing Serial COMM without VISA is anyhow quite a bit of extra work.

Rolf Kalbermatter
My Blog
Message 4 of 6
(3,248 Views)

@amitwadje wrote:

Hi,

 

Thank you for your answer, I do not want to use ONLY VISA, I agree most of the driver user knows about VISA very well but here my concern is to

 

make the common driver both for COM port and Ethenet, just in Init.vi, I will select the COM or Ehtenet with proper inputs and accordingly

 

communciation reference will be generated and the same communcation reference I will use for the further functionality (at that time, I do not

 

care aobut what I am using COM or Ethernet as I have reference genered in Init,vi and I did input this reference for further VIs).

 

is it possible to do so  ?

 

Thank you.

 


Just goes to show you don't know what you are talking about.

The next time you contradict somehow be sure you have the information to make a correct response.

 

0 Kudos
Message 5 of 6
(3,219 Views)

Hi,

 

some misunderstanding about VISA concept, now its clear.


Thnak you all.

-
Amit
CLAD
0 Kudos
Message 6 of 6
(3,193 Views)