no-OS
no_os_ain.h
Go to the documentation of this file.
1 /***************************************************************************/
38 #ifndef NO_OS_AIN_H
39 #define NO_OS_AIN_H
40 
41 /******************************************************************************/
42 /***************************** Include Files **********************************/
43 /******************************************************************************/
44 
45 #include <stdint.h>
46 
47 /******************************************************************************/
48 /********************** Macros and Constants Definitions **********************/
49 /******************************************************************************/
50 
51 /******************************************************************************/
52 /*************************** Types Declarations *******************************/
53 /******************************************************************************/
54 
60  /* Analog input reference voltage */
61  float vref;
62  /* Analog extra parameters (device specific) */
63  void *extra;
64 };
65 
71  /* Analog input reference voltage */
72  float vref;
73  /* Analog extra parameters (device specific) */
74  void *extra;
75 };
76 
77 /******************************************************************************/
78 /************************ Functions Declarations ******************************/
79 /******************************************************************************/
80 
81 /* Read analog input voltage */
82 int32_t no_os_ain_get_voltage(struct no_os_ain_desc *desc, float *value);
83 
84 /* Initialize the analog input peripheral*/
85 int32_t no_os_ain_init(struct no_os_ain_desc **desc,
86  const struct no_os_ain_init_param *param);
87 
88 /* Free the resources allocated by no_os_ain_init() */
89 int32_t no_os_ain_remove(struct no_os_ain_desc *desc);
90 
91 #endif // end of NO_OS_AIN_H
no_os_ain_get_voltage
int32_t no_os_ain_get_voltage(struct no_os_ain_desc *desc, float *value)
no_os_ain_desc
Definition: no_os_ain.h:70
no_os_ain_init_param::vref
float vref
Definition: no_os_ain.h:61
no_os_ain_init_param::extra
void * extra
Definition: no_os_ain.h:63
no_os_ain_desc::vref
float vref
Definition: no_os_ain.h:72
no_os_ain_init
int32_t no_os_ain_init(struct no_os_ain_desc **desc, const struct no_os_ain_init_param *param)
no_os_ain_desc::extra
void * extra
Definition: no_os_ain.h:74
no_os_ain_remove
int32_t no_os_ain_remove(struct no_os_ain_desc *desc)
no_os_ain_init_param
Definition: no_os_ain.h:59