// filename: get_ecg_waveform.c // copyright Massachusetts Institute of Technology // author: Matt Oefinger #include #include char DB_PATH[] = "http://physionet.org/physiobank/database"; char ABSOLUTE_PATH[150]; char RECORD_ID[50]; main(int argc, char* argv[]) { int nsig; sprintf(ABSOLUTE_PATH,"%s/%s",DB_PATH,argv[1]); setwfdb(ABSOLUTE_PATH); nsig = isigopen(argv[2], NULL, 0); if (nsig < 1) exit(1); else printf("%f\n",sampfreq(argv[2])); wfdbquit(); exit(0); }