]> git.sur5r.net Git - freertos/blob - FreeRTOS/Demo/CORTEX_A9_Zynq_ZC702/RTOSDemo_bsp/ps7_cortexa9_0/libsrc/standalone_v4_1/src/xenv.h
Add back Zynq demo - this time using SDK V14.2.
[freertos] / FreeRTOS / Demo / CORTEX_A9_Zynq_ZC702 / RTOSDemo_bsp / ps7_cortexa9_0 / libsrc / standalone_v4_1 / src / xenv.h
1 /******************************************************************************
2 *
3 *       XILINX IS PROVIDING THIS DESIGN, CODE, OR INFORMATION "AS IS"
4 *       AS A COURTESY TO YOU, SOLELY FOR USE IN DEVELOPING PROGRAMS AND
5 *       SOLUTIONS FOR XILINX DEVICES.  BY PROVIDING THIS DESIGN, CODE,
6 *       OR INFORMATION AS ONE POSSIBLE IMPLEMENTATION OF THIS FEATURE,
7 *       APPLICATION OR STANDARD, XILINX IS MAKING NO REPRESENTATION
8 *       THAT THIS IMPLEMENTATION IS FREE FROM ANY CLAIMS OF INFRINGEMENT,
9 *       AND YOU ARE RESPONSIBLE FOR OBTAINING ANY RIGHTS YOU MAY REQUIRE
10 *       FOR YOUR IMPLEMENTATION.  XILINX EXPRESSLY DISCLAIMS ANY
11 *       WARRANTY WHATSOEVER WITH RESPECT TO THE ADEQUACY OF THE
12 *       IMPLEMENTATION, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OR
13 *       REPRESENTATIONS THAT THIS IMPLEMENTATION IS FREE FROM CLAIMS OF
14 *       INFRINGEMENT, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
15 *       FOR A PARTICULAR PURPOSE.
16 *
17 *       (c) Copyright 2002 Xilinx Inc.
18 *       All rights reserved.
19 *
20 ******************************************************************************/
21 /*****************************************************************************/
22 /**
23 *
24 * @file xenv.h
25 *
26 * Defines common services that are typically found in a host operating.
27 * environment. This include file simply includes an OS specific file based
28 * on the compile-time constant BUILD_ENV_*, where * is the name of the target
29 * environment.
30 *
31 * All services are defined as macros.
32 *
33 * <pre>
34 * MODIFICATION HISTORY:
35 *
36 * Ver   Who  Date     Changes
37 * ----- ---- -------- -----------------------------------------------
38 * 1.00b ch   10/24/02 Added XENV_LINUX
39 * 1.00a rmm  04/17/02 First release
40 * </pre>
41 *
42 ******************************************************************************/
43
44 #ifndef XENV_H /* prevent circular inclusions */
45 #define XENV_H /* by using protection macros */
46
47 #ifdef __cplusplus
48 extern "C" {
49 #endif
50
51 /*
52  * Select which target environment we are operating under
53  */
54
55 /* VxWorks target environment */
56 #if defined XENV_VXWORKS
57 #include "xenv_vxworks.h"
58
59 /* Linux target environment */
60 #elif defined XENV_LINUX
61 #include "xenv_linux.h"
62
63 /* Unit test environment */
64 #elif defined XENV_UNITTEST
65 #include "ut_xenv.h"
66
67 /* Integration test environment */
68 #elif defined XENV_INTTEST
69 #include "int_xenv.h"
70
71 /* Standalone environment selected */
72 #else
73 #include "xenv_standalone.h"
74 #endif
75
76
77 /*
78  * The following comments specify the types and macro wrappers that are
79  * expected to be defined by the target specific header files
80  */
81
82 /**************************** Type Definitions *******************************/
83
84 /*****************************************************************************/
85 /**
86  *
87  * XENV_TIME_STAMP
88  *
89  * A structure that contains a time stamp used by other time stamp macros
90  * defined below. This structure is processor dependent.
91  */
92
93
94 /***************** Macros (Inline Functions) Definitions *********************/
95
96 /*****************************************************************************/
97 /**
98  *
99  * XENV_MEM_COPY(void *DestPtr, void *SrcPtr, unsigned Bytes)
100  *
101  * Copies a non-overlapping block of memory.
102  *
103  * @param   DestPtr is the destination address to copy data to.
104  * @param   SrcPtr is the source address to copy data from.
105  * @param   Bytes is the number of bytes to copy.
106  *
107  * @return  None
108  */
109
110 /*****************************************************************************/
111 /**
112  *
113  * XENV_MEM_FILL(void *DestPtr, char Data, unsigned Bytes)
114  *
115  * Fills an area of memory with constant data.
116  *
117  * @param   DestPtr is the destination address to set.
118  * @param   Data contains the value to set.
119  * @param   Bytes is the number of bytes to set.
120  *
121  * @return  None
122  */
123 /*****************************************************************************/
124 /**
125  *
126  * XENV_TIME_STAMP_GET(XTIME_STAMP *StampPtr)
127  *
128  * Samples the processor's or external timer's time base counter.
129  *
130  * @param   StampPtr is the storage for the retrieved time stamp.
131  *
132  * @return  None
133  */
134
135 /*****************************************************************************/
136 /**
137  *
138  * XENV_TIME_STAMP_DELTA_US(XTIME_STAMP *Stamp1Ptr, XTIME_STAMP* Stamp2Ptr)
139  *
140  * Computes the delta between the two time stamps.
141  *
142  * @param   Stamp1Ptr - First sampled time stamp.
143  * @param   Stamp1Ptr - Sedond sampled time stamp.
144  *
145  * @return  An unsigned int value with units of microseconds.
146  */
147
148 /*****************************************************************************/
149 /**
150  *
151  * XENV_TIME_STAMP_DELTA_MS(XTIME_STAMP *Stamp1Ptr, XTIME_STAMP* Stamp2Ptr)
152  *
153  * Computes the delta between the two time stamps.
154  *
155  * @param   Stamp1Ptr - First sampled time stamp.
156  * @param   Stamp1Ptr - Sedond sampled time stamp.
157  *
158  * @return  An unsigned int value with units of milliseconds.
159  */
160
161 /*****************************************************************************//**
162  *
163  * XENV_USLEEP(unsigned delay)
164  *
165  * Delay the specified number of microseconds.
166  *
167  * @param   delay is the number of microseconds to delay.
168  *
169  * @return  None
170  */
171
172 #ifdef __cplusplus
173 }
174 #endif
175
176 #endif            /* end of protection macro */
177