11.07.2015 Views

StreamPro ADCP Operation Manual - global site

StreamPro ADCP Operation Manual - global site

StreamPro ADCP Operation Manual - global site

SHOW MORE
SHOW LESS
  • No tags were found...

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>StreamPro</strong> <strong>ADCP</strong> <strong>Operation</strong> <strong>Manual</strong>11.2 Recommended Data Decoding Sequence for PD0Data Formata. Locate the header data by locating the header ID number (in the case ofPD0 profile data that will be 7F7F).b. Confirm that you have the correct header ID by:1. Locating the total number of bytes (located in the header data) in theensemble. This will be your offset to the next ensemble.2. Calculate the checksum of total number of bytes in the ensemble excludingthe checksum. The checksum is calculated by adding thevalue of each byte. The 2-byte least significant digits that you calculatewill be the checksum.3. Read the 2-byte checksum word at the end of the ensemble, locatedby using the checksum offset in the header (determined in step“b-1”) and compare this checksum word to the value calculated instep “b-2”.4. If the checksums match then you have a valid ensemble. If thechecksums do not match then you do not have a valid ensemble andyou need to go back to step “a” and search for the next header IDnumber occurrence.c. Locate the number of data types (located in the header data).d. Locate the offset to each data type (located in the header data).e. Locate the data ID type you wish to decode by using the offset to eachdata type and confirm the data ID number at that offset matches the IDtype you are looking for.f. Once the proper ID type has been located, use the <strong>ADCP</strong> Technical<strong>Manual</strong> for the <strong>ADCP</strong> you are using to understand what each byte representsin that particular data type.11.3 Pseudo-Code for Decoding PD0 Ensemble DataThe following examples show the pseudo-code for decoding PD0 and PD5ensemble data.g. Define structures, which contain all fields in all data types of the PD0format.1. typedef struct { } FixedLeader.2. typedef struct { } VariableLeader.3. typedef struct { } BottomTrack.4. typedef struct { } VelocityTypepage 84Teledyne RD Instruments

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!