VSF Documented
vsf_linux_devfs.h
Go to the documentation of this file.
1/*****************************************************************************
2 * Copyright(C)2009-2022 by VSF Team *
3 * *
4 * Licensed under the Apache License, Version 2.0 (the "License"); *
5 * you may not use this file except in compliance with the License. *
6 * You may obtain a copy of the License at *
7 * *
8 * http://www.apache.org/licenses/LICENSE-2.0 *
9 * *
10 * Unless required by applicable law or agreed to in writing, software *
11 * distributed under the License is distributed on an "AS IS" BASIS, *
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. *
13 * See the License for the specific language governing permissions and *
14 * limitations under the License. *
15 * *
16 ****************************************************************************/
17
18#ifndef __VSF_LINUX_FS_DEVFS_INTERNAL_H__
19#define __VSF_LINUX_FS_DEVFS_INTERNAL_H__
20
21/*============================ INCLUDES ======================================*/
22
23#include "../../../../vsf_linux_cfg.h"
24
25#if VSF_USE_LINUX == ENABLED && VSF_LINUX_USE_DEVFS == ENABLED
26
27// for hardware info
28#include "hal/vsf_hal.h"
29
30#ifdef __cplusplus
31extern "C" {
32#endif
33
34/*============================ MACROS ========================================*/
35/*============================ MACROFIED FUNCTIONS ===========================*/
36/*============================ TYPES =========================================*/
37
38#if VSF_HAL_USE_GPIO == ENABLED
39typedef struct vsf_linux_gpio_chip_t {
43#endif
44
45#if VSF_USE_INPUT == ENABLED && VSF_INPUT_CFG_REGISTRATION_MECHANISM == ENABLED
46typedef struct vsf_linux_mouse_t {
50
54#endif
55
56/*============================ GLOBAL VARIABLES ==============================*/
57/*============================ LOCAL VARIABLES ===============================*/
58/*============================ PROTOTYPES ====================================*/
59
60#if VSF_HAL_USE_USART == ENABLED
61extern int vsf_linux_fs_bind_uart(char *path, vsf_usart_t *uart);
62#endif
63#if VSF_HAL_USE_I2C == ENABLED
64extern int vsf_linux_fs_bind_i2c(char *path, vsf_i2c_t *i2c);
65#endif
66#if VSF_HAL_USE_SPI == ENABLED
67extern int vsf_linux_fs_bind_spi(char *path, vsf_spi_t *spi);
68#endif
69
70#if VSF_USE_MAL == ENABLED
71extern int vsf_linux_fs_bind_mal(char *path, vk_mal_t *mal);
72#endif
73#if VSF_USE_INPUT == ENABLED && VSF_INPUT_CFG_REGISTRATION_MECHANISM == ENABLED
75extern int vsf_linux_fs_bind_mouse(char *path, vsf_linux_mouse_t *mouse);
76# if VSF_LINUX_USE_TERMINAL_KEYBOARD == ENABLED
78# endif
79#endif
80#if VSF_USE_UI == ENABLED
81extern int vsf_linux_fs_bind_disp(char *path, vk_disp_t *disp);
82#endif
83#if VSF_HAL_USE_GPIO == ENABLED
84extern int vsf_linux_fs_bind_gpio(char *path, vsf_linux_gpio_chip_t *gpio_chip);
85# if VSF_HW_GPIO_COUNT > 0
86extern int vsf_linux_fs_bind_gpio_hw(char *path);
87# endif
88#endif
89extern int vsf_linux_devfs_init(void);
90
91#ifdef __cplusplus
92}
93#endif
94
95/*============================ INCLUDES ======================================*/
96
97#if VSF_LINUX_DEVFS_USE_ALSA == ENABLED
99#endif
100
101#endif // VSF_USE_LINUX && VSF_LINUX_USE_DEVFS
102#endif // __VSF_LINUX_FS_DEV_INTERNAL_H__
103/* EOF */
Definition vsf_disp.h:173
Definition vsf_input.h:114
mal class
Definition vsf_mal.h:154
unsigned char uint8_t
Definition stdint.h:5
Definition vsf_template_gpio.h:471
Definition vsf_template_i2c.h:334
Definition vsf_linux_devfs.h:39
uint8_t port_num
Definition vsf_linux_devfs.h:40
vsf_gpio_t * ports[0]
Definition vsf_linux_devfs.h:41
Definition vsf_linux_devfs.h:46
vk_input_notifier_t notifier
Definition vsf_linux_devfs.h:47
float default_sensitivity
Definition vsf_linux_devfs.h:48
Definition vsf_linux_devfs.h:51
vk_input_notifier_t notifier
Definition vsf_linux_devfs.h:52
Definition vsf_template_spi.h:541
Definition vsf_template_usart.h:661
int vsf_linux_fs_bind_spi(char *path, vsf_spi_t *spi)
Definition vsf_linux_devfs.c:757
int vsf_linux_fs_bind_uart(char *path, vsf_usart_t *uart)
Definition vsf_linux_devfs.c:352
int vsf_linux_fs_bind_mal(char *path, vk_mal_t *mal)
Definition vsf_linux_devfs.c:844
int vsf_linux_fs_bind_terminal_keyboard(char *path, vsf_linux_terminal_keyboard_t *keyboard)
Definition vsf_linux_devfs.c:1489
int vsf_linux_devfs_init(void)
Definition vsf_linux_devfs.c:2135
int vsf_linux_fs_bind_mouse(char *path, vsf_linux_mouse_t *mouse)
Definition vsf_linux_devfs.c:1413
int vsf_linux_fs_bind_i2c(char *path, vsf_i2c_t *i2c)
Definition vsf_linux_devfs.c:530
int vsf_linux_fs_bind_gpio(char *path, vsf_linux_gpio_chip_t *gpio_chip)
Definition vsf_linux_devfs.c:2044
int vsf_linux_fs_bind_input(char *path, vk_input_notifier_t *notifier)
Definition vsf_linux_devfs.c:1361
int vsf_linux_fs_bind_disp(char *path, vk_disp_t *disp)
Definition vsf_linux_devfs.c:1853
vk_input_notifier_t notifier
Definition vsf_xboot.c:31