Array
Class TerrellaHydrophoneLocator
java.lang.Object
Array.SimpleHydrophoneLocator
Array.StraightHydrophoneLocator
Array.ThreadingHydrophoneLocator
Array.TerrellaHydrophoneLocator
- All Implemented Interfaces:
- HydrophoneLocator, PamObserver
public class TerrellaHydrophoneLocator
- extends ThreadingHydrophoneLocator
Extends ThreadingHydrophoneLocator so that ThreadingHydrophoneLocator can
handle all the LatLong information and the Terellas handle the depth, heading
and tilt info.
It's possible that there are several Terellas on the system and we subscribe to all
of them. Each TErrella will send it's data into a different data block
Each terrella data block will have it's channel bitmap set to the represent the hydrophones
which should be positioned based on that terrella data.
The Terrells data blocks (which have been subclassed off PamDataBlock) also contain the
x, y coordinates of the terrella. The most interesting of these is probably y, which
is generally -ve for things towed behind the boat ! From teh position of the Terrella and
the position of each hydrophone it's possible to calculate exact depths for each phone using
the tilt information, etc.
- Author:
- Doug Gillespie
|
Method Summary |
private TerrellaStandardDataSetUnit |
findTerrellaData(long timeMilliseconds,
int phoneNo)
|
private TerrellaDataBlock |
findTerrellaDataBlock(int phoneNumber)
Find a Terrella data block that include the channel (phone number) that
we're interested in. |
double |
getdensity(double S,
double T,
double p)
|
double |
getPairAngle(long timeMilliseconds,
int phone1,
int phone2,
int angleType)
Get's the angle between a pair of hydrophones |
double |
getPhoneDepth(long timeMilliseconds,
int phoneNo)
Get's the depth of a specific hydrophone at a given time. |
double |
getPhoneHeading(long timeMilliseconds,
int phoneNo)
|
double |
getPhoneTilt(long timeMilliseconds,
int phoneNo)
Get's the tilt of a specific hydrophone at a given time. |
long |
getRequiredDataHistory(PamObservable o,
java.lang.Object arg)
|
void |
notifyModelChanged(int changeType)
|
private void |
setupTerrallaMonitor()
|
| Methods inherited from class Array.StraightHydrophoneLocator |
findDepthDataUnit, findGpsDataUnit, getCorrectedYPos, getObserverName, getObserverObject, getReferenceLatLong, masterClockUpdate, noteNewSettings, removeObservable, setSampleRate, setupGpsMonitor, update |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
terrellaDataBlocks
java.util.ArrayList<PamDataBlock> terrellaDataBlocks
TerrellaHydrophoneLocator
public TerrellaHydrophoneLocator(PamArray pamArray)
notifyModelChanged
public void notifyModelChanged(int changeType)
- Specified by:
notifyModelChanged in interface HydrophoneLocator- Overrides:
notifyModelChanged in class StraightHydrophoneLocator
setupTerrallaMonitor
private void setupTerrallaMonitor()
getRequiredDataHistory
public long getRequiredDataHistory(PamObservable o,
java.lang.Object arg)
- Specified by:
getRequiredDataHistory in interface PamObserver- Overrides:
getRequiredDataHistory in class StraightHydrophoneLocator
- Parameters:
o - PamObservable class requiring the dataarg - optional argument from PamObservable
- Returns:
- time in milliseconds requried by data held in PamObservable
getPairAngle
public double getPairAngle(long timeMilliseconds,
int phone1,
int phone2,
int angleType)
- Description copied from interface:
HydrophoneLocator
- Get's the angle between a pair of hydrophones
- Specified by:
getPairAngle in interface HydrophoneLocator- Overrides:
getPairAngle in class ThreadingHydrophoneLocator
- Parameters:
timeMilliseconds - time angle is needed forphone1 - First hydrophonephone2 - Second HydrophoneangleType - Type of angle - ANGLE_RE_NORTH; ANGLE_RE_SHIP; ANGLE_RE_ARRAY;
- Returns:
- angle in radians
getPhoneDepth
public double getPhoneDepth(long timeMilliseconds,
int phoneNo)
- Description copied from interface:
HydrophoneLocator
- Get's the depth of a specific hydrophone at a given time.
- Specified by:
getPhoneDepth in interface HydrophoneLocator- Overrides:
getPhoneDepth in class StraightHydrophoneLocator
- Parameters:
timeMilliseconds - time depth needed forphoneNo - Hydrophone number
- Returns:
- Hydrophone depth
getdensity
public double getdensity(double S,
double T,
double p)
getPhoneHeading
public double getPhoneHeading(long timeMilliseconds,
int phoneNo)
- Overrides:
getPhoneHeading in class SimpleHydrophoneLocator
getPhoneTilt
public double getPhoneTilt(long timeMilliseconds,
int phoneNo)
- Description copied from interface:
HydrophoneLocator
- Get's the tilt of a specific hydrophone at a given time.
- Specified by:
getPhoneTilt in interface HydrophoneLocator- Overrides:
getPhoneTilt in class SimpleHydrophoneLocator
- Parameters:
timeMilliseconds - time tilt needed forphoneNo - Hydrophone number
- Returns:
- Hydrophone tilt
findTerrellaDataBlock
private TerrellaDataBlock findTerrellaDataBlock(int phoneNumber)
- Find a Terrella data block that include the channel (phone number) that
we're interested in. It's assumed that only one Terrella data block
will be associated with each phone.
- Parameters:
phoneNumber -
- Returns:
findTerrellaData
private TerrellaStandardDataSetUnit findTerrellaData(long timeMilliseconds,
int phoneNo)