libpynq
(release 5EID0-2023 version 0.3.0 of 2024-04-25 09:42 )
buttons.c
Go to the documentation of this file.
1
#include <
buttons.h
>
2
void
switches_init
(
void
){};
3
void
switches_destroy
(
void
){};
4
void
buttons_init
(
void
){};
5
void
buttons_destroy
(
void
){};
6
int
get_button_state
(
const
int
button){};
7
int
wait_until_button_state
(
const
int
button,
const
int
state){
return
0;};
8
int
sleep_msec_button_pushed
(
const
int
button,
const
int
msec){
return
0;};
9
void
sleep_msec_buttons_pushed
(
int
button_states[],
const
int
ms){};
10
int
wait_until_button_pushed
(
const
int
button){
return
0;};
11
int
wait_until_button_released
(
const
int
button){
return
0;};
12
int
wait_until_any_button_pushed
(
void
){
return
0;};
13
int
wait_until_any_button_released
(
void
){
return
0;};
14
int
get_switch_state
(
const
int
switch_num){
return
0;};
wait_until_button_released
int wait_until_button_released(const int button)
Wait until the given button is not pushed (which may be immediately).
Definition:
buttons.c:173
wait_until_button_state
int wait_until_button_state(const int button, const int state)
Wait until the given button is in state (which may be immediately).
Definition:
buttons.c:85
switches_init
void switches_init(void)
Initialise the switches before they can be used.
Definition:
buttons.c:57
wait_until_button_pushed
int wait_until_button_pushed(const int button)
Wait until the given button is pushed (which may be immediately).
Definition:
buttons.c:168
get_switch_state
int get_switch_state(const int switch_num)
Definition:
buttons.c:219
sleep_msec_buttons_pushed
void sleep_msec_buttons_pushed(int button_states[], const int ms)
Check if any button is pushed in msec milliseconds. The function does NOT return early.
Definition:
buttons.c:142
sleep_msec_button_pushed
int sleep_msec_button_pushed(const int button, const int ms)
Check if the given button is pushed in msec milliseconds. The function does NOT return early.
Definition:
buttons.c:111
buttons_init
void buttons_init(void)
Initialise the buttons before they can be used.
Definition:
buttons.c:39
buttons.h
wait_until_any_button_pushed
int wait_until_any_button_pushed(void)
Wait until any button is not pushed (which may be immediately).
Definition:
buttons.c:178
buttons_destroy
void buttons_destroy(void)
Unitialize the buttons.
Definition:
buttons.c:50
wait_until_any_button_released
int wait_until_any_button_released(void)
Wait until the given button is not pushed (which may be immediately).
Definition:
buttons.c:199
switches_destroy
void switches_destroy(void)
Unitialize the buttons.
Definition:
buttons.c:66
get_button_state
int get_button_state(const int button)
Return the state of the button (BUTTON_(NOT_)PUSHED).
Definition:
buttons.c:73
library
empty-library
buttons.c
Generated on Thu Apr 25 2024 09:42:47 for libpynq by
1.8.17