--- /dev/null
+Revision history for Perl extension HADES::TrbNet.
+
+0.01 Sun Jan 8 04:53:28 2012
+ - original version; created by h2xs 1.23 with options
+ -n HADES::TrbNet -A -O -x trberror.h trbnet.h trbrpc_perl.h
+
--- /dev/null
+Changes
+MANIFEST
+Makefile.PL
+README
+TrbNet.xs
+lib/HADES/TrbNet.pm
+test/test.pl
--- /dev/null
+# file : Makefile.PL
+# See lib/ExtUtils/MakeMaker.pm for details of how to influence
+# the contents of the Makefile that is written.
+
+use ExtUtils::MakeMaker;
+WriteMakefile(
+ NAME => 'HADES::TrbNet',
+ VERSION_FROM => 'lib/HADES/TrbNet.pm',
+ PREREQ_PM => {}, # e.g., Module::Name => 1.1
+ ($] >= 5.005 ? ## Add these new keywords supported since 5.005
+ (ABSTRACT_FROM => 'lib/HADES/TrbNet.pm', # retrieve abstract from module
+ AUTHOR => 'Hades DAQ <hadaq@>') : ()),
+ INC => '-I../libtrbnet',
+ DEFINE => '',
+ LIBS => '-L../trbnetd -ltrbnet',
+ OBJECT => '$(O_FILES)'
+);
--- /dev/null
+HADES-TrbNet version 0.01
+=========================
+
+The README is used to introduce the module and provide instructions on
+how to install the module, any machine dependencies it may have (for
+example C compilers and installed libraries) and any other information
+that should be provided before the module is installed.
+
+A README file is required for CPAN modules since CPAN extracts the
+README file from a module distribution so that people browsing the
+archive can use it get an idea of the modules uses. It is usually a
+good idea to provide version information here so that people can
+decide whether fixes for the module are worth downloading.
+
+INSTALLATION
+
+To install this module type the following:
+
+ perl Makefile.PL
+ make
+ make test
+ make install
+
+DEPENDENCIES
+
+This module requires these other modules and libraries:
+
+ blah blah blah
+
+COPYRIGHT AND LICENCE
+
+Put the correct copyright and licence information here.
+
+Copyright (C) 2012 by Hades DAQ
+
+This library is free software; you can redistribute it and/or modify
+it under the same terms as Perl itself, either Perl version 5.10.0 or,
+at your option, any later version of Perl 5 you may have available.
+
+
--- /dev/null
+#include <EXTERN.h>
+#include <perl.h>
+#include <XSUB.h>
+#include <assert.h>
+
+#include <trbnet.h>
+
+/* file : TrbNet.xs */
+
+MODULE = HADES::TrbNet PACKAGE = HADES::TrbNet
+PROTOTYPES: ENABLE
+
+int
+init_ports()
+
+void
+trb_uid(trb_address)
+ U16 trb_address
+ INIT:
+ static U32 buf2[1024 * 4];
+ int status;
+ int i;
+
+ PPCODE:
+ i = 0;
+ status = trb_read_uid(trb_address, (U32 *)&buf2, 1024 * 4);
+ if (status <= 0) {
+ XSRETURN_UNDEF;
+ return;
+ }
+ for (i = 0 ; i < status; i++) {
+ XPUSHs(sv_2mortal(newSVnv(buf2[i])));
+ }