A javascript port of the USF-COT python pd0 parser.
var withPd0s = function(array_of_pd0s){
document.body.innerHTML = "parsed "+array_of_pd0s.length+" pd0s. See console for details.";
console.log(array_of_pd0s);
};
fetch('http://spiddal.marine.ie/data/adcps/TRDI-WHB600Hz-1323/2016/04/02/TRDI-WHB600Hz-1323_20160402.pd0')
.then(function(response) {
return response.arrayBuffer();
}).then(function(ab) {
var buffer = new Uint8Array(ab);
document.body.innerHTML = "parsing pd0...";
new pd0parser().parse(buffer).then(withPd0s)
});