no-OS
parameters.h
Go to the documentation of this file.
1 /***************************************************************************/
34 #ifndef __PARAMETERS_H__
35 #define __PARAMETERS_H__
36 
37 /******************************************************************************/
38 /***************************** Include Files **********************************/
39 /******************************************************************************/
40 #include "maxim_irq.h"
41 #include "maxim_spi.h"
42 #include "maxim_gpio.h"
43 #include "maxim_uart.h"
44 #include "maxim_uart_stdio.h"
45 
46 /******************************************************************************/
47 /********************** Macros and Constants Definitions **********************/
48 /******************************************************************************/
49 
50 #ifdef IIO_SUPPORT
51 #define INTC_DEVICE_ID 0
52 #define UART_IRQ_ID UART0_IRQn
53 #define UART_DEVICE_ID 0
54 #define UART_BAUDRATE 57600
55 #define UART_EXTRA &adxrs290_uart_extra_ip
56 #define UART_OPS &max_uart_ops
57 #endif
58 
59 #define SPI_DEVICE_ID 0
60 #define SPI_BAUDRATE 1000000
61 #define SPI_CS 0
62 #define SPI_OPS &max_spi_ops
63 #define SPI_EXTRA &adxrs290_spi_extra_ip
64 
65 #define GPIO_OPS &max_gpio_ops
66 #define GPIO_EXTRA &adxrs290_gpio_extra_ip
67 #if (TARGET_NUM != 32655)
68 #error PIN and PORT configuration have to be adapted for the used target.
69 #else
70 #define GPIO_SYNC_PIN_NUM 9
71 #define GPIO_SYNC_PORT_NUM 1
72 #endif
73 
77 
78 
79 #ifdef IIO_TRIGGER_EXAMPLE
80 #if (TARGET_NUM != 32655)
81 #error IIO_TRIGGER_EXAMPLE is currently supported only on max32655 targets.
82 #else
83 /* Setting for Port1 Pin9 used for Sync pin.
84  Has to be adapted accordingly if another pin is used.
85  */
86 #define NVIC_GPIO_IRQ GPIO1_IRQn
87 #define GPIO_IRQ_ID 1
88 #endif
89 #define GPIO_IRQ_OPS &max_gpio_irq_ops
90 #define GPIO_IRQ_EXTRA &adxrs290_gpio_extra_ip
91 
92 #define ADXRS290_GPIO_TRIG_IRQ_ID GPIO_SYNC_PIN_NUM
93 #define ADXRS290_GPIO_CB_HANDLE MXC_GPIO_GET_GPIO(GPIO_SYNC_PORT_NUM)
94 #endif
95 
96 #endif /* __PARAMETERS_H__ */
adxrs290_uart_extra_ip
struct max_uart_init_param adxrs290_uart_extra_ip
Definition: parameters.c:42
adxrs290_gpio_extra_ip
struct max_gpio_init_param adxrs290_gpio_extra_ip
Definition: parameters.c:46
max_spi_init_param
Maxim specific SPI initialization parameters.
Definition: maxim_spi.h:53
max_uart_init_param
Aditional UART config parameters.
Definition: maxim_uart.h:55
max_gpio_init_param
GPIO platform specific init parameters.
Definition: maxim_gpio.h:55
adxrs290_spi_extra_ip
struct aducm_spi_init_param adxrs290_spi_extra_ip
Definition: parameters.c:42