comparison DDS4xAD9959.h @ 0:d9aae7d7f2c6

Import
author Daniele Nicolodi <daniele.nicolodi@obspm.fr>
date Tue, 03 Jul 2012 10:38:59 +0200
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:d9aae7d7f2c6
1 //==============================================================================
2 //
3 // Title: DDS4xAD9959.h
4 // Purpose:
5 //
6 // Created on: by Volodimer Laurent, modified by YLC
7 // Copyright: syrte. All Rights Reserved.
8 //
9 //==============================================================================
10
11 #ifndef __DDS4XAD9959_H__
12 #define __DDS4XAD9959_H__
13
14 #ifdef __cplusplus
15 extern "C" {
16 #endif
17
18 //==============================================================================
19 // Include files
20
21 #include "cvidef.h"
22
23 //==============================================================================
24 // Defines
25
26 #define Adress "192.168.0.5"
27 #define Port1 6665
28 #define Port2 6666
29 #define Port3 6667
30 #define Port4 6668
31 #define Clk 1000000000
32 #define E48 1099511627776.0
33 #define E32 4294967296.0
34 #define E24 16777216.0
35 #define E16 65536.0
36 #define E8 256.0
37
38 //==============================================================================
39 // Macros
40
41 #define WORD(Freq,Clk) pow(2,32)*(Freq/Clk)
42
43 // DDS2xAD9858_Data : the data of crypto class DDS2xAD9858
44
45 typedef struct {
46 double Frequency1 ;
47 double Frequency2 ;
48 double Frequency3 ;
49 double Frequency4 ;
50 } DDS4XAD9959_Data ;
51
52 //==============================================================================
53 // Variables
54
55 char Request[255];
56 char Response[255];
57 unsigned int hConv;
58
59 //==============================================================================
60 // Functions
61
62
63 static int DDS4XAD9959_SendCmd(int DDSNum,char *Buffer) ; // essentially a private function, hence the static scope...
64 int DDS4XAD9959_SetFrequency(DDS4XAD9959_Data * Instance, int DDSNum, double Freq) ;
65 int DDS4XAD9959_Reset(DDS4XAD9959_Data * Instance) ;
66
67 #ifdef __cplusplus
68 }
69 #endif
70
71 #endif /* ndef __DDS2XAD9858_H__ */