diff DDS4xAD9959.h @ 0:d9aae7d7f2c6

Import
author Daniele Nicolodi <daniele.nicolodi@obspm.fr>
date Tue, 03 Jul 2012 10:38:59 +0200
parents
children
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/DDS4xAD9959.h	Tue Jul 03 10:38:59 2012 +0200
@@ -0,0 +1,71 @@
+//==============================================================================
+//
+// Title:       DDS4xAD9959.h
+// Purpose:     
+//
+// Created on:  by Volodimer Laurent, modified by YLC
+// Copyright:   syrte. All Rights Reserved.
+//
+//==============================================================================
+
+#ifndef __DDS4XAD9959_H__
+#define __DDS4XAD9959_H__
+
+#ifdef __cplusplus
+    extern "C" {
+#endif
+
+//==============================================================================
+// Include files
+
+#include "cvidef.h"
+
+//==============================================================================
+// Defines
+		
+#define Adress	"192.168.0.5"								
+#define Port1 	6665										 
+#define Port2	6666										
+#define Port3	6667
+#define Port4	6668
+#define Clk		1000000000									 
+#define E48		1099511627776.0								
+#define E32		4294967296.0								
+#define E24		16777216.0									 
+#define E16		65536.0										 
+#define E8		256.0										
+
+//==============================================================================
+// Macros
+		
+#define WORD(Freq,Clk) pow(2,32)*(Freq/Clk)	
+		
+// DDS2xAD9858_Data : the data of crypto class DDS2xAD9858
+
+typedef struct {
+	double Frequency1 ; 
+	double Frequency2 ;
+	double Frequency3 ;
+	double Frequency4 ;
+	} DDS4XAD9959_Data ;
+		
+//==============================================================================		
+// Variables
+		
+char  Request[255];
+char Response[255];
+unsigned int hConv;		
+
+//==============================================================================		
+// Functions
+
+
+static int DDS4XAD9959_SendCmd(int DDSNum,char *Buffer) ; // essentially a private function, hence the static scope... 
+int DDS4XAD9959_SetFrequency(DDS4XAD9959_Data * Instance, int DDSNum, double Freq) ;		
+int DDS4XAD9959_Reset(DDS4XAD9959_Data * Instance) ;
+
+#ifdef __cplusplus
+    }
+#endif
+
+#endif  /* ndef __DDS2XAD9858_H__ */