-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathStateDrivenCode.h
More file actions
116 lines (97 loc) · 5.73 KB
/
StateDrivenCode.h
File metadata and controls
116 lines (97 loc) · 5.73 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
#ifndef STATEDRIVENCODE_H
#define STATEDRIVENCODE_H
/********************************************************************\
* State-driven Dynamic Configuration *
*--------------------------------------------------------------------*
* *
* File: StateDrivenCode.h *
* Generated: May 05, 2022: 01:41 PM *
* Version: 2.8.0.10 - (Standard) - Release *
* Copyright: Copyright © 2015 Okika. All rights reserved. *
* *
\********************************************************************/
#ifdef __cplusplus
extern "C" {
#endif
/*##################################################################*\
# #
# Data and Definitions #
# #
\*##################################################################*/
/* Represents an 8 bit data type. */
typedef unsigned char ot_Byte;
/* A type to represent a single State. */
typedef short ot_State;
/* This structure contains all the information about a configuration
of a chip */
typedef struct ot_stateConfigInfo
{
/* The configuration data. */
const ot_Byte* data;
/* Total byte count in the configuration data. */
short length;
} ot_stateConfigInfo;
/* Define all StateID's */
#define ot_FPAA1_to_FPAA2 0 /* "FPAA1 to FPAA2" */
#define ot_FPAA2_to_FPAA3 1 /* "FPAA2 to FPAA3" */
#define ot_FPAA3_to_FPAA4 2 /* "FPAA3 to FPAA4" */
#define ot_FPAA4_to_FPAA5 3 /* "FPAA4 to FPAA5" */
#define ot_FPAA5_to_FPAA1 4 /* "FPAA5 to FPAA1" */
/* Count of states with initial primary configurations. */
#define ot_statePrimaryCount 0
/* Count of state transitions. */
#define ot_stateTransitionCount 5
/* Configuration Data*/
extern const ot_Byte ot_FPAA1_to_FPAA2_Data[];
extern const ot_Byte ot_FPAA2_to_FPAA3_Data[];
extern const ot_Byte ot_FPAA3_to_FPAA4_Data[];
extern const ot_Byte ot_FPAA4_to_FPAA5_Data[];
extern const ot_Byte ot_FPAA5_to_FPAA1_Data[];
/* Maps states with primary configurations to the configuration data.
*/
extern const ot_stateConfigInfo ot_statePrimaryData[ot_statePrimaryCount];
/* Maps each stateID to its transition data. */
extern const ot_stateConfigInfo ot_stateTransitionData[ot_stateTransitionCount];
/*##################################################################*\
# #
# Functions #
# #
\*##################################################################*/
/*--------------------------------------------------------------*\
| GetStatePrimaryData |
+----------------------------------------------------------------+
| |
| Function Declaration |
\* ------------------------------ */
const ot_Byte* ot_GetStatePrimaryData(ot_State stateID, int* count);
/* *\
| |
| Description |
| ------------------------------ |
| Retrieves the primary configuration data for the state. The |
| returned data begins with the synch byte and ends with the |
| last error byte. There are no pad bytes included. The number |
| of bytes in the configuration data is set in count. |
| |
\*--------------------------------------------------------------*/
/*--------------------------------------------------------------*\
| GetStateTransitionData |
+----------------------------------------------------------------+
| |
| Function Declaration |
\* ------------------------------ */
const ot_Byte* ot_GetStateTransitionData(ot_State stateID, int* count);
/* *\
| |
| Description |
| ------------------------------ |
| Retrieves the transition data for the state. The returned |
| data begins with the synch byte and ends with the last error |
| byte. There are no pad bytes included. The number of bytes in |
| the configuration data is set in count. |
| |
\*--------------------------------------------------------------*/
#ifdef __cplusplus
}
#endif
#endif /* STATEDRIVENCODE_H */