gpio.h
Go to the documentation of this file.
1 /*
2  * KubOS HAL
3  * Copyright (C) 2016 Kubos Corporation
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  */
17 
32 #ifndef K_GPIO_H
33 #define K_GPIO_H
34 
35 #include "pins.h"
36 
37 typedef enum {
43 } KGPIOMode;
44 
45 typedef enum {
49 } KGPIOPullup;
50 
51 void k_gpio_init(int pin, KGPIOMode mode, KGPIOPullup pullup);
52 
53 unsigned int k_gpio_read(int pin);
54 void k_gpio_write(int pin, unsigned int val);
55 void k_gpio_toggle(int pin);
56 
57 #endif
58 
59 /* @} */
KGPIOMode
Definition: gpio.h:37
Definition: gpio.h:41
void k_gpio_init(int pin, KGPIOMode mode, KGPIOPullup pullup)
Definition: gpio.h:47
void k_gpio_write(int pin, unsigned int val)
Definition: gpio.h:42
Definition: gpio.h:38
void k_gpio_toggle(int pin)
Definition: gpio.h:48
unsigned int k_gpio_read(int pin)
Definition: gpio.h:39
KGPIOPullup
Definition: gpio.h:45
Definition: gpio.h:46
Definition: gpio.h:40