libpruio  0.6.8
Fast and easy Digital/Analog Input/Output for Beaglebones
pruio_gpio.bi
Go to the documentation of this file.
1 
9 
10 
11 
20 TYPE GpioSet
21  AS UInt32 _
22  DeAd _
23  , ClAd _
24  , ClVa
25 
26  AS UInt32 _
27  REVISION _
28  , SYSCONFIG _
29  , EOI _
30  , IRQSTATUS_RAW_0 _
31  , IRQSTATUS_RAW_1 _
32  , IRQSTATUS_0 _
33  , IRQSTATUS_1 _
34  , IRQSTATUS_SET_0 _
35  , IRQSTATUS_SET_1 _
36  , IRQSTATUS_CLR_0 _
37  , IRQSTATUS_CLR_1 _
38  , IRQWAKEN_0 _
39  , IRQWAKEN_1 _
40  , SYSSTATUS _
41  , CTRL _
42  , OE _
43  , DATAIN _
44  , DATAOUT _
45  , LEVELDETECT0 _
46  , LEVELDETECT1 _
47  , RISINGDETECT _
48  , FALLINGDETECT _
49  , DEBOUNCENABLE _
50  , DEBOUNCINGTIME _
51  , CLEARDATAOUT _
52  , SETDATAOUT
53 END TYPE
54 
55 
62 TYPE GpioArr
63  AS UInt32 _
64  DeAd
65  AS UInt32 _
66  DATAIN _
67  , DATAOUT _
68  , Mix
69 END TYPE
70 
71 
72 
81 TYPE GpioUdt
82  AS Pruio_ PTR Top
83  AS GpioSet PTR _
86  AS GpioArr PTR _
88  AS UInt32 _
89  InitParA _
90  , Mask
91  AS UInt8 _
92  Mode _
93  , Indx _
94  , Fe1 _
95  , Fe2
96  AS ZSTRING PTR _
97  E0 = @"GPIO subsystem not enabled" _
98  , E1 = @"no GPIO mode" _
99  , E2 = @"no GPIO pin"
100 
101  DECLARE CONSTRUCTOR (BYVAL AS Pruio_ PTR)
102  DECLARE FUNCTION initialize CDECL() AS ZSTRING PTR
103  DECLARE FUNCTION config CDECL( _
104  BYVAL AS UInt8 _
105  , BYVAL AS UInt8 = CAST(UInt8, PRUIO_GPIO_IN_0)) AS ZSTRING PTR
106  DECLARE SUB setGpioSs CDECL()
107  DECLARE FUNCTION flush CDECL(BYVAL AS UInt8) AS ZSTRING PTR
108  DECLARE FUNCTION Value CDECL( _
109  BYVAL AS UInt8) AS Int32
110  DECLARE FUNCTION setValue CDECL( _
111  BYVAL AS UInt8 _
112  , BYVAL AS UInt8 = 0) AS ZSTRING PTR
113 END TYPE
114