sfregosi / agate

agate: Acoustic Glider Analysis Tools and Environment. MATLAB-based tools for working with passive acoustic underwater gliders.
https://sfregosi.github.io/agate/
GNU General Public License v3.0
2 stars 2 forks source link

`processWisprDetFile.m` does not work in 2024 #73

Open sfregosi opened 2 months ago

sfregosi commented 2 months ago

Describe the bug Get an error at the gunzip function that the file is not a gzipped file.

This was discovered once the new downloadBasestationFiles method was implemented (SFTP vs SSH2) but I don't think it is related to those changes. I am thinking it might be related to WISPR software/firmware changes? Need to discuss with @DMellinger

To Reproduce

>> CONFIG = agate;
      agate   version 0.9.20240814   https://github.com/sfregosi/agate-public
Mission configuration file:
      C:\Users\Selene.Fregosi\Documents\GitHub\glider-CalCurCEAS\MATLAB\fregosi_config_files\agate_config_sg679_CalCurCEAS_Aug2024.cnf
      loaded config file   C:\Users\Selene.Fregosi\Documents\GitHub\glider-CalCurCEAS\MATLAB\fregosi_config_files\agate_config_sg679_CalCurCEAS_Aug2024.cnf

>> wsFile = 'C:\Users\Selene.Fregosi\Desktop\sg679_CalCurCEAS_Aug2024\basestationFiles\ws0093az.x00';
>> processWisprDetFile(CONFIG, wsFile);
Error using matlab.io.internal.archive.core.builtin.uncompressgz
File
"C:\Users\Selene.Fregosi\Desktop\sg679_CalCurCEAS_Aug2024\basestationFiles\ws0093az.x00"
is not in GZIP format.
Error in gunzip (line 92)
       names = matlab.io.internal.archive.core.builtin.uncompressgz({entries.file}, outputDir, false);
Error in processWisprDetFile (line 49)
gunzip(fullfile(CONFIG.path.bsLocal, [name, ext])); % makes unzipped file sans ext 
>> 
sfregosi commented 2 months ago

Because the files are viewable in notepad, they must already be uncompressed. Not sure when/where this step is happening. I looked at the baselog and baselogin files on the basestation and didn't see any reference to unzipping, but would probably need to ask IOP about this.

New processing step would require concatenating mulitple files and maybe still checking for bad characters.