precision-converters-firmware
app_config.h
Go to the documentation of this file.
1 /*************************************************************************/
14 #ifndef _APP_CONFIG_H_
15 #define _APP_CONFIG_H_
16 
17 #include <stdint.h>
18 #include <PinNames.h>
19 #include "ad5933.h"
20 
29 //#define ARDUINO
30 
31 //#warning check this
32 #ifdef ARDUINO
33 /* Arduino interface pins*/
34 #define I2C_SCL ARDUINO_UNO_D15
35 #define I2C_SDA ARDUINO_UNO_D14
36 
37 #define SPI_CS ARDUINO_UNO_D10
38 #define SPI_MISO ARDUINO_UNO_D12
39 #define SPI_MOSI ARDUINO_UNO_D11
40 #define SPI_SCK ARDUINO_UNO_D13
41 
42 #define GAIN_PIN ARDUINO_UNO_D8
43 #define RESET_PIN ARDUINO_UNO_D9
44 #define LDAC_PIN ARDUINO_UNO_D7
45 #define ADDR0_PIN ARDUINO_UNO_D6
46 #else
47 /* SDP-120 interface pins*/
48 #define I2C_SCL SDP_I2C_SCL
49 #define I2C_SDA SDP_I2C_SDA
50 
51 #define SPI_CS SDP_SPI_CS_A
52 #define SPI_MISO SDP_SPI_MISO
53 #define SPI_MOSI SDP_SPI_MOSI
54 #define SPI_SCK SDP_SPI_SCK
55 
56 #define GAIN_PIN SDP_GPIO_0
57 #define RESET_PIN SDP_GPIO_2
58 #define LDAC_PIN SDP_GPIO_3
59 #define ADDR0_PIN SDP_GPIO_4
60 #endif
61 
62 #endif //_APP_CONFIG_H_