I am new to the LabVIEW community and am trying to determine if the LabVIEW ecosystem will be suitable to implement as a standard within the company I work for.
I have two questions:
- Can an NXG created web application allow the user to send commands/set parameters for the FPGA on a cRIO controller? For our application we are trying to use the cRIO to monitor a few inputs and control a few outputs in a sequence, but need to be able to adjust virtual point parameters such as a timer duration or measurement cutoff limit to stop the program.
- Can a web application which has been deployed to a cRIO be used standalone with any PC with only a browser and no additional modules? Here I found some good information on this https://www.ni.com/documentation/en/labview-web-module/latest/manual/use-web-app-with-crio/ I am wondering if it is possible for me to develop a web application in NXG on my hardware, deploy that package to the cRIO, while having the same control detailed above, and be able to use an ethernet connection from the cRIO to a PC, without any LabVIEW licenses or drivers, in order to use the web app front end.
The help topic Hosting a LabVIEW Web Service and an NXG Web VI in a Remote System describes the use case of running a LabVIEW application (in this case a LabVIEW Web Service) and using a LabVIEW NXG-based web application UI on a cRIO.
Some key bits to point out in that topic is the link to the Call LabVIEW Web Service example and that your case describes the "second approach" in the topic which discusses adding the built web application as a Public Content folder for the web service on the cRIO.
Can an NXG created web application allow the user to send commands/set parameters for the FPGA on a cRIO controller?
The web application does not talk directly to the hardware on the cRIO. Instead the web application makes HTTP requests to a LabVIEW Web Service and the LabVIEW Web Service can communicate with the hardware on the cRIO using LabVIEW's APIs.
Can a web application which has been deployed to a cRIO be used standalone with any PC with only a browser and no additional modules?
Yep! Because the web application communicates over standard browser protocols like HTTP to the LabVIEW web service on the cRIO no special plugins are needed by the PC or mobile devices. NXG built web applications run without plugins on modern web browsers.
Thank you for your reply and the information you provided.
Based on my lack of knowledge I think I worded my first question incorrectly. However your response does clear up how these actions are carried out which is very helpful.
I think in the simplest terms what I want to know overall is: if the user can command outputs on a cRIO from a web application deployed on that controller with only an ethernet connection to an isolated PC having a browser but otherwise no LabVIEW plugins or internet access.
Is this possible? I would think not unless the LabVIEW Web Service runs locally on the controller. Is that deployed with the web app when it's deployed to the controller? My knowledge of the software behind all this is limited. I mostly work with hardware and local hardware programming.
Any more info on this would be greatly appreciated.
the short answer is yes. it can work as you describe.
it can also work when the host site is not the cRIO target.
if the cRIO supports a series of web services, a website can be hosted on the same cRIO that delivers the web content that presents and calls the web services on the cRIO.
the details are more complicated the concept certainly works.