no-OS
no_os_ain.h
Go to the documentation of this file.
1 /***************************************************************************/
32 #ifndef NO_OS_AIN_H
33 #define NO_OS_AIN_H
34 
35 /******************************************************************************/
36 /***************************** Include Files **********************************/
37 /******************************************************************************/
38 
39 #include <stdint.h>
40 
41 /******************************************************************************/
42 /********************** Macros and Constants Definitions **********************/
43 /******************************************************************************/
44 
45 /******************************************************************************/
46 /*************************** Types Declarations *******************************/
47 /******************************************************************************/
48 
54  /* Analog input reference voltage */
55  float vref;
56  /* Analog extra parameters (device specific) */
57  void *extra;
58 };
59 
65  /* Analog input reference voltage */
66  float vref;
67  /* Analog extra parameters (device specific) */
68  void *extra;
69 };
70 
71 /******************************************************************************/
72 /************************ Functions Declarations ******************************/
73 /******************************************************************************/
74 
75 /* Read analog input voltage */
76 int32_t no_os_ain_get_voltage(struct no_os_ain_desc *desc, float *value);
77 
78 /* Initialize the analog input peripheral*/
79 int32_t no_os_ain_init(struct no_os_ain_desc **desc,
80  const struct no_os_ain_init_param *param);
81 
82 /* Free the resources allocated by no_os_ain_init() */
83 int32_t no_os_ain_remove(struct no_os_ain_desc *desc);
84 
85 #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:64
no_os_ain_init_param::vref
float vref
Definition: no_os_ain.h:55
no_os_ain_init_param::extra
void * extra
Definition: no_os_ain.h:57
no_os_ain_desc::vref
float vref
Definition: no_os_ain.h:66
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:68
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:53