Use Remote Front Panels without LabVIEW Development System 您所在的位置:网站首页 labview控制网页 Use Remote Front Panels without LabVIEW Development System

Use Remote Front Panels without LabVIEW Development System

2024-07-16 18:55| 来源: 网络整理| 查看: 265

Follow the next procedure to create and deploy a LabVIEW Standalone Application (Executable) that includes Remote Front Panels: Create a LabVIEW project.Enable the Web Server by selecting Tools»Options»Web Server (or Web Server: Configuration).  LabVIEW 2010 and later: Select Enable Remote Panel Server and click OK.Select Remote front panels under Remote Panel Server.Note that the default HTTP port is 8000. LabVIEW 2009 and earlier: Select Enable Web Server and click OK.Allow access for Remote front panels under Advanced Settings.Note that the default HTTP port is 80. Add your source code to the project.Build the web page for your VI:  Select Tools»Web Publishing Tool...Select the VI to publish from the VI name drop-down menu.Configure the Viewing Mode as either Embedded, Snapshot, or Monitor and click Next.Edit the Document title, Header, and Footer and click Next.Ensure that the HTML document is saved in your C:\Program Files\National Instruments\\www directory and click Save to Disk.Note the Document URL for use in step 10. Add the HTML document from step 4 to Project Explorer by right-clicking My Computer and selecting Add»File and then select the HTML file from your C:\Program Files\National Instruments\\www directory.   Save your project and build your executable by right-clicking Build Specifications and selecting New»Application (EXE). Select the Source Files category. Then, place your top level VI under Startup VIs and your HTML file under Always Included. Click Build and then click Done when the build is complete.   Copy the executable and all of the generated files to your target computer. Note: The target computer must have the LabVIEW Run-Time Engine installed and it must match the version of LabVIEW used to develop the executable.On the target computer, browse to the directory where you just copied your executable. Open the .ini file in a text editor. On a Mac OS, this will be the .app x.x Preferences file, where x.x is the LabVIEW version. Perform the following:  Verify the token WebServer.Enabled=True exists. If you cannot find it, add it to the end of the file.   Versions of LabVIEW released prior to 8.6: a. Add or modify the WebServer.RootPath so that its value is set to the directory where the HTML page currently resides (it should be located in the application's data directory). b. Save the changes to the .ini file and close it. LabVIEW 8.6 and later: a. Close the .ini file and open niwebserver.conf in a text editor. This file was created to handle the new functionality provided by the LabVIEW web server in LabVIEW 8.6.b. If you do not haveniwebserver.conffile in your application directory launch your executable once and it should be created. After the .conf file is created shut down your executable.c. In the second section labeled Directives that apply to the default server there is a DocumentRoot tag. Replace the default LabVIEW\www with the directory where the HTML page currently resides (it should be located in the application's data directory).  Do not include the name of the html file.   Run the executable on the target computer.Replace the name of the development computer in the URL from Step 4 with the IP address of the target computer and navigate to this address in a web browser on a different computer than the one running the executable. You can now view and control the LabVIEW executable remotely. Note: If you present any issues during the deployment consult the Troubleshooting articles located in the Related Links section. Use Remote Panels with Installers To enable remote front panels for an installer, the same ideas apply. Create a web page. Include the web page in your project. Build your executable and include your web page in the support files. Create an installer and include your executable in the installer under the source files setting of the installer. Build and deploy the installer. Lastly, change the .ini and niwebserver.conf files. Licensing By default, versions of LabVIEW prior to 2011 include one remote front panel license. This means that one connection at a time can be made to the remote front panel of your executable. If you have LabVIEW Professional Edition you are entitled to five licenses for remote panels. To have access to these additional licenses (or any others that you may have purchased), you need to build an installer that contains your executable along with the LabVIEW Deployable License under Additional Installer.  To purchase additional licenses for versions of LabVIEW prior to 2011, use part number 781841-3599.  Versions of LabVIEW 2011 and later do not require any licenses for remote front panels, so there is no need to include licenses in the installer.

Note: A LabVIEW web server cannot permit more than one connection if Volume License Manager is in use on the same computer. This is due to the fact that remote front panel licenses share components with the Volume License Manager.



【本文地址】

公司简介

联系我们

今日新闻

    推荐新闻

    专题文章
      CopyRight 2018-2019 实验室设备网 版权所有