index.php 7.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253
  1. <html>
  2. <head>
  3. <link rel="shortcut icon" href="pics/KATRINlogo.ico" />
  4. <link href="stylesheet.css" rel="stylesheet">
  5. <link rel="preload" href="CorporateESC-Bold.woff" as="font" type="font/woff" crossorigin>
  6. <link rel="preload" href="CorporateESC-Bold.woff2" as="font" type="font/woff2" crossorigin>
  7. <title>KATRIN Spectrometer and Detector Section Status Overview</title>
  8. <style>
  9. /*
  10. http://meyerweb.com/eric/tools/css/reset/
  11. v2.0 | 20110126
  12. License: none (public domain)
  13. */
  14. /* sub excluded */
  15. html, body, div, span, applet, object, iframe,
  16. h1, h2, h3, h4, h5, h6, p, blockquote, pre,
  17. a, abbr, acronym, address, big, cite, code,
  18. del, dfn, em, img, ins, kbd, q, s, samp,
  19. small, strike, strong, sup, tt, var,
  20. b, u, i, center,
  21. dl, dt, dd, ol, ul, li,
  22. fieldset, form, label, legend,
  23. table, caption, tbody, tfoot, thead, tr, th, td,
  24. article, aside, canvas, details, embed,
  25. figure, figcaption, footer, header, hgroup,
  26. menu, nav, output, ruby, section, summary,
  27. time, mark, audio, video {
  28. margin: 0;
  29. padding: 0;
  30. border: 0;
  31. font-size: 100%;
  32. font: inherit;
  33. vertical-align: baseline;
  34. }
  35. /* HTML5 display-role reset for older browsers */
  36. article, aside, details, figcaption, figure, footer, header, hgroup, menu, nav, section {display: block;}
  37. body {line-height: 1;}
  38. /*
  39. ol, ul {list-style: none;}
  40. blockquote, q {quotes: none;}
  41. blockquote:before, blockquote:after,q:before, q:after {content: '';content: none;}
  42. table {border-collapse: collapse;border-spacing: 0;}
  43. */
  44. h1 {
  45. position: relative;
  46. background: #B3D8CC;
  47. font-size: 36px;
  48. color: #fff;
  49. padding: 0px 10px;
  50. margin: -10 0px 0px 0px;
  51. }
  52. h2 {
  53. position: relative;
  54. background: #B3D8CC;
  55. font-size: 14px;
  56. color: #000;
  57. padding: 2px 10px;
  58. margin: 0 0px 0px 0px;
  59. }
  60. h3 {
  61. position: relative;
  62. background: #B3D8CC;
  63. font-size: 16px;
  64. color: #000;
  65. padding: 10px 10px;
  66. margin: 0 0px 0px 0px;
  67. }
  68. h4 {
  69. position: relative;
  70. background: #fff;
  71. font-size: 16px;
  72. color: #000;
  73. padding: 2px 10px;
  74. margin: 0 0px 0px 0px;
  75. }
  76. .letters {font-size: 25px; margin-bottom: 20px;}
  77. .s10:before {content: '10px';}
  78. .s11:before {content: '11px';}
  79. .s12:before {content: '12px';}
  80. .s14:before {content: '14px';}
  81. .s18:before {content: '18px';}
  82. .s24:before {content: '24px';}
  83. .s30:before {content: '30px';}
  84. .s36:before {content: '36px';}
  85. .s48:before {content: '48px';}
  86. .s60:before {content: '60px';}
  87. .s72:before {content: '72px';}
  88. .s10:before, .s11:before, .s12:before, .s14:before, .s18:before, .s24:before, .s30:before, .s36:before, .s48:before, .s60:before, .s72:before {
  89. font-family: Arial, sans-serif; font-size: 10px; font-weight: normal; font-style: normal; color: #999; padding-right: 6px;}
  90. pre {display: block;padding: 9px;
  91. margin: 0 0 12px;font-family: Monaco, Menlo, Consolas, "Courier New", monospace;font-size: 13px;line-height: 1.428571429;color: #333;font-weight: normal;font-style: normal;background-color: #f5f5f5;border: 1px solid #ccc;overflow-x: auto;border-radius: 4px;}
  92. /* responsive */
  93. @media (max-width: 959px) {.page {width: auto;margin: 0;}}
  94. </style>
  95. <style type="text/css">
  96. body { font-family:Calibri,Arial; }
  97. a:link { text-decoration:none; }
  98. a:visited { text-decoration:none; }
  99. a:hover { text-decoration:none; }
  100. a:active { text-decoration:none; }
  101. a:focus { text-decoration:none; }
  102. </style>
  103. <head>
  104. <link rel="artwork" href="pics/beamline_noMoS.png" />
  105. <link rel="artwork" href="pics/spectrometer2019.png" />
  106. <link rel="artwork" href="pics/katrin_logo_round.png" />
  107. <link rel="artwork" href="pics/newEmail.png" />
  108. <!--
  109. <style>
  110. body {
  111. background-image: url("pics/bg.png");
  112. background-repeat: no-repeat;
  113. }
  114. </style>
  115. -->
  116. </head>
  117. <?php
  118. //echo "test: ". $_GET["time"].PHP_EOL;
  119. // get client ip adress to check whether computer is on-site or not
  120. if (!empty($_SERVER['HTTP_CLIENT_IP'])) {
  121. $ip = $_SERVER['HTTP_CLIENT_IP'];
  122. } elseif (!empty($_SERVER['HTTP_X_FORWARDED_FOR'])) {
  123. $ip = $_SERVER['HTTP_X_FORWARDED_FOR'];
  124. } else { $ip = $_SERVER['REMOTE_ADDR']; }
  125. $onsite = false;
  126. $slowrefresh = false;
  127. if ((substr($ip, 0, 6) == "141.52") or (substr($ip, 0, 6) == "172.30"))
  128. { if (substr($ip, 0, 9) == "141.52.16")
  129. { echo '<meta http-equiv="refresh" content="10">'; $onsite = true; }
  130. else echo '<meta http-equiv="refresh" content="30">'; $onsite = true; }
  131. else { echo '<meta http-equiv="refresh" content="120">'; $slowrefresh= true; }
  132. ?>
  133. </head>
  134. <body style="background-color:white;">
  135. <?php
  136. // set time zone to local German time
  137. date_default_timezone_set('Europe/Berlin');
  138. // include helper functions
  139. include "SDS_status_functions.php";
  140. // include channel list
  141. include "SDS_status_channels.php";
  142. // include aircoil settings
  143. include "aircoils_settings.php";
  144. // include mac-e filter settings
  145. include "mace_settings.php";
  146. // include HV data
  147. if ((include "ADEI_HV_readings.php") == 0)
  148. { usleep(400000); include "ADEI_HV_readings.php"; };
  149. // read cached ADEI data
  150. $valuesincluded = 0;
  151. $loop = 0;
  152. $includeflag = 0;
  153. do {
  154. $includeflag = include 'ADEIvalues.php';
  155. $loop++;
  156. if ($valuesincluded == 0) usleep(100000);
  157. }
  158. while (($loop < 21) && ($includeflag+$valuesincluded < 2));
  159. if ($valuesincluded == 0) $extraction_time = "Request timed out!".PHP_EOL;
  160. //echo $loop." ".$includeflag." ".$valuesincluded.PHP_EOL;
  161. // ########## TIME STAMP ##########
  162. // echo '<font size="6" color="#FF0000"><b>Deprecated KATRIN Spectrometer and Detector Section Status Overview</b></font><br>';
  163. echo '<h3 style="font-family: CorporateESC; font-weight: bold; font-style: normal;">KATRIN - Karlsruhe Tritium Neutrino Experiment</h3>';
  164. echo '<h1 style="font-family: CorporateESC; font-weight: bold; font-style: normal;">Spectrometer and Detector Section Status Overview</h1>';
  165. echo '<h2 style="font-family: inherit; font-weight: plain; font-style: normal;">Page refreshed:&emsp;' . date(DATE_RFC850) . '</h2>';
  166. echo '<h2 style="font-family: inherit; font-weight: plain; font-style: normal;">Data extracted:&ensp;&thinsp;&thinsp;&thinsp;&thinsp;' . $extraction_time . '</h2>';
  167. echo '<font size="3" color="#FFFFFF">&emsp; &emsp; &emsp; Client IP:' . $ip . ' </font><br>';
  168. echo '<font size="3" color="#FFFFFF">&emsp; &emsp; &emsp; Uptime:' . @file_get_contents( "/proc/uptime") . ' </font><br>';
  169. //('. date("s", time() - $extraction_timestamp).'&thinsp;s old data)<br>';
  170. if ($errorcount >0) echo "<br> <br> <br> <br> <br> <br> <br> <br>".$errormessage;
  171. ?>
  172. <!--
  173. <div style="position:absolute; top:0px; left:0px">
  174. <img src="pics/bg.png">
  175. -->
  176. <div style="position:absolute; top:150px; left:2px">
  177. <img src="pics/beamline_noMoS.png" >
  178. <div style="position:absolute; top:15px; left:314px">
  179. <img src="pics/spectrometer2019.png" width="1132" height="601">
  180. </div>
  181. <div style="position:absolute; top:-148px; left:1625px">
  182. <img src="pics/katrin_logo_round.png" width="93" height="93">
  183. </div>
  184. <!--
  185. <div style="position: absolute; top: 60px; left:1680px">
  186. <iframe src="https://uhr.ptb.de" scrolling="no" style="height: 230px; border: 0px none; width: 230px; margin-bottom: 0px; margin-left: 0px;">
  187. </iframe>
  188. </div>
  189. -->
  190. <a href="mailto:thuemmler@kit.edu">
  191. <div title="send email to Thomas Thuemmler" style="position:absolute; top:-50px; left:8px">
  192. <img src="pics/newEmail.png" width="23" height="23">
  193. </div>
  194. </a>
  195. <?php
  196. // include SDS status main page
  197. //if (($valuesincluded == 1) & ($onsite)) include "SDS_status_main.php";
  198. if ($valuesincluded == 1) include "SDS_status_main.php";
  199. ?>
  200. <br><br><br>
  201. <!--
  202. <iframe width="1700" height="400" src="https://dataview.raspberryshake.org/#/embed/AM/R985B/00/EHZ"></iframe>
  203. -->
  204. </body>
  205. </html>