Here's a program and compiled executable that will create a CSV format from 
ALL.TXT like this:
2017-01-01,0000,-5,-0.9,952,#,CQ KE2P FM18
2017-01-01,0000,-15,-1.1,1058,#,CQ N7MDW CN94
2017-01-01,0002,-6,-0.9,952,#,CQ KE2P FM18
2017-01-01,0002,-17,-0.9,1296,#,CQ N2IEC FM29
2017-01-01,0002,-20,-0.8,1768,#,CQ KD4BEE EL99

https://www.dropbox.com/s/n196tigzjguq6gp/allcsv.exe?dl=0




#include <stdio.h>
#include <string.h>
#include <stdlib.h>

int main(int argc, char *argv[])
{
    if (argc != 2) {
        fprintf(stderr,"Usage: %s [filename]\n",argv[0]);
        exit(1);
    }
    FILE *fp=fopen(argv[1],"r");
    char buf[4096];
    while(fgets(buf,sizeof(buf),fp)) {
        char date[32],freq[32],time[32],msg[32];
        int db,offset;
        float dt;
        char mode;
        if (buf[4]=='-') { // date line
            sscanf(buf,"%s %*d:%*d %s",date,freq);
        }
        else if (strstr(buf," CQ ") || strstr(buf," DE ")){
            int n = sscanf(buf,"%s %d %f %d %c 
%[^\n]s",time,&db,&dt,&offset,&mode,msg);
            printf("%s,%s,%d,%.1f,%d,%c,%s\n",date,time,db,dt,offset,mode,msg); 
   
        }
    }
    fclose(fp);
    return 0;
}

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
wsjt-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wsjt-devel

Reply via email to