Our full technical support staff does not monitor this forum. If you need assistance from a member of our staff, please submit your question from the Ask a Question page.


Log in or register to post/reply in the forum.

Several CSI Web server questions


mwassmer Aug 15, 2012 11:20 PM

I have a few questions regarding CSI Web server. Please let me know if you'd prefer that I re-ask these questions in five separate posts. FYI, I'm running the trial version of RTMC Pro v4.0 on Windows Server 2008 R2.

My questions are:

1) Regarding security: After a couple hours of troubleshooting, I eventually discovered that I couldn't rely on IIS' "World Wide Web Services (HTTP traffic-in)" firewall rule to allow TCP port 80 traffic in to CSI Web server, presumably because the "Program" field for that rule is set to "System." CSI Web server worked when I created a new firewall rule with the "Program" field set to "Any". In both cases, the TCP port was 80. My question: Is there a specific program file I should enter instead of "Any" in order to reduce my attack surface area?

2) I apologize for this novice question, but does CSI Web server have to run independent of IIS, Apache, etc? In other words, is it possible for IIS to serve up RTMC pages? The ability to do so would help me better integrate my RTMC pages with the rest of my site, which is served up by IIS.

3) Regarding customization: The Web Publisher appears to overwrite the contents of the designated site folder every time I click "Publish Website". Does this mean that I cannot customize the Web pages that CSI Web server creates? For example, I'd like to be able to put a banner over the screen tabs. I'd also like to customize the appearance of the "Data Browse" tab and do some other things to give the RTMC pages the same look and feel as the rest of my site.

4)Is it possible/allowable to change the "CS" favicon logo to my own company logo? If so, where is that image setting located in the code?

5) Regarding the polling interval: If I set the polling interval to 1 minute, how many seconds into each minute will the polling occur? In my case, LoggerNet is collecting new data from the CR1000 every minute. My "base time" in the Setup client is set to 12:00:05 so that my program has time to complete at the top of each minute before I collect that minute's data. That's how I get my "quasi" real-time data from the CR1000. Obviously, I'd like the Web page polling to occur as soon as possible after the new data arrives in the LN cache. I suppose I could accomplish this by setting the polling interval to 1 second, but this would mean that 59 out of every 60 polls would be wasted because there is new data arriving only once per minute.

* Last updated by: mwassmer on 8/15/2012 @ 5:25 PM *


jtrauntvein Aug 17, 2012 03:16 PM

1) Regarding security: After a couple hours of troubleshooting, I eventually discovered that I couldn't rely on IIS' "World Wide Web Services (HTTP traffic-in)" firewall rule to allow TCP port 80 traffic in to CSI Web server, presumably because the "Program" field for that rule is set to "System." CSI Web server worked when I created a new firewall rule with the "Program" field set to "Any". In both cases, the TCP port was 80. My question: Is there a specific program file I should enter instead of "Any" in order to reduce my attack surface area?

The name of the service would be CsiWebServer.exe. If you have to specify the full path, the default path would be "c:\program files\campbellsci\CsiWebServer\CsiWebServer.exe" (on a 64 bit machine, replace "program files" with "program files(x86)". If you want the CsiWebServer to co-exist with another web server such as IIS, you will need to change the port that CsiWebServer listens on (I would suggest port 8080). This can be accomplished by editing the CSI web server's config file or by running the CsiWebAdmin utility.

2) I apologize for this novice question, but does CSI Web server have to run independent of IIS, Apache, etc? In other words, is it possible for IIS to serve up RTMC pages? The ability to do so would help me better integrate my RTMC pages with the rest of my site, which is served up by IIS.

In its present incarnation, the CsiWebServer can only be configured to be a standalone web server. RTMC run time does have the ability to periodically generate web pages from the project and to transfer these files to an FTP server. If you want the interactivity that is possible with the CsiWebServer, you can use iframes in your web pages that can reference pages served by the CsiWebServer.

3) Regarding customization: The Web Publisher appears to overwrite the contents of the designated site folder every time I click "Publish Website". Does this mean that I cannot customize the Web pages that CSI Web server creates? For example, I'd like to be able to put a banner over the screen tabs. I'd also like to customize the appearance of the "Data Browse" tab and do some other things to give the RTMC pages the same look and feel as the rest of my site.

See my note on using iframes above.

4)Is it possible/allowable to change the "CS" favicon logo to my own company logo? If so, where is that image setting located in the code?

The CsiWebServer is designed so that, if a file named "favicon.ico" is present in its root directory, that file will be served in preference to the internal icon.

5) Regarding the polling interval: If I set the polling interval to 1 minute, how many seconds into each minute will the polling occur? In my case, LoggerNet is collecting new data from the CR1000 every minute. My "base time" in the Setup client is set to 12:00:05 so that my program has time to complete at the top of each minute before I collect that minute's data. That's how I get my "quasi" real-time data from the CR1000. Obviously, I'd like the Web page polling to occur as soon as possible after the new data arrives in the LN cache. I suppose I could accomplish this by setting the polling interval to 1 second, but this would mean that 59 out of every 60 polls would be wasted because there is new data arriving only once per minute.

Since you appear to be discussing a LoggerNet data source, I assume that the polling interval is the one that you specified when you published the RTMC project. This intrval governs the rate at which the web page will poll the web server for new data and apparently does not use any fixed base other than the time at which the web page was loaded. Depending upon the amount of data being transferred for the web page, a polling interval of 10-15 seconds may be acceptable.


mwassmer Aug 18, 2012 10:46 PM

Thank you very much! Your replies make a lot of sense.
I did want to get a little more clarification on #3, though. Thanks to your reply, I now think I understand the role that iframes can play in what I'm trying to do. However, unless I am mistaken, that will still not enable me to actually modify or supplement any of the RTMC Web server-generated HTML documents to do things like adjust fonts, add little jQuery "info" pop-ups to provide explanations for certain readings for the users, etc. Is that correct?

If I'm correct that it is not possible to modify the RTMC Web server-generated HTML, can you think of a reasonable workaround to do something like adding help popups? Could I do something like using CSS to position the help icon on top of the iframe?

* Last updated by: mwassmer on 8/18/2012 @ 4:49 PM *


jtrauntvein Aug 20, 2012 03:10 PM

The web page generated by RTMC is basically a shell that creates an HTML5 canvas element of a size specified by the project and imports a javascript module that contains the actual code for the project. Since there is only one canvas element, there is really nothing in the DOM that you can manipulate. That said, all of the controls in RTMC allow you to specify fonts, colours, and other appearance parameters.

One of the features that RTMC pro has is the ability to embed "hot spots" inside of the project. These hot spots have the ability to embed an HTML link within the project and allows your project to specify the value of the href attribute. You could specify something like the following for the link attribute:

javascript:alert("This measurement is beyond cool!")

If the user clicked on that hotspot, the browser would then show the content in an alert dialogue.


mwassmer Aug 20, 2012 04:20 PM

Terrific! Thanks again.

Log in or register to post/reply in the forum.