Commit 4a245341 authored by Benoit Rat's avatar Benoit Rat

www: update fields with new wrs_version

parent fb3b56be
......@@ -19,15 +19,15 @@
<h1 class="title">About</h1>
<?php $_SESSION['advance']=""; ?>
<div>
<?php
$msg = shell_exec("/wr/bin/wrs_version -g");
$msg = shell_exec("/wr/bin/wrs_version -t");
$msg = explode("\n", $msg);
$message .= "<ul>";
$message .= "<li>WRSW OS:".shell_exec("uname -r")."</li>";
for($i=0; $i<5; $i++){
$message .= "<li>wr-switch-os: ".shell_exec("uname -r")."</li>";
for($i=0; $i<count($msg)-1; $i++){
$message .= "<li>".$msg[$i]."</li>";
}
......
......@@ -151,15 +151,16 @@ function wrs_main_info(){
echo '<a href="showfile.php?help_id=gateware&name=GateWare Info" onClick="showPopup(this.href);return(false);">';
echo $str; echo '</a></td></tr>';
echo '<tr><td>PCB Version</td><td>'; $str = shell_exec("/wr/bin/wrs_version -p"); echo $str; echo '</td></tr>';
echo '<tr><td>HW Version</td><td>'; $str = shell_exec("/wr/bin/wrs_version -t | grep 'scb\|back' | sort -r | sed 's/-version: /: v/'"); echo str_replace("\n"," / ",rtrim($str)); echo '</td></tr>';
echo '<tr><td>FPGA</td><td>'; $str = shell_exec("/wr/bin/wrs_version -f"); echo $str; echo '</td></tr>';
echo '<tr><td>Manufacturer</td><td>'; $str = shell_exec("/wr/bin/wrs_version -t | grep 'manufacturer' | sed 's/[^:]*: //'"); echo str_replace("\n","",$str); echo '</td></tr>';
echo '<tr><td>Serial Number</td><td>'; $str = shell_exec("/wr/bin/wrs_version -t | grep 'serial' | sed 's/[^:]*: //'"); echo str_replace("\n","",$str); echo '</td></tr>';
echo '<tr><td>Compiling Date</td><td>'; $str = shell_exec("/wr/bin/wrs_version -c"); echo $str; echo '</td></tr>';
echo '<tr><td>White-Rabbit Date</td><td>'; $str = shell_exec("export TZ=".$_SESSION['utc']." /wr/bin/wr_date -n get"); echo str_replace("\n","<br>",$str); echo '</td></tr>';
echo '<tr><td>White-Rabbit Date</td><td>'; $str = shell_exec("export TZ=".$_SESSION['utc']."; /wr/bin/wr_date -n get"); echo str_replace("\n","<br>",$str); echo '</td></tr>';
echo '<tr><td>PPSi</td><td>'; echo wrs_check_ptp_status() ? '[<a href="ptp.php">on</A>]' : '[<a href="ptp.php">off</A>]'; echo '</td></tr>';
echo '<tr><td>Net-SNMP Server</td><td>'; echo check_snmp_status() ? '[on] ' : '[off] '; echo '&nbsp;&nbsp;ver. '; echo shell_exec("snmpd -v | grep version | awk '{print $3}'");
echo '( port '; $str = shell_exec("cat ".$GLOBALS['etcdir']."snmpd.conf | grep agent | cut -d: -f3 | awk '{print $1}'"); echo $str; echo ')'; echo /*" <a href='help.php?help_id=snmp' onClick='showPopup(this.href);return(false);'> [OIDs]</a>*/"</td></tr>";
echo '<tr><td>NTP Server</td><td> <a href="management.php">'; $str = check_ntp_server(); echo $str; echo '</A> '.$_SESSION['utc'].'</td></tr>';
echo '<tr><td>Max. Filesize Upload</td><td>'; echo shell_exec("cat ".$GLOBALS['phpinifile']." | grep upload_max_filesize | awk '{print $3}'"); echo '</td></tr>';
echo '</table>';
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment