diff cmu200/mode.c @ 3:b552e8d86474

fc-cmu200d: started implementing operation modes
author Mychaela Falconia <falcon@freecalypso.org>
date Sun, 21 May 2017 07:01:53 +0000
parents
children 8877634feba5
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/cmu200/mode.c	Sun May 21 07:01:53 2017 +0000
@@ -0,0 +1,20 @@
+/*
+ * In this module we are going to implement the logic for switching
+ * the CMU200 into different modes as needed for signal generation,
+ * frequency measurement etc.
+ */
+
+#include "mode.h"
+
+int current_mode;
+
+cmu200_session_begin()
+{
+	current_mode = OP_MODE_UNDEF;
+}
+
+stop_signal_gen()
+{
+	if (current_mode == OP_MODE_SIGNAL_GEN)
+		send_scpi_cmd("ABORT:RFG\n");
+}