ccNOos
v0.0.0
Build Portable Microcontroller Applications!
io_device.c
Go to the documentation of this file.
1
/** \file io_device.c
2
* \brief <a href="https://www.inmechasol.org/" target="_blank">IMS</a>:
3
<a href="https://github.com/InMechaSol/ccNOos" target="_blank">ccNOos</a>,
4
Implementation for straight C
5
6
Copyright 2021 <a href="https://www.inmechasol.org/" target="_blank">InMechaSol, Inc</a>
7
8
Licensed under the Apache License, Version 2.0(the "License");
9
you may not use this file except in compliance with the License.
10
You may obtain a copy of the License at
11
12
http://www.apache.org/licenses/LICENSE-2.0
13
14
Unless required by applicable law or agreed to in writing, software
15
distributed under the License is distributed on an "AS IS" BASIS,
16
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17
See the License for the specific language governing permissions and
18
limitations under the License.
19
20
Notes:
21
(.c includes .h) - for straight C or
22
(.cpp includes .c which includes .h) - for C++ wrapped straight C
23
*Always compiled to a single compilation unit, either C or CPP, not both
24
25
*/
26
27
#include "
io_device.h
"
28
#include "
execution_system.h
"
29
30
31
struct
devicedatastruct
createDeviceStruct
()
32
{
33
struct
devicedatastruct
outstruct;
34
outstruct.
devstate
=
devstate_init
;
35
outstruct.
newDataReadIn
=
ui8FALSE
;
36
outstruct.
triggerWriteOperation
=
ui8FALSE
;
37
outstruct.
inbuff
.
charbuff
[0] = 0x00;
38
outstruct.
outbuff
.
charbuff
[0] = 0x00;
39
return
outstruct;
40
}
41
devicedatastruct::outbuff
union devicebufferunion outbuff
Definition:
io_device.h:64
execution_system.h
IMS: ccNOos, Declarations for straight C and C++
devicedatastruct::newDataReadIn
UI_8 newDataReadIn
Definition:
io_device.h:66
devicebufferunion::charbuff
char charbuff[charBuffMax]
Definition:
io_device.h:55
io_device.h
IMS: ccNOos, Declarations for straight C and C++
devicedatastruct
the common data struct of io devices
Definition:
io_device.h:62
createDeviceStruct
struct devicedatastruct createDeviceStruct()
Definition:
io_device.c:31
devicedatastruct::triggerWriteOperation
UI_8 triggerWriteOperation
Definition:
io_device.h:67
devicedatastruct::inbuff
union devicebufferunion inbuff
Definition:
io_device.h:63
ui8FALSE
#define ui8FALSE
Definition:
version_config.h:190
devstate_init
@ devstate_init
Definition:
io_device.h:42
devicedatastruct::devstate
enum devicestateenum devstate
Definition:
io_device.h:65
ioDevice
io_device.c
Generated by
1.8.20