123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130 |
- <html>
- <head>
- <title>KATRIN Spectrometer and Detector Section Status Overview</title>
- <style type="text/css">
- body { font-family:Calibri,Arial; }
- a:link { text-decoration:none; }
- a:visited { text-decoration:none; }
- a:hover { text-decoration:none; }
- a:active { text-decoration:none; }
- a:focus { text-decoration:none; }
- </style>
- <head>
- <link rel="stylesheet" href="pics/beamline_noMoS.png" />
- <link rel="stylesheet" href="pics/spectrometer.png" />
- <link rel="stylesheet" href="pics/katrin_logo.jpg" />
- <link rel="stylesheet" href="pics/newEmail.png" />
- <style>
- body {
- background-image: url("pics/bg.png");
- background-repeat: no-repeat;
- }
- </style>
- </head>
- <?php
- // get client ip adress to check whether computer is on-site or not
- if (!empty($_SERVER['HTTP_CLIENT_IP'])) {
- $ip = $_SERVER['HTTP_CLIENT_IP'];
- } elseif (!empty($_SERVER['HTTP_X_FORWARDED_FOR'])) {
- $ip = $_SERVER['HTTP_X_FORWARDED_FOR'];
- } else { $ip = $_SERVER['REMOTE_ADDR']; }
- $onsite = false;
- $slowrefresh = false;
- if (substr($ip, 0, 6) == "141.52")
- { if (substr($ip, 0, 9) == "141.52.16")
- { echo '<meta http-equiv="refresh" content="10">'; $onsite = true; }
- else echo '<meta http-equiv="refresh" content="30">'; $onsite = true; }
- else { echo '<meta http-equiv="refresh" content="120">'; $slowrefresh= true; }
- ?>
- </head>
- <body style="background-color:black;">
- <?php
- // set time zone to local German time
- date_default_timezone_set('Europe/Berlin');
- // include helper functions
- include "SDS_status_functions.php";
- // include channel list
- include "SDS_status_channels.php";
- // include aircoil settings
- include "aircoils_settings.php";
- // include HV data
- if ((include "ADEI_HV_readings.php") == 0)
- { usleep(400000); include "ADEI_HV_readings.php"; };
- // read cached ADEI data
- $valuesincluded = 0;
- $loop = 0;
- $includeflag = 0;
- do {
- $includeflag = include 'ADEIvalues.php';
- $loop++;
- if ($valuesincluded == 0) usleep(100000);
- }
- while (($loop < 21) && ($includeflag+$valuesincluded < 2));
- if ($valuesincluded == 0) $extraction_time = "Request timed out!".PHP_EOL;
- //echo $loop." ".$includeflag." ".$valuesincluded.PHP_EOL;
-
- // ########## TIME STAMP ##########
- echo '<font size="6" color="#000000"><b>KATRIN Spectrometer and Detector Section Status Overview</b></font><br>';
- echo '<font size="4" color="#000000">Page refreshed: ' . date(DATE_RFC850) . '</font><br>';
- echo '<font size="4" color="#000000">Data extracted:    ' . $extraction_time . ' </font><br>';
- echo '<font size="4" color="#FFFFFF">      Client IP:' . $ip . ' </font><br>';
- //('. date("s", time() - $extraction_timestamp).' s old data)<br>';
- if ($errorcount >0) echo "<br> <br> <br> <br>".$errormessage;
- ?>
- <!--
- <div style="position:absolute; top:0px; left:0px">
- <img src="pics/bg.png">
- -->
-
- <div style="position:absolute; top:150px; left:0px">
- <img src="pics/beamline_noMoS.png">
- <div style="position:absolute; top:20px; left:315px">
- <img src="pics/spectrometer.png" width="1130" height="596">
- </div>
- <div style="position:absolute; top:-140px; left:1585px">
- <img src="pics/katrin_logo.jpg" width="100" height="100">
- </div>
- <!--
- <div style="position: absolute; top: 60px; left:1670px">
- <iframe src="https://uhr.ptb.de" scrolling="no" style="height: 230px; border: 0px none; width: 230px; margin-bottom: 0px; margin-left: 0px;">
- </iframe>
- </div>
- -->
- <a href="mailto:thuemmler@kit.edu">
- <div title="send email to Thomas Thuemmler" style="position:absolute; top:-50px; left:8px">
- <img src="pics/newEmail.png" width="23" height="23">
- </div>
- </a>
- <?php
- // include SDS status main page
- if ($valuesincluded == 1) include "SDS_status_main.php";
- ?>
- </body>
- </html>
|