]> jspc29.x-matter.uni-frankfurt.de Git - daqtools.git/commitdiff
adding registers for Pulser AddOn
authorJan Michel <j.michel@gsi.de>
Fri, 3 Jul 2015 15:58:06 +0000 (17:58 +0200)
committerJan Michel <j.michel@gsi.de>
Fri, 3 Jul 2015 15:58:16 +0000 (17:58 +0200)
web/htdocs/addons/pulseraddon.pl [new file with mode: 0755]
web/htdocs/index.pl
xml-db/database/Pulser.xml [new file with mode: 0644]

diff --git a/web/htdocs/addons/pulseraddon.pl b/web/htdocs/addons/pulseraddon.pl
new file mode 100755 (executable)
index 0000000..8620f92
--- /dev/null
@@ -0,0 +1,45 @@
+#!/usr/bin/perl
+if ($ENV{'SERVER_SOFTWARE'} =~ /HTTPi/i) {
+  print "HTTP/1.0 200 OK\n";
+  print "Content-type: text/html\r\n\r\n";
+  }
+else {
+  use lib '..';
+  use if (!($ENV{'SERVER_SOFTWARE'} =~ /HTTPi/i)), apacheEnv;
+  print "Content-type: text/html\n\n";
+  }
+
+use CGI ':standard';
+use XML::LibXML;
+use POSIX;
+use CGI::Carp qw(fatalsToBrowser);
+
+use lib qw|../commands htdocs/commands|;
+use xmlpage;
+
+my $page;
+
+$page->{title} = "Pulser AddOn";
+$page->{link}  = "../";
+
+my @setup;
+
+push(@setup,({name      => "Control", 
+              cmd       => "Pulser-0xfe61-GlobalConfig",
+              period    => 1000,
+              address   => 1}));
+
+push(@setup,({name      => "PulserConfig", 
+              cmd       => "Pulser-0xfe61-PulserConfig",
+              period    => 10000,
+              address   => 1}));
+              
+              
+xmlpage::initPage(\@setup,$page);
+
+
+1;
+
+
index 0b64274acf50db3ecdc8821f4fca33ce1d70a857..69782ad12953bc7aaf51a546f20ec5b94eedc740 100755 (executable)
@@ -96,6 +96,7 @@ The main documentation of the network can be found in these documents and locati
 <li><a href="tools/cbmmbs.pl">CBM-MBS Receiver</a>
 <li><a href="addons/adc.pl">48ch sampling ADC</a>
 <li><a href="addons/adc_cfd.pl">48ch sampling ADC CFD</a>
+<li><a href="addons/pulseraddon.pl">Pulser AddOn</a>
 <li><a href="network/generic.pl">Everything else</a>
 </ul>
 </div>
diff --git a/xml-db/database/Pulser.xml b/xml-db/database/Pulser.xml
new file mode 100644 (file)
index 0000000..c4b2b26
--- /dev/null
@@ -0,0 +1,73 @@
+<?xml version="1.0"  encoding="utf-8" ?>
+<TrbNetEntity xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+              xsi:noNamespaceSchemaLocation="../schema/TrbNetEntity.xsd"
+              name="Pulser"
+              address="a000"
+              >
+  <description>Pulse generator</description>
+
+  <group name="GlobalConfig" purpose="config" address="0000" size="128" mode="rw" continuous="false">
+    <description>Configuration for all channels</description>
+      <register name="ChannelEnable" address="0000"  mode="rw" >
+         <description>Enables individual outputs</description>
+         <field  name="EnKelFirst16" start="0" bits="16" format="bitmask" noflag="true">
+         </field>
+         <field  name="EnKelOdd" start="16" bits="1" format="bitmask" noflag="true">
+         </field>
+         <field  name="EnKelEven" start="17" bits="1" format="bitmask" noflag="true">
+         </field>
+         <field  name="En34pinOdd" start="18" bits="1" format="bitmask" noflag="true">
+         </field>
+         <field  name="En34pinEven" start="19" bits="1" format="bitmask" noflag="true">
+         </field>
+         <field  name="EnAna0" start="20" bits="5" format="bitmask" noflag="true">
+         </field>
+         <field  name="EnAna1" start="25" bits="5" format="bitmask" noflag="true">
+         </field>
+      </register>
+      <register name="ChannelInvert" address="0001"  mode="rw" >
+         <description>Invert individual outputs - negative pulse, logical 1 when idle</description>
+         <field  name="InvKelFirst16" start="0" bits="16" format="bitmask" noflag="true">
+         </field>
+         <field  name="InvKelOdd" start="16" bits="1" format="bitmask" noflag="true">
+         </field>
+         <field  name="InvKelEven" start="17" bits="1" format="bitmask" noflag="true">
+         </field>
+         <field  name="Inv34pinOdd" start="18" bits="1" format="bitmask" noflag="true">
+         </field>
+         <field  name="Inv34pinEven" start="19" bits="1" format="bitmask" noflag="true">
+         </field>
+         <field  name="InvAna0" start="20" bits="5" format="bitmask" noflag="true">
+         </field>
+         <field  name="InvAna1" start="25" bits="5" format="bitmask" noflag="true">
+         </field>
+      </register>
+      <register name="AnalogConfig" address="0040" mode="rw" repeat="2">
+         <description>Setting for the analog pulser.</description>
+         <field  name="Cap39pF" start="0" bits="1" format="bitmask" noflag="true"></field>      
+         <field  name="Cap56pF" start="1" bits="1" format="bitmask" noflag="true"></field>      
+         <field  name="Cap68pF" start="2" bits="1" format="bitmask" noflag="true"></field>      
+         <field  name="Cap82pF" start="3" bits="1" format="bitmask" noflag="true"></field>    
+<!--          <field  name="Outp1" start="8" bits="1" format="bitmask" noflag="true"></field>       -->
+<!--          <field  name="Outp2" start="9" bits="1" format="bitmask" noflag="true"></field>       -->
+       </register>
+  </group>
+
+  <group name="PulserConfig" purpose="config" address="0080" size="96" mode="rw" continuous="true">
+    <description>Settings for each pulser channel</description>  
+    <register name="PulserPeriod" address="0000" mode="r" repeat="30" >
+      <description>The period of the pulser, given in multiples of the 240 MHz clock cycle</description>
+      <field  name="PulserPeriod" start="0" bits="24" format="unsigned" noflag="true" scale="4.1667" unit="ns" />
+    </register>    
+    <register name="PulseWidth" address="0020" mode="r" repeat="30" >
+      <description>The width of the pulse, given in multiples of the 960 MHz clock cycle</description>
+      <field  name="PulseWidth" start="0" bits="24" format="unsigned" noflag="true" scale="1.0417" unit="ns" />
+    </register> 
+    <register name="PulserOffset" address="0040" mode="r" repeat="30" >
+      <description>The offset of the pulser channel, given in multiples of the 240 MHz clock cycle</description>
+      <field  name="PulserOffset" start="0" bits="24" format="unsigned" noflag="true" scale="4.1667" unit="ns" />
+    </register> 
+  </group>
+
+</TrbNetEntity>
+