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 "stm32_hal.h"
41 #include "stm32_irq.h"
42 #include "stm32_gpio_irq.h"
43 #include "stm32_spi.h"
44 #include "stm32_gpio.h"
45 #include "stm32_uart.h"
46 #include "stm32_uart_stdio.h"
47 
48 /******************************************************************************/
49 /********************** Macros and Constants Definitions **********************/
50 /******************************************************************************/
51 
52 #ifdef IIO_LWIP_EXAMPLE
53 extern UART_HandleTypeDef huart1;
54 #define UART_INSTANCE (&huart1)
55 #define SPI_DEVICE_ID 3
56 #define SPI_CS 12
57 #define SPI_CS_PORT 6
58 #else
59 extern UART_HandleTypeDef huart5;
60 #define UART_INSTANCE (&huart5)
61 #define SPI_DEVICE_ID 1
62 #define SPI_CS 15
63 #define SPI_CS_PORT 0
64 #endif
65 
66 #ifdef IIO_SUPPORT
67 #define INTC_DEVICE_ID 0
68 #define IIO_APP_HUART (&huart5)
69 #endif
70 #define UART_IRQ_ID UART5_IRQn
71 
72 #define UART_DEVICE_ID 1
73 #define UART_BAUDRATE 115200
74 #define UART_EXTRA &adxl355_uart_extra_ip
75 #define UART_OPS &stm32_uart_ops
76 
77 #define SPI_BAUDRATE 1000000
78 #define SPI_OPS &stm32_spi_ops
79 #define SPI_EXTRA &adxl355_spi_extra_ip
80 
83 
84 #ifdef IIO_TRIGGER_EXAMPLE
85 extern struct stm32_gpio_irq_init_param adxl355_gpio_irq_extra_ip;
86 /* Setting for PortA Pin2 used for DATA_READY.
87  Has to be adapted accordingly if another pin is used.
88  */
89 #define ADXL355_GPIO_TRIG_IRQ_ID 0 /* Not used in stm32 platform */
90 #define ADXL355_GPIO_CB_HANDLE NULL /* Not used in stm32 platform */
91 
92 #define GPIO_IRQ_ID 2 /* Pin 2 */
93 #define GPIO_IRQ_OPS &stm32_gpio_irq_ops
94 #define GPIO_IRQ_EXTRA &adxl355_gpio_irq_extra_ip
95 #endif
96 
97 #ifdef IIO_LWIP_EXAMPLE
98 #define ADIN1110_GPIO_RESET_PORT 2
99 #define ADIN1110_GPIO_RESET_PIN 7
100 #define ADIN1110_SPI_DEVICE_ID 2
101 #define ADIN1110_SPI_CS 12
102 #define ADIN1110_SPI_CS_PORT 1
103 #define ADIN1110_SPI_CLK_RATE 25000000
104 #define GPIO_OPS &stm32_gpio_ops
105 
106 extern struct stm32_gpio_init_param adin1110_reset_gpio_extra_ip;
108 #endif
109 
110 #endif /* __PARAMETERS_H__ */
stm32_spi_init_param
Structure holding the initialization parameters for stm32 platform specific SPI parameters.
Definition: stm32_spi.h:51
stm32_gpio_irq_init_param
Structure holding the initialization parameters for stm32 platform specific GPIO IRQ parameters.
Definition: stm32_gpio_irq.h:44
stm32_spi.h
Header file for the stm32 spi driver.
stm32_gpio_init_param
Structure holding the initialization parameters for stm32 platform.
Definition: stm32_gpio.h:44
stm32_uart_init_param
Specific initialization parameters for stm32 UART.
Definition: stm32_uart.h:46
stm32_uart.h
Header file of UART driver for STM32.
stm32_uart_stdio.h
Header file of stm32 UART driver stdout/stdin redirection.
adin1110_spi_extra_ip
struct max_spi_init_param adin1110_spi_extra_ip
Definition: parameters.c:41
adxl355_spi_extra_ip
struct aducm_spi_init_param adxl355_spi_extra_ip
Definition: parameters.c:42
stm32_irq.h
Header file for stm32 irq specifics.
stm32_gpio.h
Header file for stm32 gpio specifics.
adxl355_uart_extra_ip
struct max_uart_init_param adxl355_uart_extra_ip
Definition: parameters.c:42
stm32_gpio_irq.h
Header file for stm32 gpio irq specifics.
huart5
UART_HandleTypeDef huart5
stm32_hal.h