Real-Time Measurement and Control

cancel
Showing results for 
Search instead for 
Did you mean: 

end of file encountered error on real-time

Solved!
Go to solution

I am having ad issue with a deployment to a cFP controller. I had a successful deployment that needed a few tweeks. When I may a few changes I got some problems that resulted in a "end of file encountered" error. Here is what I know.

 

  1. Updated the cFP with System State Publisher
  2. Viewed CPU useage to be 100%
  3. Adjusted I/O polling rate to wait 10ms on cFP controller and applied changes in MAX
  4. Reviewed CPU useage to be 28%
  5. Made changes to time zone on controller to reflect EST vs default UTC and applied changes in MAX
  6. Made minor changes to subVI, which I am publishing as a remote front panel through a web browser, compiled and deployed to target.
  7. Tried to view new webpage and got message that 'server has regained control'.
  8. Redid web publishing tool to verify that I requested control of webpage automatically.
  9. Redeployed application and rechecked web page. Still 'server has regained control'
  10. Connection to target got continually more difficult. Eventually producing a 'Safe Mode, software error' displayed in MAX.
  11. Unistalled all OS and drivers on cFP.
  12. Reinstalled OS and all drivers on cFP.
  13. Redeployed application and webpage showed the subVI front panel,but it was before it was running i.e. I could see the Run button.
  14. I reloaded the webpage and then the subVI appeared to be running very slowly, with no control, and the data was not updating correctly. But no more 'server has gained control'. When I exit the program I get a 'end of ile encountered' error in a popup dialog.

I am running a very simply state machine setup with three loops. One to control the connection and TCP WRITE to an exe running on another machine. A second to control the connection and TCP READ to that same second machine. And a third loop to write some FALSE conditions to cFP modules, configure the 485 serial port, and then to launch and run the subVI which displays information via a webpage on a HMI. The subVI displays data from a SQL database which I am reading on that second machine and passing through to the cFP via TCP. Since the subVI has a problem loading in the webpage I figure the problem is in that loop. It could be related to the remote front panel code or could be in the code to call the subVI.

 

Any suggestrions? I don't have the hardware. Its deployed on a production line at a client. I am trying to get the hardware back in so I can debug with my development machine.

 

Doug

Doug Ferguson

www.southerndaqsolutions.com
0 Kudos
Message 1 of 4
(3,950 Views)

Hi Doug,

 

I have a couple of questions:

 

1.  What is the cFP controller and LabVIEW RT versions, etc.

2.  What do you mean by "control the connection"?  Does it have to do with clients connected to the RFP?

3.  Also, if the cFP is displaying information via webpage, are you referring to the RFP or is this a separate webpage hosted on the LVRT server?

 

I'm not quite sure where the problem is, but as far as debugging is concerned, you can try disabling some of the loops to see if performance improves.  You can also build a debuggable executable to try and debug the issue:  http://digital.ni.com/public.nsf/allkb/CE6C440EE28BDF9F8625714000746D15 

0 Kudos
Message 2 of 4
(3,928 Views)

cFP-2120 with LabVIEW 2009

 

Control the connection is the TCP connection through two ports to an exe running on another networked windows machine

 

The cFP is displaying the front panel of a subVI using remote front panel/web publishing tool functionality.

 

I will picking up the cFP to bring back to my office to debug.

Doug Ferguson

www.southerndaqsolutions.com
0 Kudos
Message 3 of 4
(3,916 Views)
Solution
Accepted by topic author DougFerguson

Ok, we finally got this solved. Thanks to the effort given by Roger Hebert of NI for the help.

 

It seems I had two problems. The first was a 0 bytes of 0 % downloaded problem. When I took the cFP off the deployed network and put it on my home network, I didn't remove the specified DNS server in the cFP setup page. Since it wasn't present on my local network, it couldn't download the web page properly. Unspecified the DNS server fixed that issue.

 

The second issue was this "server has regained control" followed by the "end of file" message. In my code I am publishing a subVI's front panel as a webpage. Its a single while loop that executes once and stores information shift registers. It is called repeatedly in a timed while loop from the top level VI. When the front panel appearance of the subVI was default it worked fine. But when I changed it to a dialog to hide the menu bar and run button, by default the "show front panel when called" and "close afterwards if originally closed" are checked in the VI window appearance properties. The "close afterwards if originally closed" caused all the problems. After it ran, it closed and released the control back to the server (cFP). When the top level loop called the subVI again it couldn't file the subVI, which had been closed.

 

Thanks to Roger for the patience to help me out on this. But who here understands the pharse "close afterwards if originally closed"?????????

Doug Ferguson

www.southerndaqsolutions.com
0 Kudos
Message 4 of 4
(3,800 Views)