Difference between revisions of "HV technical"
Line 106: | Line 106: | ||
Kill cfengine, which tends to rather rudely delete /etc/xinetd.d/telnet Yes, telnet is an old, insecure protocol, but it's needed by this software. The Java code uses telnet to communicate with the Perl server. | Kill cfengine, which tends to rather rudely delete /etc/xinetd.d/telnet Yes, telnet is an old, insecure protocol, but it's needed by this software. The Java code uses telnet to communicate with the Perl server. | ||
+ | |||
+ | ========================================== | ||
+ | |||
+ | Nov 13, 2013 | ||
+ | |||
+ | Adding a new Intel VME PC to the hall | ||
+ | |||
+ | add to /etc/dhcpd.conf on adaql2 | ||
+ | |||
+ | <pre> | ||
+ | host halladaq8 | ||
+ | { | ||
+ | filename "linux-install/pxelinux.0"; # File location relative to /tftpboot/ | ||
+ | next-server 129.57.164.32; # TFTP server | ||
+ | # hardware ethernet 00:20:38:04:6D:12; # Client MAC XVB601 | ||
+ | # hardware ethernet 00:20:CE:F6:03:EE; # Client MAC XVR14 | ||
+ | # hardware ethernet 00:21:70:AF:3B:46; # PC Magali LPC Clermont | ||
+ | hardware ethernet 00:20:38:04:6D:0E; # Right Intel CPU HV control XVB601 | ||
+ | fixed-address 129.57.164.15; # Client IP | ||
+ | } | ||
+ | } | ||
+ | </pre> | ||
+ | |||
+ | Then need to restart: | ||
+ | |||
+ | /etc/rc.d/init.d/dhcp restart | ||
+ | |||
+ | On adaql1 | ||
+ | |||
+ | Need to add IP to adaql1:/root/tftpboot/linux-install/pxelinux.cfg | ||
+ | |||
+ | 8139A40F is the hex version of 129.57.164.15 = halldaq8 | ||
+ | |||
+ | What this file (8139A40F) looks like : | ||
+ | |||
+ | <pre> | ||
+ | [root@adaql1 pxelinux.cfg]# pwd | ||
+ | /root/tftpboot/linux-install/pxelinux.cfg | ||
+ | [root@adaql1 pxelinux.cfg]# more 8139A40F | ||
+ | default Centos_5.8_32_bit | ||
+ | |||
+ | label Centos_5.8_32_bit | ||
+ | kernel Centos_5.8_32_bit/vmlinuz | ||
+ | append initrd=Centos_5.8_32_bit/initrd.img root=/dev/ram0 init=disklessrc N | ||
+ | FSROOT=129.57.164.32:/diskless/i386/Centos5.8 ramdisk_size=23904 ETHERNET=eth0 S | ||
+ | NAPSHOT=intelha1 NISDOMAIN=CCHP vga=0x305 acpi=force vmalloc=256MB | ||
+ | </pre> | ||
+ | |||
+ | Some things had to be enabled in BIOS, too. The network and the boot sequence -- Alex did it too fast. |
Revision as of 12:06, 13 November 2013
R. Michaels, Nov 2013
Here is some boring technical info about HV control.
First, note these somewhat old URLs as a starting point
http://hallaweb.jlab.org/equipment/daq/HVhelp.html
http://hallaweb.jlab.org/equipment/daq/gen_slow_control.html
The above URLs will need to be modified and updated to provide User guidance. But they are a nice start.
A note about the HV software architecture:
1. "hvs" (aka "hvg") = Java GUI that provides User interface (author: Roman Pomatsalyuk)
2. LecroyHV_Shim = Perl server, listens on a telnet port, talks to hvs. This code emulates the obsolete (no-longer-existing) motherboards on the LeCroy 1458 HV crate (author: Brad Sawatzky). This server must run on the PC that is connected by RS232 to the HV crate.
3. i2lchv_linux_bob = Bob's version of Brad's version of Javier's code that does the low-level communication with the HV crate. (original author: Javier Gomez, but don't blame him for my hacks). i2lchv_linux_bob talks via R232 to the HV cards using a primitive "language". The LecroyHV_Shim Perl script connects to i2lchv_linux_bob via the "Expect" module of Perl.
Nov 12, 2013. Attempts to use Intel PC as the PC that is nearby the LeCroy HV crate.
from root on adaql1, see /root/diskless/i386/Centos5.8
./snapshot = directories local to the cpus. e.g. see /snapshot/intelha3 for intelha3.
./root = directory shared by all the cpus. However, not (yet) writeable by the cpus.
On the intel cpu, if you want to create or touch files, you must use the local filesystem.
/root/diskless/i386/Centos5.8/snapshot/intelha3/root (from adaql1)
appears as
/root (local filesystem on intelha3)
/shim (on intelha3) is the shared shim directory from
However, if you want to compile code that every intel PC uses, you must use
/root/diskless/i386/Centos5.8/root on adaql1
/shim (on intelha3) is the shared shim directory from /root/diskless/i386/Centos5.8/root/shim on adaql1
Nov 12, 2013. Attempting to run HV control on L-HRS.
Login to intelha3 as root.
Reminder /root/shim is the LOCAL copy. Must run Shim server here because this filesystem can be written to. /shim is the SHARED copy (on adaql1). Must compile here (on adaql1)
To check that HV cards are seen via RS232, go to /root/shim and run /shim/LecroyHV_shim/LecroyHV_FE/i2lchv_linux_bob
I'm running code in /root/shim because if it needs to make output, this filesystem allows. But the code coms from /shim which is the shared area.
A note: if this code needs to be recompiled, you must do the compilation on the shared disk area and then use the exec in the local area.
If when you run i2lchv_linux_bob you see a list of HV cards, then it's a good sign.
Next, run the Perl Server: go to /root/shim/ and type /shim/LecroyHV_shim/LecroyHV_Shim (Note, I've attempted to automate this step, so it is running 24/7 even after rebooting the intel PC. see below)
On adaql1, as adev account, do this: "cd ./slowc ; ./hvs LEFT"
How to modify programming on intelha3 or other intel PCs
On adaql1 as root, in /root/diskless/i386/Centos5.8/root/shim/LecroyHV_shim/LecroyHV_FE and related areas. Modify code and compile here.
On intelha3 the files appear as /shim/LecroyHV_shim/LecroyHV_FE (etc)
Attempt to automate the startup of Shim server so that users don't need to care.
On intelha3, have a crontab entry for root
[root@intelha3 LecroyHV_shim]# crontab -l
# Start the shim server for HV 2,10,20,30,40,50 * * * * /shim/scripts/prepHV
The script prepHV checks if Shim is running. If it is, do nothing. If not, start it.
Notes about pre-requisites for making the Perl server work.
Needed Perl 5.8.8 or later install. On intel PC this appears as /perl after being put (on adaql1) in the shared area.
Needed RH5 or greater, to have correct glibc
/dev/ttyS0 permissions -- it gets reset when boot.
Install telnetd server, and restart allow telnet in /etc/xinetd.d
Kill cfengine, which tends to rather rudely delete /etc/xinetd.d/telnet Yes, telnet is an old, insecure protocol, but it's needed by this software. The Java code uses telnet to communicate with the Perl server.
==============================
Nov 13, 2013
Adding a new Intel VME PC to the hall
add to /etc/dhcpd.conf on adaql2
host halladaq8 { filename "linux-install/pxelinux.0"; # File location relative to /tftpboot/ next-server 129.57.164.32; # TFTP server # hardware ethernet 00:20:38:04:6D:12; # Client MAC XVB601 # hardware ethernet 00:20:CE:F6:03:EE; # Client MAC XVR14 # hardware ethernet 00:21:70:AF:3B:46; # PC Magali LPC Clermont hardware ethernet 00:20:38:04:6D:0E; # Right Intel CPU HV control XVB601 fixed-address 129.57.164.15; # Client IP } }
Then need to restart:
/etc/rc.d/init.d/dhcp restart
On adaql1
Need to add IP to adaql1:/root/tftpboot/linux-install/pxelinux.cfg
8139A40F is the hex version of 129.57.164.15 = halldaq8
What this file (8139A40F) looks like :
[root@adaql1 pxelinux.cfg]# pwd /root/tftpboot/linux-install/pxelinux.cfg [root@adaql1 pxelinux.cfg]# more 8139A40F default Centos_5.8_32_bit label Centos_5.8_32_bit kernel Centos_5.8_32_bit/vmlinuz append initrd=Centos_5.8_32_bit/initrd.img root=/dev/ram0 init=disklessrc N FSROOT=129.57.164.32:/diskless/i386/Centos5.8 ramdisk_size=23904 ETHERNET=eth0 S NAPSHOT=intelha1 NISDOMAIN=CCHP vga=0x305 acpi=force vmalloc=256MB
Some things had to be enabled in BIOS, too. The network and the boot sequence -- Alex did it too fast.