µGFX
2.9
version 2.9
ginput_driver_toggle.h
Go to the documentation of this file.
1
/*
2
* This file is subject to the terms of the GFX License. If a copy of
3
* the license was not distributed with this file, you can obtain one at:
4
*
5
* http://ugfx.io/license.html
6
*/
7
8
/**
9
* @file src/ginput/ginput_driver_toggle.h
10
* @brief GINPUT header file for toggle drivers.
11
*
12
* @defgroup Toggle Toggle
13
* @ingroup GINPUT
14
* @{
15
*/
16
17
#ifndef _LLD_GINPUT_TOGGLE_H
18
#define _LLD_GINPUT_TOGGLE_H
19
20
#if GINPUT_NEED_TOGGLE || defined(__DOXYGEN__)
21
22
// Describes how the toggle bits are obtained
23
typedef
struct
GToggleConfig_t {
24
void
*id;
25
unsigned
mask;
26
unsigned
invert;
27
unsigned
mode;
28
} GToggleConfig;
29
30
/*===========================================================================*/
31
/* External declarations. */
32
/*===========================================================================*/
33
34
#ifdef __cplusplus
35
extern
"C"
{
36
#endif
37
38
extern
const
GToggleConfig GInputToggleConfigTable[GINPUT_TOGGLE_CONFIG_ENTRIES];
39
40
void
ginput_lld_toggle_init(
const
GToggleConfig *ptc);
41
unsigned
ginput_lld_toggle_getbits(
const
GToggleConfig *ptc);
42
43
/* This routine is provided to low level drivers to wakeup a value read from a thread context.
44
* Particularly useful if GINPUT_TOGGLE_POLL_PERIOD = gDelayForever
45
*/
46
void
ginputToggleWakeup(
void
);
47
48
/* This routine is provided to low level drivers to wakeup a value read from an ISR
49
* Particularly useful if GINPUT_TOGGLE_POLL_PERIOD = gDelayForever
50
*/
51
void
ginputToggleWakeupI(
void
);
52
53
#ifdef __cplusplus
54
}
55
#endif
56
57
#endif
/* GFX_USE_GINPUT && GINPUT_NEED_TOGGLE */
58
59
#endif
/* _LLD_GINPUT_TOGGLE_H */
60
/** @} */
61
Users
joel
Documents
projects
ugfx
library_v2
src
ginput
ginput_driver_toggle.h
Generated on Thu Aug 19 2021 13:46:13 for µGFX by
1.9.1