Table of Contents
Previous instructions for LADCP use at University of Hawaii "currents" lab covered the BB150 instrument, and the set of cables it used from the mid 1990's until Nov 2007. The older cables involved charging through the endcap (via wiring changes made after delivery), 8-pin seacon connectors, and a single cable that went from the LADCP to the computer lab (or other dry space).
This document marks a new generation of LADCP use in our group, since we are purchasing a 300kHz Workhorse. Future use will presumably allow the possibility of a pair of instruments, and hence requires that the new cable design allow a master/slave arrangement. We are adopting WHOI's Star cable design, and are using an extension between the Star legs and any instrument or lab cable, to prevent wear on the Star cable connectors. Our cables are therefore not compatible with LDEO's cables.
NOTE: This document is a work in progress.
This section refers to the procedure involving the instrument, cables, power, and rosette. Basically, it is the part of the procedure you carry out in association with deployment and recovery of the rosette.
When approaching a station to do a CTD cast, you need to have the instrument pinging and disconnected from power and communications (with cable ends properly dummied and secured) before the rosette is ready to deploy. Depending on your comfort level with all the steps and the status of the rosette, this could be as little as 5 minutes before "on station". However, we (the LADCP people) do not want to be responsible for any delay in deploment. Often the instrument is made to ping more like 10-15 minutes before arrival on station. The longer the instrument pings on deck, the greater the file size to download, and the longer the battery will have to recharge. But, we do not want to get in the way or cause any kind of delay. At the beginning of a cruise, err on the side being ready with time to spare, and later in the cruise trim that time down as the situation allows.
The LADCP operator may also help deploy the rosette.
15-20 minutes before "on station": Find the clipboard with the logsheet.
The rosette is brought on board. People are milling about, anxious to start sampling. The LADCP person should be standing by (or maybe that person helped with the recovery), and as soon as the rosette is officially "secured", before sampling starts, the LADCP person should connect the cables for power and communication.
The LADCP person may participate in drawing water for salts or other rosette sampling, as long as they are able to monitor the download and charging process, assess the quality of the data (pass/fail) and perform any nexessary troubleshooting.
For each communication/power cable:
This link has figures and details about mounting the LADCP on the rosette, including the cabling diagram.
When mounting the transducers on the rosette frame, put a piece of dense foam under the transducers. The BB150 instrument, especially, weighs enough that the transducers may be damaged if the instrument rests on them without any padding. A good piece of foam is one of the pieces from the shipping container). The foam in the BB150 gray shipping box is good for this.
For the BB150, use a piece of PVC pipe that is cut to fit between the transducers down in the nether regions of the instrument. This protects the transducers if the instrument were to slip in the brackets (eg. during a drop on deck from several feet).
Data logging command files:
There are two python programs designed to communicate with RDI Workhorse or BB LADCP with baud rate and port optionally specified on the command line (for one or two instruments, respectively):
/home/currents/programs/logging/serial/ladcp1.py #for one instrument /home/currents/programs/logging/serial/ladcp2.py #for two instruments
To use either of these two programs, copy them to the ladcp data download directory and edit them to be appropriate for your cruise. In general, do not edit anything in home/currents/programs unless you find a bug and are confident of the solution. See the cruise setup section for more info. It may be useful to rename them to match specific instruments or cruise name. Run them from the download directory, which should also contain any command files being sent to the instrument.
link to annotated command file for wh300
link to example command file for bb150
link to station example logsheet
link to detailed narrative about LADCP acquisition and processing from a recent user of the UH code and computers.
Start in the ladcp data directory ("cd; cd cruise/ladcp/data/ladcp")
Run the steps under menu item Deploy:
Deployment initialization:
send setup (appropriate *.cmd, in the current directory)
Deal with cables and power in the hangar
Run the steps under Recover:
Recovery initialization:
download
Files are downloaded to a name chosen by the instrument, with a timestamp embedded in the first 8 characters, and the serial number (from firmware?) as the last 3 digits. The date is wierd. The python program will reset the date to now at the end of download, and you get to choose a new name for the file if you wish.
Disregard the following security warning in the console:
"RuntimeWarning: tempnam is a potential security risk to your program"
The following programs reside in
/home/currents/programs/ladcp/python
and if they are going to be run, they should be copied to the location where they will be run, and then modified.
This one will be needed as part of LADCP processing, to get the GGA data into the one-file-per-day the perl programs expect.
uhdas2deva.py: Need to have gps data somehow; this uses UHDAS gps files.
These two may not be necessary:
depth_check.py: wrapper for "scan.prl"
fix_ymodemfile.py: renames a wierd filename, changes permissions, and makes the date more reasonable
Matlab ladcp plotting programs are here:
/home/currents/programs/matlab/ladcp/misc/contour /home/currents/programs/matlab/ladcp/misc/vector
These programs were written on one cruise, and to avoid losing them the were copied into the ladcp location in the programs directory. Make your own contour or vector directory, copy files there, and edit locally. If you are making plots for a web page, copy the png files to the web location and make sure the permissions include other read.
DO NOT edit programs in /home/currents/programs, unless you are fixing a bug, and then you should check with one of
hummon@hawaii.edu efiring@hawaii.edu
An example of the simple web page developed during P16S is here. If you want to make your own web page, the following steps must be performed
Read this page for instructions about reading single-ping ladcp data. There is also an example of how to make nice pcolor plots.
3-6 months
brackets: Be aware of which group is doing the CTD operations. The rosette they use may or may not have brackets for the LADCP or a housing to mount the battery. These need to be constructed and tested before shipping, so the timing for new brackets is similar to buying a new instrument.
2-3 months
4-6 weeks
0-1 week
setup for cruise:
Here are some links to files written during P16S, Revelle 2005. Details will vary cruise to cruise.
See "deployment" and "recovery" for rosette (deploy, recover), and computer (deploy, recover) operations.
shipboard ADCP data Data will probably come from one, but not both of these:
UHDAS: Mount the data disk from the uhdas computer "currents". (instructions are here). The disk, (say it's called "data"), will have a subdirector for the present cruise (eg. km0508). Get the whole directory. It will include subdirectories:
Lowered ADCP data (easiest to get the whole processing directory) By category:
Ancillary data for LADCP
NOTE: There is a log book for the LADCPs and batteries. Do not lose it. At the beginning of the cruise, note what instruments are being used, and note when any are swapped out. At the end of the cruise, tally up how many casts hae been made by each instrument and battery. Use serial numbers to reference instruments
You should be familiar with the following aspects of the logging PC:
The user is "science".
Cruise names can be one of the following: - ship+year+number (eg: km0715) - ship's convention (eg: ZHNG04RR) - science convention (eg: P18_leg1)
Two generic names are "docs" and "web". Other than that, name the cruise directory something useful (eg. use the name the CTD group is using). Keep all processing, notes, documentation, logsheets, etc in that directory. It makes backing up easier.
directory : contains --------- : ---------------------------------- /home/science : user science: home
/home/science/docs : documentation files for this computer
: provided for the science user#--------------------------
/home/science/vg9507 : example of logsheet, processed data,
: directory structure# Inside /home/science/vg9507, we have subdirectories for different purposes: data/ : holds all raw data for this cruise data/ctd_2db : 2db ctd data data/gpsnav : 1-day files with GPGGA messages data/ladcp : ladcp download data/underway : meteorological data
ladcp/ : ladcp processing dictory, made by "setcruise.prl"
: see "lad_proc.txt" in this directory
: (this file is copied here by setcruise.prl)adcp/ : for instance, to hold processed adcp data
ldeo_proc : for instance, to hold ldeo processing #--------------------------
/home/science/cruise : link to the real cruise directory
: --> do all work here/home/science/web : link to web directory for the present cruise
/home/currents/programs : root of UH programs. Do not edit these
: files. Copy to a local directory before
: editing.The demo uses an imaginary cruise, "vg9507". Run through the demo to make sure all the programs work. When you make your own processing directory do all work related to teh cruise in this directory. Backups are much easier if you keep everything in here.
The ladcp demo is called "bbdemo" and is located in the following directory:
/home/currents/programs/ladcp/bbdemo
The strategy for the demo, or any other cruise directory is:
make the cruise directory, and create the ladcp data and processing directory in it:
cd # go to home directory mkdir vg9507 # make the cruise directory cd vg9507 # go into the cruise directory
# run the following command (all one line)
/home/currents/programs/ladcp/perl/ladstart.prl ladcp /home/currents/programs/ladcp/bbdemo/vg9507/ladcp
make the data directory and subdirectories to hold all kinds of data;
mkdir data cd data mkdir ctd_2db gpsnav ladcp
If logging LADCP data, you will need command files and logging scripts.
cd ladcp # copy the command files cp /home/currents/programs/ladcp/howto_bbwh2008/ladcp_logging/wh300.cmd . cp /home/currents/programs/ladcp/howto_bbwh2008/ladcp_logging/bb150.cmd . copy the logging scripts: cp /home/currents/programs/uhdas/serial/ladcp1.py . cp /home/currents/programs/uhdas/serial/ladcp2.py .
If you will be logging data, make a symbolic link from /home/science/cruise to the new named cruise directory, eg:
cd ln -s vg9507 cruise
ports set up for physically set in program (**) ----- --------- ------------ ---------------- ttyUSB0 ladcp logging keyspan USB ladcp1.py, ladcp2.py ttyUSB1 ladcp logging keyspan USB ladcp1.py, ladcp2.py ttyS0 ladcp logging serial port ladcp1.py, ladcp2.py
There may also be USB ports for mouse or external disk
There may be a firewire port for an external disk
There may be an ethernet card for the network (older machines)
The LADCP loggging PC could be one of several, and will have a name. For the purposes of this example, the machine's name will be "poi"
Usually, "plug into the network, wait, and it will find a number"
Use the command "ifconfig eth0" to see what the ip number is, for example:
eth0 Link encap:Ethernet HWaddr 00:0C:29:1F:5B:CB
inet addr:172.20.101.247 Bcast:172.20.255.255 Mask:255.255.0.0If you must change network settings, use the tool under "system" menu that says "networking" (there are several with similar names). Click or unclick the appropriate box, change settings, wait 10 seconds or more for those changes to take effect. You may need to reboot.
On most of our Ubuntu laptops, if you plug in a disk (USB or firewire) while you are logged in, it will automatically mount. You must manually unmount it before unplugging it from the computer or you risk damaging the data.
Automatic mounting is done by the window manager (KDE or Gnome).
Unmount by one of these means: - right-click the icon; select "safely remove"; wait till it's ready, unplug. - on the command line, type "sudo umount /media/usbdisk" (or whatever it's called). Type "df" to make sure it's not on the list. unplug
All data should be on two media as soon as practical. Do not delete anything you care about until there are two copies.
A service called "automount" is also installed. This allows automatic mounting of various other kinds of disks. Specifically, in /etc/auto.master, a line is uncommented allowing automatic mounting of disks shared with nfs. This means that, for example, if yo can ping the uhdas ADCP computer by name, (called "currents") then you should be able to access its nfs shares as
/net/currents/home/data /net/currents/home/programs /net/currents/home/adcp
If you need to mount an nfs share without automount, make a mount point (as root), eg "/mnt/tmp", and mount it as
mount currents:/home/data /mnt/tmp
Read the man page on mount for more info.
Disks are sometimes shared using samba, to make life easier for people with Windows or Macs. Linux can mount samba-shared disks using the smbfs filesystem type, but the command can get rather long. Read the man page for smbmount. Samba mount must be done as root or using the "sudo" command. One example that worked is
sudo mount -t smbfs -o username=guest,password=,workgroup=tgt//p16n/P16N\ Shared /mnt/p16n-ctd
In this case,
If you have problems with permissions, you may need to add
uid=51077,gid=1076
You can edit the file /etc/exports to share a disk via nfs. This example is from "currents" and shows the read-only export of three directories:
# /etc/exports on "currents" /home/adcp *(ro,async) /home/data *(ro,async) /home/currents *(ro,async) #
To make this active, type
sudo exportfs -r
The computer clock should be set to UTC. For some computers this means choosing a time zone called Rejkavik (they are on UTC and evidently don't use daylight savings time)
It is important that the computer clock be close to UTC time. It should not be off by more than 1 second when an LADCP cast starts. That can be accomplished by - manually setting the clock before each cast - setting the computer to look for the time using an NTP server.
Setting the NTP server
(a) The file /etc/ntp.conf has a line that says "server". Use "sudo" and edit it to use the local time server on the ship. In this example the time server is 128.171.154.123
# You do need to talk to an NTP server or two (or three). server 128.171.154.123
(b) Then run this command to restart the time server
sudo /etc/init.d/ntp restart
(c) Then run the following to verify that the time server is working
ntpq -p
Manually setting the clock
Use the "date" command. For example, to set the current time and date to July 31, 11:16:30pm, type
date -s 07312316.30
(note that the time is given in 24 hour notation). I've also seen this notation.
date -s "11/20/2003 12:48:00"
I am not setting up the matlab license to boot automatically. The license manager must have the output of "hostname" match the server line in /usr/local/matlab/etc/license.dat exactly. Every time you change networking it's possible to break this. Always run with the ethernet card in, or networking won't start and then the license manager won't run.
Every time you boot the machine and want to run matlab, start the license manager. NOTE that this kind of license allows multiple sessions of matlab to run, but they must all be run by the same user. Since the automatic processing will be user "science", you'd better just BE "science" here, and then there won't be any failure to start sessions.
To start the matlab license manager, type "lmstart" as user "science". (lmstart is linked to /usr/local/bin). Do not do this as root. (The license manager needs a regular user or various permissions or something else will be screwed up).
If it comes back with a failure, then you have to change the file: /usr/local/matlab/etc/license.dat (as root), replacing the fully qualified hostname with whatever comes out when you type "hostname".
EG: replace snowboard.soest.hawaii.edu with
adelie.melville.ucsd.edu in this line:SERVER snowboard.soest.hawaii.edu ID=22566 27000
Then as user adcp, type "lmstart" again.
---------
Additional notes:
The most likely problems with the matlab license manager are (1) server name and networking (see above) (2) permissions:
All the files with *TMW* in /var/tmp ust be owned (or be writeable) by the user who is trying to start the license manager. In this case, the use is "science". If another user owns those files, delete them all, and try again.
This link has a list of various potentially useful unix shell commands.
POWER OFF FIRST (do not plug anything together with the power supply on. Two really good reasons:
As of Nov 2007, a new instrument is arriving, and with it a new set of cables and confusion.
Old suite (short story) - BB150, communicating with RS422 protocol - 8-pin cable connects instrument to long cable into the lab, and - RS422-RS232 converter + DC power, to serial port on PC - power for charging battery (Amrel Linear Power Supply) - power goes into the 8-pin connector on the instrument, through the endcap, and out the 2-pin cable to the battery. i.e. charging is done through the endcap. - battery is 48V oil-filled SOB (Safe Orange Battery)
New suite (short story)l - one or two of the following: WH300, BB150 - BB150 will always look down - if there are 2 instruments, they must be slaved. - "star" cable, with 5 ends for - ladcp #1 - ladcp #2 - laptop serial communication with ladcp#1; includes power - laptop serial communication with ladcp#2; includes power - battery - all communication is RS232
We have the AMREL power supply programmed with the following settings:
+VSET = 28.300 -VSET = 29.010 +ISET = 2.0 -ISET = 1.8 The other 2 settings are INDEP 5V
If the comercial charger works with the Star cable,