function [time FDOM]=rd_Eco1ch(fnam)
%
%  Program to read DH-4/WAP BB9 file
%
%  INPUTS
%    FNAM = file name to read in.
%
%  OUTPUTS
%    
%  	 time = timestmap from WAP
%
%    dat = analog data
%
%
%  Written by Emmanuel Boss, U of Maine, 2018 for EXPORTS01.
%   

fid=fopen(fnam,'r')
%clear all
%fid=fopen('C:\Documents and Settings\Emmanuel Boss\Desktop\RIVET2012\day1\archive_24_T_ASCII.000','r')
%skip first line  
%   line=fgetl(fid);
line=fgetl(fid);
junk=0;
i=1;
while(feof(fid)==0);
      dat1=fscanf(fid,'%f',[3]);
      if isempty(dat1);
          break
      end
      dat(i,:)=dat1([1, 3]);
      i=i+1;
      clear dat1
end
time=dat(:,1);
FDOM=dat(:,2);
fclose(fid);