Web Services in LabVIEW
Web Services in LabVIEW
Using LabVIEW since 1993 (version 3.1). EE from MTU. Know some C, C++, C#, JavaScript but prefer LabVIEW. Believe there is nothing you cant do in LabVIEW (if you try hard enough!)
Medical Telecomm Software (using COM interfaces, XML) Network Servers (multiple simultaneous asyncronous DUTs from single TE)
Wikipedia:
a software system designed to
National Instruments:
more open and standard way to communicate with VIs
My Definition:
An API that allows (nearly) any language or tool to
NI.com Links
Web Services in LabVIEW http://zone.ni.com/devzone/cda/tut/p/id/7350 LabVIEW Web Services FAQ http://zone.ni.com/devzone/cda/tut/p/id/7747 LabVIEW Web Services Security http://zone.ni.com/devzone/cda/tut/p/id/7749
Sending Parameters
Must include httpRequestID if returning stream data Pitfalls
Cannot send case sensitive data (converts everything to lower case) Cannot send file paths (must use substitute for /, I like to use ~) Cannot send file names at end of call (browser will think it points to a file)
Returning Data
XML Format
Text Format
HTML Format
Cannot use normal methods (queues, notifiers) Calling interface VI with VI Server
VI must be in memory (how to accomplish this) See EXAMPLE - EXE with screenshot enabled.vi VI can push data into a queue. How to use queues to wait for a response (demo)
You can use any web enabled script or language to call your web service (makes your application scriptable)
important!)
Turn off the Web Server before you build
Custom Files you must include niwebserver.conf (how to create and edit, MIME issue) The www folder (and how to make it appear)
Passing in data (discussed above) Niwebserver.conf file tweaks The build process is a PITA (and very non-intuitive). Seems like distribution was an afterthought. Hope for the future? Double Installation issue Log folder missing
Hard to debug!
how this is done) Keeps the RESTful web server up and running. (see ini file) Deploys new web services you install automatically Provides some cool utilities!
Get a screenshot
Remote screen must be rendered (active user)
Create a Universal API Can access any LabVIEW application anywhere in the world Multiple access methods Not simple (yet) to use, but should get better Hard to debug! Only limited by your imagination