diff FXAnalyse.c @ 267:1de805d2d37a

Reuse beatnote enum also for dedrift reference selection
author Daniele Nicolodi <daniele.nicolodi@obspm.fr>
date Thu, 09 Jul 2015 23:08:22 +0200
parents dfbee05fe464
children ec4462c7f8b7
line wrap: on
line diff
--- a/FXAnalyse.c	Thu Jul 09 23:05:43 2015 +0200
+++ b/FXAnalyse.c	Thu Jul 09 23:08:22 2015 +0200
@@ -346,11 +346,6 @@
 
 
 // dedrift
-enum {
-	DEDRIFT_REFERENCE_MICROWAVE = 0,
-	DEDRIFT_REFERENCE_HG = 1,
-};
-
 struct dedrift {
 	int enabled;        // dedrift enabled
 	int proportional;   // enable proportional correction
@@ -374,7 +369,7 @@
 struct dedrift dedrift = {
 	.enabled = FALSE,
 	.proportional = FALSE,
-	.reference = DEDRIFT_REFERENCE_MICROWAVE,
+	.reference = MICROWAVE,
 	.sign = +1,
 	.x2 = FALSE,
 	.keep_freq = TRUE,
@@ -1538,10 +1533,10 @@
 				// select dedrift reference
 				double f = 0.0;
 				switch (dedrift.reference) {
-					case DEDRIFT_REFERENCE_MICROWAVE:
+					case MICROWAVE:
 						f = Math2;
 						break;
-					case DEDRIFT_REFERENCE_HG:
+					case HG:
 						f = Ch2 * 1062.5 / 1542.2;
 						break;
 				}