##// END OF EJS Templates
Bug 176
paul -
r159:b822fb2ec6ef VHDLib206
parent child
Show More
@@ -1,273 +1,273
1 1 #############################################################################
2 2 # Makefile for building: bin/fsw
3 # Generated by qmake (2.01a) (Qt 4.8.6) on: Thu Jun 19 07:41:34 2014
3 # Generated by qmake (2.01a) (Qt 4.8.6) on: Fri Jun 20 15:19:24 2014
4 4 # Project: fsw-qt.pro
5 5 # Template: app
6 6 # Command: /usr/bin/qmake-qt4 -spec /usr/lib64/qt4/mkspecs/linux-g++ -o Makefile fsw-qt.pro
7 7 #############################################################################
8 8
9 9 ####### Compiler, tools and options
10 10
11 11 CC = sparc-rtems-gcc
12 12 CXX = sparc-rtems-g++
13 13 DEFINES = -DSW_VERSION_N1=1 -DSW_VERSION_N2=0 -DSW_VERSION_N3=0 -DSW_VERSION_N4=12 -DPRINT_MESSAGES_ON_CONSOLE
14 14 CFLAGS = -pipe -O3 -Wall $(DEFINES)
15 15 CXXFLAGS = -pipe -O3 -Wall $(DEFINES)
16 16 INCPATH = -I/usr/lib64/qt4/mkspecs/linux-g++ -I. -I../src -I../header -I../header/processing -I../src/LFR_basic-parameters
17 17 LINK = sparc-rtems-g++
18 18 LFLAGS =
19 19 LIBS = $(SUBLIBS)
20 20 AR = sparc-rtems-ar rcs
21 21 RANLIB =
22 22 QMAKE = /usr/bin/qmake-qt4
23 23 TAR = tar -cf
24 24 COMPRESS = gzip -9f
25 25 COPY = cp -f
26 26 SED = sed
27 27 COPY_FILE = $(COPY)
28 28 COPY_DIR = $(COPY) -r
29 29 STRIP = sparc-rtems-strip
30 30 INSTALL_FILE = install -m 644 -p
31 31 INSTALL_DIR = $(COPY_DIR)
32 32 INSTALL_PROGRAM = install -m 755 -p
33 33 DEL_FILE = rm -f
34 34 SYMLINK = ln -f -s
35 35 DEL_DIR = rmdir
36 36 MOVE = mv -f
37 37 CHK_DIR_EXISTS= test -d
38 38 MKDIR = mkdir -p
39 39
40 40 ####### Output directory
41 41
42 42 OBJECTS_DIR = obj/
43 43
44 44 ####### Files
45 45
46 46 SOURCES = ../src/wf_handler.c \
47 47 ../src/tc_handler.c \
48 48 ../src/fsw_misc.c \
49 49 ../src/fsw_init.c \
50 50 ../src/fsw_globals.c \
51 51 ../src/fsw_spacewire.c \
52 52 ../src/tc_load_dump_parameters.c \
53 53 ../src/tm_lfr_tc_exe.c \
54 54 ../src/tc_acceptance.c \
55 55 ../src/processing/fsw_processing.c \
56 56 ../src/processing/avf0_prc0.c \
57 57 ../src/processing/avf1_prc1.c \
58 58 ../src/processing/avf2_prc2.c \
59 59 ../src/lfr_cpu_usage_report.c \
60 60 ../src/LFR_basic-parameters/basic_parameters.c
61 61 OBJECTS = obj/wf_handler.o \
62 62 obj/tc_handler.o \
63 63 obj/fsw_misc.o \
64 64 obj/fsw_init.o \
65 65 obj/fsw_globals.o \
66 66 obj/fsw_spacewire.o \
67 67 obj/tc_load_dump_parameters.o \
68 68 obj/tm_lfr_tc_exe.o \
69 69 obj/tc_acceptance.o \
70 70 obj/fsw_processing.o \
71 71 obj/avf0_prc0.o \
72 72 obj/avf1_prc1.o \
73 73 obj/avf2_prc2.o \
74 74 obj/lfr_cpu_usage_report.o \
75 75 obj/basic_parameters.o
76 76 DIST = /usr/lib64/qt4/mkspecs/common/unix.conf \
77 77 /usr/lib64/qt4/mkspecs/common/linux.conf \
78 78 /usr/lib64/qt4/mkspecs/common/gcc-base.conf \
79 79 /usr/lib64/qt4/mkspecs/common/gcc-base-unix.conf \
80 80 /usr/lib64/qt4/mkspecs/common/g++-base.conf \
81 81 /usr/lib64/qt4/mkspecs/common/g++-unix.conf \
82 82 /usr/lib64/qt4/mkspecs/qconfig.pri \
83 83 /usr/lib64/qt4/mkspecs/modules/qt_webkit.pri \
84 84 /usr/lib64/qt4/mkspecs/features/qt_functions.prf \
85 85 /usr/lib64/qt4/mkspecs/features/qt_config.prf \
86 86 /usr/lib64/qt4/mkspecs/features/exclusive_builds.prf \
87 87 /usr/lib64/qt4/mkspecs/features/default_pre.prf \
88 88 sparc.pri \
89 89 /usr/lib64/qt4/mkspecs/features/release.prf \
90 90 /usr/lib64/qt4/mkspecs/features/default_post.prf \
91 91 /usr/lib64/qt4/mkspecs/features/shared.prf \
92 92 /usr/lib64/qt4/mkspecs/features/unix/gdb_dwarf_index.prf \
93 93 /usr/lib64/qt4/mkspecs/features/warn_on.prf \
94 94 /usr/lib64/qt4/mkspecs/features/resources.prf \
95 95 /usr/lib64/qt4/mkspecs/features/uic.prf \
96 96 /usr/lib64/qt4/mkspecs/features/yacc.prf \
97 97 /usr/lib64/qt4/mkspecs/features/lex.prf \
98 98 /usr/lib64/qt4/mkspecs/features/include_source_dir.prf \
99 99 fsw-qt.pro
100 100 QMAKE_TARGET = fsw
101 101 DESTDIR = bin/
102 102 TARGET = bin/fsw
103 103
104 104 first: all
105 105 ####### Implicit rules
106 106
107 107 .SUFFIXES: .o .c .cpp .cc .cxx .C
108 108
109 109 .cpp.o:
110 110 $(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
111 111
112 112 .cc.o:
113 113 $(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
114 114
115 115 .cxx.o:
116 116 $(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
117 117
118 118 .C.o:
119 119 $(CXX) -c $(CXXFLAGS) $(INCPATH) -o "$@" "$<"
120 120
121 121 .c.o:
122 122 $(CC) -c $(CFLAGS) $(INCPATH) -o "$@" "$<"
123 123
124 124 ####### Build rules
125 125
126 126 all: Makefile $(TARGET)
127 127
128 128 $(TARGET): $(OBJECTS)
129 129 @$(CHK_DIR_EXISTS) bin/ || $(MKDIR) bin/
130 130 $(LINK) $(LFLAGS) -o $(TARGET) $(OBJECTS) $(OBJCOMP) $(LIBS)
131 131
132 132 Makefile: fsw-qt.pro /usr/lib64/qt4/mkspecs/linux-g++/qmake.conf /usr/lib64/qt4/mkspecs/common/unix.conf \
133 133 /usr/lib64/qt4/mkspecs/common/linux.conf \
134 134 /usr/lib64/qt4/mkspecs/common/gcc-base.conf \
135 135 /usr/lib64/qt4/mkspecs/common/gcc-base-unix.conf \
136 136 /usr/lib64/qt4/mkspecs/common/g++-base.conf \
137 137 /usr/lib64/qt4/mkspecs/common/g++-unix.conf \
138 138 /usr/lib64/qt4/mkspecs/qconfig.pri \
139 139 /usr/lib64/qt4/mkspecs/modules/qt_webkit.pri \
140 140 /usr/lib64/qt4/mkspecs/features/qt_functions.prf \
141 141 /usr/lib64/qt4/mkspecs/features/qt_config.prf \
142 142 /usr/lib64/qt4/mkspecs/features/exclusive_builds.prf \
143 143 /usr/lib64/qt4/mkspecs/features/default_pre.prf \
144 144 sparc.pri \
145 145 /usr/lib64/qt4/mkspecs/features/release.prf \
146 146 /usr/lib64/qt4/mkspecs/features/default_post.prf \
147 147 /usr/lib64/qt4/mkspecs/features/shared.prf \
148 148 /usr/lib64/qt4/mkspecs/features/unix/gdb_dwarf_index.prf \
149 149 /usr/lib64/qt4/mkspecs/features/warn_on.prf \
150 150 /usr/lib64/qt4/mkspecs/features/resources.prf \
151 151 /usr/lib64/qt4/mkspecs/features/uic.prf \
152 152 /usr/lib64/qt4/mkspecs/features/yacc.prf \
153 153 /usr/lib64/qt4/mkspecs/features/lex.prf \
154 154 /usr/lib64/qt4/mkspecs/features/include_source_dir.prf
155 155 $(QMAKE) -spec /usr/lib64/qt4/mkspecs/linux-g++ -o Makefile fsw-qt.pro
156 156 /usr/lib64/qt4/mkspecs/common/unix.conf:
157 157 /usr/lib64/qt4/mkspecs/common/linux.conf:
158 158 /usr/lib64/qt4/mkspecs/common/gcc-base.conf:
159 159 /usr/lib64/qt4/mkspecs/common/gcc-base-unix.conf:
160 160 /usr/lib64/qt4/mkspecs/common/g++-base.conf:
161 161 /usr/lib64/qt4/mkspecs/common/g++-unix.conf:
162 162 /usr/lib64/qt4/mkspecs/qconfig.pri:
163 163 /usr/lib64/qt4/mkspecs/modules/qt_webkit.pri:
164 164 /usr/lib64/qt4/mkspecs/features/qt_functions.prf:
165 165 /usr/lib64/qt4/mkspecs/features/qt_config.prf:
166 166 /usr/lib64/qt4/mkspecs/features/exclusive_builds.prf:
167 167 /usr/lib64/qt4/mkspecs/features/default_pre.prf:
168 168 sparc.pri:
169 169 /usr/lib64/qt4/mkspecs/features/release.prf:
170 170 /usr/lib64/qt4/mkspecs/features/default_post.prf:
171 171 /usr/lib64/qt4/mkspecs/features/shared.prf:
172 172 /usr/lib64/qt4/mkspecs/features/unix/gdb_dwarf_index.prf:
173 173 /usr/lib64/qt4/mkspecs/features/warn_on.prf:
174 174 /usr/lib64/qt4/mkspecs/features/resources.prf:
175 175 /usr/lib64/qt4/mkspecs/features/uic.prf:
176 176 /usr/lib64/qt4/mkspecs/features/yacc.prf:
177 177 /usr/lib64/qt4/mkspecs/features/lex.prf:
178 178 /usr/lib64/qt4/mkspecs/features/include_source_dir.prf:
179 179 qmake: FORCE
180 180 @$(QMAKE) -spec /usr/lib64/qt4/mkspecs/linux-g++ -o Makefile fsw-qt.pro
181 181
182 182 dist:
183 183 @$(CHK_DIR_EXISTS) obj/fsw1.0.0 || $(MKDIR) obj/fsw1.0.0
184 184 $(COPY_FILE) --parents $(SOURCES) $(DIST) obj/fsw1.0.0/ && (cd `dirname obj/fsw1.0.0` && $(TAR) fsw1.0.0.tar fsw1.0.0 && $(COMPRESS) fsw1.0.0.tar) && $(MOVE) `dirname obj/fsw1.0.0`/fsw1.0.0.tar.gz . && $(DEL_FILE) -r obj/fsw1.0.0
185 185
186 186
187 187 clean:compiler_clean
188 188 -$(DEL_FILE) $(OBJECTS)
189 189 -$(DEL_FILE) *~ core *.core
190 190
191 191
192 192 ####### Sub-libraries
193 193
194 194 distclean: clean
195 195 -$(DEL_FILE) $(TARGET)
196 196 -$(DEL_FILE) Makefile
197 197
198 198
199 199 grmon:
200 200 cd bin && C:/opt/grmon-eval-2.0.29b/win32/bin/grmon.exe -uart COM4 -u
201 201
202 202 check: first
203 203
204 204 compiler_rcc_make_all:
205 205 compiler_rcc_clean:
206 206 compiler_uic_make_all:
207 207 compiler_uic_clean:
208 208 compiler_image_collection_make_all: qmake_image_collection.cpp
209 209 compiler_image_collection_clean:
210 210 -$(DEL_FILE) qmake_image_collection.cpp
211 211 compiler_yacc_decl_make_all:
212 212 compiler_yacc_decl_clean:
213 213 compiler_yacc_impl_make_all:
214 214 compiler_yacc_impl_clean:
215 215 compiler_lex_make_all:
216 216 compiler_lex_clean:
217 217 compiler_clean:
218 218
219 219 ####### Compile
220 220
221 221 obj/wf_handler.o: ../src/wf_handler.c
222 222 $(CC) -c $(CFLAGS) $(INCPATH) -o obj/wf_handler.o ../src/wf_handler.c
223 223
224 224 obj/tc_handler.o: ../src/tc_handler.c
225 225 $(CC) -c $(CFLAGS) $(INCPATH) -o obj/tc_handler.o ../src/tc_handler.c
226 226
227 227 obj/fsw_misc.o: ../src/fsw_misc.c
228 228 $(CC) -c $(CFLAGS) $(INCPATH) -o obj/fsw_misc.o ../src/fsw_misc.c
229 229
230 230 obj/fsw_init.o: ../src/fsw_init.c ../src/fsw_config.c
231 231 $(CC) -c $(CFLAGS) $(INCPATH) -o obj/fsw_init.o ../src/fsw_init.c
232 232
233 233 obj/fsw_globals.o: ../src/fsw_globals.c
234 234 $(CC) -c $(CFLAGS) $(INCPATH) -o obj/fsw_globals.o ../src/fsw_globals.c
235 235
236 236 obj/fsw_spacewire.o: ../src/fsw_spacewire.c
237 237 $(CC) -c $(CFLAGS) $(INCPATH) -o obj/fsw_spacewire.o ../src/fsw_spacewire.c
238 238
239 239 obj/tc_load_dump_parameters.o: ../src/tc_load_dump_parameters.c
240 240 $(CC) -c $(CFLAGS) $(INCPATH) -o obj/tc_load_dump_parameters.o ../src/tc_load_dump_parameters.c
241 241
242 242 obj/tm_lfr_tc_exe.o: ../src/tm_lfr_tc_exe.c
243 243 $(CC) -c $(CFLAGS) $(INCPATH) -o obj/tm_lfr_tc_exe.o ../src/tm_lfr_tc_exe.c
244 244
245 245 obj/tc_acceptance.o: ../src/tc_acceptance.c
246 246 $(CC) -c $(CFLAGS) $(INCPATH) -o obj/tc_acceptance.o ../src/tc_acceptance.c
247 247
248 248 obj/fsw_processing.o: ../src/processing/fsw_processing.c
249 249 $(CC) -c $(CFLAGS) $(INCPATH) -o obj/fsw_processing.o ../src/processing/fsw_processing.c
250 250
251 251 obj/avf0_prc0.o: ../src/processing/avf0_prc0.c
252 252 $(CC) -c $(CFLAGS) $(INCPATH) -o obj/avf0_prc0.o ../src/processing/avf0_prc0.c
253 253
254 254 obj/avf1_prc1.o: ../src/processing/avf1_prc1.c
255 255 $(CC) -c $(CFLAGS) $(INCPATH) -o obj/avf1_prc1.o ../src/processing/avf1_prc1.c
256 256
257 257 obj/avf2_prc2.o: ../src/processing/avf2_prc2.c
258 258 $(CC) -c $(CFLAGS) $(INCPATH) -o obj/avf2_prc2.o ../src/processing/avf2_prc2.c
259 259
260 260 obj/lfr_cpu_usage_report.o: ../src/lfr_cpu_usage_report.c
261 261 $(CC) -c $(CFLAGS) $(INCPATH) -o obj/lfr_cpu_usage_report.o ../src/lfr_cpu_usage_report.c
262 262
263 263 obj/basic_parameters.o: ../src/LFR_basic-parameters/basic_parameters.c
264 264 $(CC) -c $(CFLAGS) $(INCPATH) -o obj/basic_parameters.o ../src/LFR_basic-parameters/basic_parameters.c
265 265
266 266 ####### Install
267 267
268 268 install: FORCE
269 269
270 270 uninstall: FORCE
271 271
272 272 FORCE:
273 273
@@ -1,201 +1,201
1 1 <?xml version="1.0" encoding="UTF-8"?>
2 2 <!DOCTYPE QtCreatorProject>
3 <!-- Written by QtCreator 3.0.1, 2014-06-19T07:07:23. -->
3 <!-- Written by QtCreator 3.0.1, 2014-06-20T09:37:09. -->
4 4 <qtcreator>
5 5 <data>
6 6 <variable>ProjectExplorer.Project.ActiveTarget</variable>
7 7 <value type="int">0</value>
8 8 </data>
9 9 <data>
10 10 <variable>ProjectExplorer.Project.EditorSettings</variable>
11 11 <valuemap type="QVariantMap">
12 12 <value type="bool" key="EditorConfiguration.AutoIndent">true</value>
13 13 <value type="bool" key="EditorConfiguration.AutoSpacesForTabs">false</value>
14 14 <value type="bool" key="EditorConfiguration.CamelCaseNavigation">true</value>
15 15 <valuemap type="QVariantMap" key="EditorConfiguration.CodeStyle.0">
16 16 <value type="QString" key="language">Cpp</value>
17 17 <valuemap type="QVariantMap" key="value">
18 18 <value type="QByteArray" key="CurrentPreferences">CppGlobal</value>
19 19 </valuemap>
20 20 </valuemap>
21 21 <valuemap type="QVariantMap" key="EditorConfiguration.CodeStyle.1">
22 22 <value type="QString" key="language">QmlJS</value>
23 23 <valuemap type="QVariantMap" key="value">
24 24 <value type="QByteArray" key="CurrentPreferences">QmlJSGlobal</value>
25 25 </valuemap>
26 26 </valuemap>
27 27 <value type="int" key="EditorConfiguration.CodeStyle.Count">2</value>
28 28 <value type="QByteArray" key="EditorConfiguration.Codec">UTF-8</value>
29 29 <value type="bool" key="EditorConfiguration.ConstrainTooltips">false</value>
30 30 <value type="int" key="EditorConfiguration.IndentSize">4</value>
31 31 <value type="bool" key="EditorConfiguration.KeyboardTooltips">false</value>
32 32 <value type="bool" key="EditorConfiguration.MouseNavigation">true</value>
33 33 <value type="int" key="EditorConfiguration.PaddingMode">1</value>
34 34 <value type="bool" key="EditorConfiguration.ScrollWheelZooming">true</value>
35 35 <value type="int" key="EditorConfiguration.SmartBackspaceBehavior">0</value>
36 36 <value type="bool" key="EditorConfiguration.SpacesForTabs">true</value>
37 37 <value type="int" key="EditorConfiguration.TabKeyBehavior">0</value>
38 38 <value type="int" key="EditorConfiguration.TabSize">8</value>
39 39 <value type="bool" key="EditorConfiguration.UseGlobal">true</value>
40 40 <value type="int" key="EditorConfiguration.Utf8BomBehavior">1</value>
41 41 <value type="bool" key="EditorConfiguration.addFinalNewLine">true</value>
42 42 <value type="bool" key="EditorConfiguration.cleanIndentation">true</value>
43 43 <value type="bool" key="EditorConfiguration.cleanWhitespace">true</value>
44 44 <value type="bool" key="EditorConfiguration.inEntireDocument">false</value>
45 45 </valuemap>
46 46 </data>
47 47 <data>
48 48 <variable>ProjectExplorer.Project.PluginSettings</variable>
49 49 <valuemap type="QVariantMap"/>
50 50 </data>
51 51 <data>
52 52 <variable>ProjectExplorer.Project.Target.0</variable>
53 53 <valuemap type="QVariantMap">
54 54 <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Desktop-Qt 4.8.2 in PATH (System)</value>
55 55 <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName">Desktop-Qt 4.8.2 in PATH (System)</value>
56 56 <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">{5289e843-9ef2-45ce-88c6-ad27d8e08def}</value>
57 57 <value type="int" key="ProjectExplorer.Target.ActiveBuildConfiguration">0</value>
58 58 <value type="int" key="ProjectExplorer.Target.ActiveDeployConfiguration">0</value>
59 59 <value type="int" key="ProjectExplorer.Target.ActiveRunConfiguration">0</value>
60 60 <valuemap type="QVariantMap" key="ProjectExplorer.Target.BuildConfiguration.0">
61 61 <value type="QString" key="ProjectExplorer.BuildConfiguration.BuildDirectory"></value>
62 62 <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
63 63 <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
64 64 <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
65 65 <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">qmake</value>
66 66 <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
67 67 <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">QtProjectManager.QMakeBuildStep</value>
68 68 <value type="bool" key="QtProjectManager.QMakeBuildStep.LinkQmlDebuggingLibrary">false</value>
69 69 <value type="bool" key="QtProjectManager.QMakeBuildStep.LinkQmlDebuggingLibraryAuto">false</value>
70 70 <value type="QString" key="QtProjectManager.QMakeBuildStep.QMakeArguments"></value>
71 71 <value type="bool" key="QtProjectManager.QMakeBuildStep.QMakeForced">false</value>
72 72 </valuemap>
73 73 <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.1">
74 74 <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
75 75 <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Make</value>
76 76 <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
77 77 <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
78 78 <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments">
79 79 <value type="QString">-w</value>
80 80 <value type="QString">-r</value>
81 81 </valuelist>
82 82 <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">false</value>
83 83 <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments"></value>
84 84 <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
85 85 </valuemap>
86 86 <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">2</value>
87 87 <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Build</value>
88 88 <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
89 89 <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Build</value>
90 90 </valuemap>
91 91 <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.1">
92 92 <valuemap type="QVariantMap" key="ProjectExplorer.BuildStepList.Step.0">
93 93 <value type="bool" key="ProjectExplorer.BuildStep.Enabled">true</value>
94 94 <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Make</value>
95 95 <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
96 96 <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.MakeStep</value>
97 97 <valuelist type="QVariantList" key="Qt4ProjectManager.MakeStep.AutomaticallyAddedMakeArguments">
98 98 <value type="QString">-w</value>
99 99 <value type="QString">-r</value>
100 100 </valuelist>
101 101 <value type="bool" key="Qt4ProjectManager.MakeStep.Clean">true</value>
102 102 <value type="QString" key="Qt4ProjectManager.MakeStep.MakeArguments">clean</value>
103 103 <value type="QString" key="Qt4ProjectManager.MakeStep.MakeCommand"></value>
104 104 </valuemap>
105 105 <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">1</value>
106 106 <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Clean</value>
107 107 <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
108 108 <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Clean</value>
109 109 </valuemap>
110 110 <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">2</value>
111 111 <value type="bool" key="ProjectExplorer.BuildConfiguration.ClearSystemEnvironment">false</value>
112 112 <valuelist type="QVariantList" key="ProjectExplorer.BuildConfiguration.UserEnvironmentChanges"/>
113 113 <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Release</value>
114 114 <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
115 115 <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4BuildConfiguration</value>
116 116 <value type="int" key="Qt4ProjectManager.Qt4BuildConfiguration.BuildConfiguration">0</value>
117 117 <value type="bool" key="Qt4ProjectManager.Qt4BuildConfiguration.UseShadowBuild">true</value>
118 118 </valuemap>
119 119 <value type="int" key="ProjectExplorer.Target.BuildConfigurationCount">1</value>
120 120 <valuemap type="QVariantMap" key="ProjectExplorer.Target.DeployConfiguration.0">
121 121 <valuemap type="QVariantMap" key="ProjectExplorer.BuildConfiguration.BuildStepList.0">
122 122 <value type="int" key="ProjectExplorer.BuildStepList.StepsCount">0</value>
123 123 <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Deploy</value>
124 124 <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
125 125 <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.BuildSteps.Deploy</value>
126 126 </valuemap>
127 127 <value type="int" key="ProjectExplorer.BuildConfiguration.BuildStepListCount">1</value>
128 128 <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">Deploy locally</value>
129 129 <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
130 130 <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">ProjectExplorer.DefaultDeployConfiguration</value>
131 131 </valuemap>
132 132 <value type="int" key="ProjectExplorer.Target.DeployConfigurationCount">1</value>
133 133 <valuemap type="QVariantMap" key="ProjectExplorer.Target.PluginSettings"/>
134 134 <valuemap type="QVariantMap" key="ProjectExplorer.Target.RunConfiguration.0">
135 135 <valuelist type="QVariantList" key="Analyzer.Valgrind.AddedSuppressionFiles"/>
136 136 <value type="bool" key="Analyzer.Valgrind.Callgrind.CollectBusEvents">false</value>
137 137 <value type="bool" key="Analyzer.Valgrind.Callgrind.CollectSystime">false</value>
138 138 <value type="bool" key="Analyzer.Valgrind.Callgrind.EnableBranchSim">false</value>
139 139 <value type="bool" key="Analyzer.Valgrind.Callgrind.EnableCacheSim">false</value>
140 140 <value type="bool" key="Analyzer.Valgrind.Callgrind.EnableEventToolTips">true</value>
141 141 <value type="double" key="Analyzer.Valgrind.Callgrind.MinimumCostRatio">0.01</value>
142 142 <value type="double" key="Analyzer.Valgrind.Callgrind.VisualisationMinimumCostRatio">10</value>
143 143 <value type="bool" key="Analyzer.Valgrind.FilterExternalIssues">true</value>
144 144 <value type="int" key="Analyzer.Valgrind.LeakCheckOnFinish">1</value>
145 145 <value type="int" key="Analyzer.Valgrind.NumCallers">25</value>
146 146 <valuelist type="QVariantList" key="Analyzer.Valgrind.RemovedSuppressionFiles"/>
147 147 <value type="int" key="Analyzer.Valgrind.SelfModifyingCodeDetection">1</value>
148 148 <value type="bool" key="Analyzer.Valgrind.Settings.UseGlobalSettings">true</value>
149 149 <value type="bool" key="Analyzer.Valgrind.ShowReachable">false</value>
150 150 <value type="bool" key="Analyzer.Valgrind.TrackOrigins">true</value>
151 151 <value type="QString" key="Analyzer.Valgrind.ValgrindExecutable">valgrind</value>
152 152 <valuelist type="QVariantList" key="Analyzer.Valgrind.VisibleErrorKinds">
153 153 <value type="int">0</value>
154 154 <value type="int">1</value>
155 155 <value type="int">2</value>
156 156 <value type="int">3</value>
157 157 <value type="int">4</value>
158 158 <value type="int">5</value>
159 159 <value type="int">6</value>
160 160 <value type="int">7</value>
161 161 <value type="int">8</value>
162 162 <value type="int">9</value>
163 163 <value type="int">10</value>
164 164 <value type="int">11</value>
165 165 <value type="int">12</value>
166 166 <value type="int">13</value>
167 167 <value type="int">14</value>
168 168 </valuelist>
169 169 <value type="int" key="PE.EnvironmentAspect.Base">2</value>
170 170 <valuelist type="QVariantList" key="PE.EnvironmentAspect.Changes"/>
171 171 <value type="QString" key="ProjectExplorer.ProjectConfiguration.DefaultDisplayName">fsw-qt</value>
172 172 <value type="QString" key="ProjectExplorer.ProjectConfiguration.DisplayName"></value>
173 173 <value type="QString" key="ProjectExplorer.ProjectConfiguration.Id">Qt4ProjectManager.Qt4RunConfiguration:/opt/DEV_PLE/FSW-qt/fsw-qt.pro</value>
174 174 <value type="QString" key="Qt4ProjectManager.Qt4RunConfiguration.CommandLineArguments"></value>
175 175 <value type="QString" key="Qt4ProjectManager.Qt4RunConfiguration.ProFile">fsw-qt.pro</value>
176 176 <value type="bool" key="Qt4ProjectManager.Qt4RunConfiguration.UseDyldImageSuffix">false</value>
177 177 <value type="bool" key="Qt4ProjectManager.Qt4RunConfiguration.UseTerminal">true</value>
178 178 <value type="QString" key="Qt4ProjectManager.Qt4RunConfiguration.UserWorkingDirectory"></value>
179 179 <value type="uint" key="RunConfiguration.QmlDebugServerPort">3768</value>
180 180 <value type="bool" key="RunConfiguration.UseCppDebugger">true</value>
181 181 <value type="bool" key="RunConfiguration.UseCppDebuggerAuto">false</value>
182 182 <value type="bool" key="RunConfiguration.UseMultiProcess">false</value>
183 183 <value type="bool" key="RunConfiguration.UseQmlDebugger">false</value>
184 184 <value type="bool" key="RunConfiguration.UseQmlDebuggerAuto">true</value>
185 185 </valuemap>
186 186 <value type="int" key="ProjectExplorer.Target.RunConfigurationCount">1</value>
187 187 </valuemap>
188 188 </data>
189 189 <data>
190 190 <variable>ProjectExplorer.Project.TargetCount</variable>
191 191 <value type="int">1</value>
192 192 </data>
193 193 <data>
194 194 <variable>ProjectExplorer.Project.Updater.EnvironmentId</variable>
195 195 <value type="QByteArray">{2e58a81f-9962-4bba-ae6b-760177f0656c}</value>
196 196 </data>
197 197 <data>
198 198 <variable>ProjectExplorer.Project.Updater.FileVersion</variable>
199 199 <value type="int">15</value>
200 200 </data>
201 201 </qtcreator>
@@ -1,775 +1,772
1 1 /** Functions to load and dump parameters in the LFR registers.
2 2 *
3 3 * @file
4 4 * @author P. LEROY
5 5 *
6 6 * A group of functions to handle TC related to parameter loading and dumping.\n
7 7 * TC_LFR_LOAD_COMMON_PAR\n
8 8 * TC_LFR_LOAD_NORMAL_PAR\n
9 9 * TC_LFR_LOAD_BURST_PAR\n
10 10 * TC_LFR_LOAD_SBM1_PAR\n
11 11 * TC_LFR_LOAD_SBM2_PAR\n
12 12 *
13 13 */
14 14
15 15 #include "tc_load_dump_parameters.h"
16 16
17 17 int action_load_common_par(ccsdsTelecommandPacket_t *TC)
18 18 {
19 19 /** This function updates the LFR registers with the incoming common parameters.
20 20 *
21 21 * @param TC points to the TeleCommand packet that is being processed
22 22 *
23 23 *
24 24 */
25 25
26 26 parameter_dump_packet.unused0 = TC->dataAndCRC[0];
27 27 parameter_dump_packet.bw_sp0_sp1_r0_r1 = TC->dataAndCRC[1];
28 28 set_wfp_data_shaping( );
29 29 return LFR_SUCCESSFUL;
30 30 }
31 31
32 32 int action_load_normal_par(ccsdsTelecommandPacket_t *TC, rtems_id queue_id, unsigned char *time)
33 33 {
34 34 /** This function updates the LFR registers with the incoming normal parameters.
35 35 *
36 36 * @param TC points to the TeleCommand packet that is being processed
37 37 * @param queue_id is the id of the queue which handles TM related to this execution step
38 38 *
39 39 */
40 40
41 41 int result;
42 42 int flag;
43 43 rtems_status_code status;
44 44
45 45 flag = LFR_SUCCESSFUL;
46 46
47 47 if ( (lfrCurrentMode == LFR_MODE_NORMAL) ||
48 48 (lfrCurrentMode == LFR_MODE_SBM1) || (lfrCurrentMode == LFR_MODE_SBM2) ) {
49 49 status = send_tm_lfr_tc_exe_not_executable( TC, queue_id );
50 50 flag = LFR_DEFAULT;
51 51 }
52 52
53 53 // CHECK THE PARAMETERS SET CONSISTENCY
54 54 if (flag == LFR_SUCCESSFUL)
55 55 {
56 56 flag = check_common_par_consistency( TC, queue_id );
57 57 }
58 58
59 59 // SET THE PARAMETERS IF THEY ARE CONSISTENT
60 60 if (flag == LFR_SUCCESSFUL)
61 61 {
62 62 result = set_sy_lfr_n_swf_l( TC );
63 63 result = set_sy_lfr_n_swf_p( TC );
64 64 result = set_sy_lfr_n_bp_p0( TC );
65 65 result = set_sy_lfr_n_bp_p1( TC );
66 66 result = set_sy_lfr_n_asm_p( TC );
67 67 result = set_sy_lfr_n_cwf_long_f3( TC );
68 68 }
69 69
70 70 return flag;
71 71 }
72 72
73 73 int action_load_burst_par(ccsdsTelecommandPacket_t *TC, rtems_id queue_id, unsigned char *time)
74 74 {
75 75 /** This function updates the LFR registers with the incoming burst parameters.
76 76 *
77 77 * @param TC points to the TeleCommand packet that is being processed
78 78 * @param queue_id is the id of the queue which handles TM related to this execution step
79 79 *
80 80 */
81 81
82 int result;
83 82 int flag;
84 83 rtems_status_code status;
85 84 unsigned char sy_lfr_b_bp_p0;
86 85 unsigned char sy_lfr_b_bp_p1;
87 86 float aux;
88 87
89 88 flag = LFR_SUCCESSFUL;
90 89
91 90 if ( lfrCurrentMode == LFR_MODE_BURST ) {
92 91 status = send_tm_lfr_tc_exe_not_executable( TC, queue_id );
93 result = LFR_DEFAULT;
92 flag = LFR_DEFAULT;
94 93 }
95 94
96 95 sy_lfr_b_bp_p0 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_B_BP_P0 ];
97 96 sy_lfr_b_bp_p1 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_B_BP_P1 ];
98 97
99 98 // sy_lfr_b_bp_p0
100 99 if (flag == LFR_SUCCESSFUL)
101 100 {
102 101 if (sy_lfr_b_bp_p0 < DEFAULT_SY_LFR_B_BP_P0 )
103 102 {
104 103 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_B_BP_P0+10, sy_lfr_b_bp_p0 );
105 104 flag = WRONG_APP_DATA;
106 105 }
107 106 }
108 107 // sy_lfr_b_bp_p1
109 108 if (flag == LFR_SUCCESSFUL)
110 109 {
111 110 if (sy_lfr_b_bp_p1 < DEFAULT_SY_LFR_B_BP_P1 )
112 111 {
113 112 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_B_BP_P1+10, sy_lfr_b_bp_p1 );
114 113 flag = WRONG_APP_DATA;
115 114 }
116 115 }
117 116 //****************************************************************
118 117 // check the consistency between sy_lfr_b_bp_p0 and sy_lfr_b_bp_p1
119 118 if (flag == LFR_SUCCESSFUL)
120 119 {
121 120 sy_lfr_b_bp_p0 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_B_BP_P0 ];
122 121 sy_lfr_b_bp_p1 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_B_BP_P1 ];
123 122 aux = ( (float ) sy_lfr_b_bp_p1 / sy_lfr_b_bp_p0 ) - floor(sy_lfr_b_bp_p1 / sy_lfr_b_bp_p0);
124 123 if (aux != 0)
125 124 {
126 125 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_B_BP_P0+10, sy_lfr_b_bp_p0 );
127 126 flag = LFR_DEFAULT;
128 127 }
129 128 }
130 129
131 130 // SET HTE PARAMETERS
132 131 if (flag == LFR_SUCCESSFUL)
133 132 {
134 result = set_sy_lfr_b_bp_p0( TC );
135 result = set_sy_lfr_b_bp_p1( TC );
133 flag = set_sy_lfr_b_bp_p0( TC );
134 flag = set_sy_lfr_b_bp_p1( TC );
136 135 }
137 136
138 137 return flag;
139 138 }
140 139
141 140 int action_load_sbm1_par(ccsdsTelecommandPacket_t *TC, rtems_id queue_id, unsigned char *time)
142 141 {
143 142 /** This function updates the LFR registers with the incoming sbm1 parameters.
144 143 *
145 144 * @param TC points to the TeleCommand packet that is being processed
146 145 * @param queue_id is the id of the queue which handles TM related to this execution step
147 146 *
148 147 */
149 148
150 int result;
151 149 int flag;
152 150 rtems_status_code status;
153 151 unsigned char sy_lfr_s1_bp_p0;
154 152 unsigned char sy_lfr_s1_bp_p1;
155 153 float aux;
156 154
157 155 flag = LFR_SUCCESSFUL;
158 156
159 157 if ( lfrCurrentMode == LFR_MODE_SBM1 ) {
160 158 status = send_tm_lfr_tc_exe_not_executable( TC, queue_id );
161 result = LFR_DEFAULT;
159 flag = LFR_DEFAULT;
162 160 }
163 161
164 162 sy_lfr_s1_bp_p0 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_S1_BP_P0 ];
165 163 sy_lfr_s1_bp_p1 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_S1_BP_P1 ];
166 164
167 165 // sy_lfr_s1_bp_p0
168 166 if (flag == LFR_SUCCESSFUL)
169 167 {
170 168 if (sy_lfr_s1_bp_p0 < DEFAULT_SY_LFR_S1_BP_P0 )
171 169 {
172 170 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_S1_BP_P0+10, sy_lfr_s1_bp_p0 );
173 171 flag = WRONG_APP_DATA;
174 172 }
175 173 }
176 174 // sy_lfr_s1_bp_p1
177 175 if (flag == LFR_SUCCESSFUL)
178 176 {
179 177 if (sy_lfr_s1_bp_p1 < DEFAULT_SY_LFR_S1_BP_P1 )
180 178 {
181 179 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_S1_BP_P1+10, sy_lfr_s1_bp_p1 );
182 180 flag = WRONG_APP_DATA;
183 181 }
184 182 }
185 183 //******************************************************************
186 184 // check the consistency between sy_lfr_s1_bp_p0 and sy_lfr_s1_bp_p1
187 185 if (flag == LFR_SUCCESSFUL)
188 186 {
189 187 aux = ( (float ) sy_lfr_s1_bp_p1 / (sy_lfr_s1_bp_p0*0.25) ) - floor(sy_lfr_s1_bp_p1 / (sy_lfr_s1_bp_p0*0.25));
190 188 if (aux != 0)
191 189 {
192 190 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_S1_BP_P0+10, sy_lfr_s1_bp_p0 );
193 191 flag = LFR_DEFAULT;
194 192 }
195 193 }
196 194
197 195 // SET THE PARAMETERS
198 196 if (flag == LFR_SUCCESSFUL)
199 197 {
200 result = set_sy_lfr_s1_bp_p0( TC );
201 result = set_sy_lfr_s1_bp_p1( TC );
198 flag = set_sy_lfr_s1_bp_p0( TC );
199 flag = set_sy_lfr_s1_bp_p1( TC );
202 200 }
203 201
204 202 return flag;
205 203 }
206 204
207 205 int action_load_sbm2_par(ccsdsTelecommandPacket_t *TC, rtems_id queue_id, unsigned char *time)
208 206 {
209 207 /** This function updates the LFR registers with the incoming sbm2 parameters.
210 208 *
211 209 * @param TC points to the TeleCommand packet that is being processed
212 210 * @param queue_id is the id of the queue which handles TM related to this execution step
213 211 *
214 212 */
215 213
216 int result;
217 214 int flag;
218 215 rtems_status_code status;
219 216 unsigned char sy_lfr_s2_bp_p0;
220 217 unsigned char sy_lfr_s2_bp_p1;
221 218 float aux;
222 219
223 220 flag = LFR_SUCCESSFUL;
224 221
225 222 if ( lfrCurrentMode == LFR_MODE_SBM2 ) {
226 223 status = send_tm_lfr_tc_exe_not_executable( TC, queue_id );
227 result = LFR_DEFAULT;
224 flag = LFR_DEFAULT;
228 225 }
229 226
230 227 sy_lfr_s2_bp_p0 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_S2_BP_P0 ];
231 228 sy_lfr_s2_bp_p1 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_S2_BP_P1 ];
232 229
233 230 // sy_lfr_s2_bp_p0
234 231 if (flag == LFR_SUCCESSFUL)
235 232 {
236 233 if (sy_lfr_s2_bp_p0 < DEFAULT_SY_LFR_S2_BP_P0 )
237 234 {
238 235 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_S2_BP_P0+10, sy_lfr_s2_bp_p0 );
239 236 flag = WRONG_APP_DATA;
240 237 }
241 238 }
242 239 // sy_lfr_s2_bp_p1
243 240 if (flag == LFR_SUCCESSFUL)
244 241 {
245 242 if (sy_lfr_s2_bp_p1 < DEFAULT_SY_LFR_S2_BP_P1 )
246 243 {
247 244 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_S2_BP_P1+10, sy_lfr_s2_bp_p1 );
248 245 flag = WRONG_APP_DATA;
249 246 }
250 247 }
251 248 //******************************************************************
252 249 // check the consistency between sy_lfr_s2_bp_p0 and sy_lfr_s2_bp_p1
253 250 if (flag == LFR_SUCCESSFUL)
254 251 {
255 252 sy_lfr_s2_bp_p0 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_S2_BP_P0 ];
256 253 sy_lfr_s2_bp_p1 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_S2_BP_P1 ];
257 254 aux = ( (float ) sy_lfr_s2_bp_p1 / sy_lfr_s2_bp_p0 ) - floor(sy_lfr_s2_bp_p1 / sy_lfr_s2_bp_p0);
258 255 if (aux != 0)
259 256 {
260 257 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_S2_BP_P0+10, sy_lfr_s2_bp_p0 );
261 258 flag = LFR_DEFAULT;
262 259 }
263 260 }
264 261
265 262 // SET THE PARAMETERS
266 263 if (flag == LFR_SUCCESSFUL)
267 264 {
268 result = set_sy_lfr_s2_bp_p0( TC );
269 result = set_sy_lfr_s2_bp_p1( TC );
265 flag = set_sy_lfr_s2_bp_p0( TC );
266 flag = set_sy_lfr_s2_bp_p1( TC );
270 267 }
271 268
272 269 return flag;
273 270 }
274 271
275 272 int action_dump_par( rtems_id queue_id )
276 273 {
277 274 /** This function dumps the LFR parameters by sending the appropriate TM packet to the dedicated RTEMS message queue.
278 275 *
279 276 * @param queue_id is the id of the queue which handles TM related to this execution step.
280 277 *
281 278 * @return RTEMS directive status codes:
282 279 * - RTEMS_SUCCESSFUL - message sent successfully
283 280 * - RTEMS_INVALID_ID - invalid queue id
284 281 * - RTEMS_INVALID_SIZE - invalid message size
285 282 * - RTEMS_INVALID_ADDRESS - buffer is NULL
286 283 * - RTEMS_UNSATISFIED - out of message buffers
287 284 * - RTEMS_TOO_MANY - queue s limit has been reached
288 285 *
289 286 */
290 287
291 288 int status;
292 289
293 290 // UPDATE TIME
294 291 parameter_dump_packet.packetSequenceControl[0] = (unsigned char) (sequenceCounterParameterDump >> 8);
295 292 parameter_dump_packet.packetSequenceControl[1] = (unsigned char) (sequenceCounterParameterDump );
296 293 increment_seq_counter( &sequenceCounterParameterDump );
297 294
298 295 parameter_dump_packet.time[0] = (unsigned char) (time_management_regs->coarse_time>>24);
299 296 parameter_dump_packet.time[1] = (unsigned char) (time_management_regs->coarse_time>>16);
300 297 parameter_dump_packet.time[2] = (unsigned char) (time_management_regs->coarse_time>>8);
301 298 parameter_dump_packet.time[3] = (unsigned char) (time_management_regs->coarse_time);
302 299 parameter_dump_packet.time[4] = (unsigned char) (time_management_regs->fine_time>>8);
303 300 parameter_dump_packet.time[5] = (unsigned char) (time_management_regs->fine_time);
304 301 // SEND DATA
305 302 status = rtems_message_queue_send( queue_id, &parameter_dump_packet,
306 303 PACKET_LENGTH_PARAMETER_DUMP + CCSDS_TC_TM_PACKET_OFFSET + CCSDS_PROTOCOLE_EXTRA_BYTES);
307 304 if (status != RTEMS_SUCCESSFUL) {
308 305 PRINTF1("in action_dump *** ERR sending packet, code %d", status)
309 306 }
310 307
311 308 return status;
312 309 }
313 310
314 311 //***********************
315 312 // NORMAL MODE PARAMETERS
316 313
317 314 int check_common_par_consistency( ccsdsTelecommandPacket_t *TC, rtems_id queue_id )
318 315 {
319 316 unsigned char msb;
320 317 unsigned char lsb;
321 318 int flag;
322 319 float aux;
323 320 rtems_status_code status;
324 321
325 322 unsigned int sy_lfr_n_swf_l;
326 323 unsigned int sy_lfr_n_swf_p;
327 324 unsigned int sy_lfr_n_asm_p;
328 325 unsigned char sy_lfr_n_bp_p0;
329 326 unsigned char sy_lfr_n_bp_p1;
330 327 unsigned char sy_lfr_n_cwf_long_f3;
331 328
332 329 flag = LFR_SUCCESSFUL;
333 330
334 331 //***************
335 332 // get parameters
336 333 msb = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_N_SWF_L ];
337 334 lsb = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_N_SWF_L+1 ];
338 335 sy_lfr_n_swf_l = msb * 256 + lsb;
339 336
340 337 msb = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_N_SWF_P ];
341 338 lsb = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_N_SWF_P+1 ];
342 339 sy_lfr_n_swf_p = msb * 256 + lsb;
343 340
344 341 msb = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_N_ASM_P ];
345 342 lsb = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_N_ASM_P+1 ];
346 343 sy_lfr_n_asm_p = msb * 256 + lsb;
347 344
348 345 sy_lfr_n_bp_p0 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_N_BP_P0 ];
349 346
350 347 sy_lfr_n_bp_p1 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_N_BP_P1 ];
351 348
352 349 sy_lfr_n_cwf_long_f3 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_N_CWF_LONG_F3 ];
353 350
354 351 //******************
355 352 // check consistency
356 353 // sy_lfr_n_swf_l
357 354 if (sy_lfr_n_swf_l != 2048)
358 355 {
359 356 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_N_SWF_L+10, sy_lfr_n_swf_l );
360 357 flag = WRONG_APP_DATA;
361 358 }
362 359 // sy_lfr_n_swf_p
363 360 if (flag == LFR_SUCCESSFUL)
364 361 {
365 362 if ( sy_lfr_n_swf_p < 16 )
366 363 {
367 364 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_N_SWF_P+10, sy_lfr_n_swf_p );
368 365 flag = WRONG_APP_DATA;
369 366 }
370 367 }
371 368 // sy_lfr_n_bp_p0
372 369 if (flag == LFR_SUCCESSFUL)
373 370 {
374 371 if (sy_lfr_n_bp_p0 < SY_LFR_N_BP_P0)
375 372 {
376 373 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_N_BP_P0+10, sy_lfr_n_bp_p0 );
377 374 flag = WRONG_APP_DATA;
378 375 }
379 376 }
380 377 // sy_lfr_n_asm_p
381 378 if (flag == LFR_SUCCESSFUL)
382 379 {
383 380 if (sy_lfr_n_asm_p == 0)
384 381 {
385 382 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_N_ASM_P+10, sy_lfr_n_asm_p );
386 383 flag = WRONG_APP_DATA;
387 384 }
388 385 }
389 386 // sy_lfr_n_asm_p shall be a whole multiple of sy_lfr_n_bp_p0
390 387 if (flag == LFR_SUCCESSFUL)
391 388 {
392 389 aux = ( (float ) sy_lfr_n_asm_p / sy_lfr_n_bp_p0 ) - floor(sy_lfr_n_asm_p / sy_lfr_n_bp_p0);
393 390 if (aux != 0)
394 391 {
395 392 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_N_ASM_P+10, sy_lfr_n_asm_p );
396 393 flag = WRONG_APP_DATA;
397 394 }
398 395 }
399 396 // sy_lfr_n_bp_p1
400 397 if (flag == LFR_SUCCESSFUL)
401 398 {
402 399 if (sy_lfr_n_bp_p1 < SY_LFR_N_BP_P1)
403 400 {
404 401 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_N_BP_P1+10, sy_lfr_n_bp_p1 );
405 402 flag = WRONG_APP_DATA;
406 403 }
407 404 }
408 405 // sy_lfr_n_bp_p1 shall be a whole multiple of sy_lfr_n_bp_p0
409 406 if (flag == LFR_SUCCESSFUL)
410 407 {
411 408 aux = ( (float ) sy_lfr_n_bp_p1 / sy_lfr_n_bp_p0 ) - floor(sy_lfr_n_bp_p1 / sy_lfr_n_bp_p0);
412 409 if (aux != 0)
413 410 {
414 411 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_N_BP_P1+10, sy_lfr_n_bp_p1 );
415 412 flag = LFR_DEFAULT;
416 413 }
417 414 }
418 415 // sy_lfr_n_cwf_long_f3
419 416
420 417 return flag;
421 418 }
422 419
423 420 int set_sy_lfr_n_swf_l( ccsdsTelecommandPacket_t *TC )
424 421 {
425 422 /** This function sets the number of points of a snapshot (sy_lfr_n_swf_l).
426 423 *
427 424 * @param TC points to the TeleCommand packet that is being processed
428 425 * @param queue_id is the id of the queue which handles TM related to this execution step
429 426 *
430 427 */
431 428
432 429 int result;
433 430
434 431 result = LFR_SUCCESSFUL;
435 432
436 433 parameter_dump_packet.sy_lfr_n_swf_l[0] = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_N_SWF_L ];
437 434 parameter_dump_packet.sy_lfr_n_swf_l[1] = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_N_SWF_L+1 ];
438 435
439 436 return result;
440 437 }
441 438
442 439 int set_sy_lfr_n_swf_p(ccsdsTelecommandPacket_t *TC )
443 440 {
444 441 /** This function sets the time between two snapshots, in s (sy_lfr_n_swf_p).
445 442 *
446 443 * @param TC points to the TeleCommand packet that is being processed
447 444 * @param queue_id is the id of the queue which handles TM related to this execution step
448 445 *
449 446 */
450 447
451 448 int result;
452 449
453 450 result = LFR_SUCCESSFUL;
454 451
455 452 parameter_dump_packet.sy_lfr_n_swf_p[0] = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_N_SWF_P ];
456 453 parameter_dump_packet.sy_lfr_n_swf_p[1] = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_N_SWF_P+1 ];
457 454
458 455 return result;
459 456 }
460 457
461 458 int set_sy_lfr_n_asm_p( ccsdsTelecommandPacket_t *TC )
462 459 {
463 460 /** This function sets the time between two full spectral matrices transmission, in s (SY_LFR_N_ASM_P).
464 461 *
465 462 * @param TC points to the TeleCommand packet that is being processed
466 463 * @param queue_id is the id of the queue which handles TM related to this execution step
467 464 *
468 465 */
469 466
470 467 int result;
471 468
472 469 result = LFR_SUCCESSFUL;
473 470
474 471 parameter_dump_packet.sy_lfr_n_asm_p[0] = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_N_ASM_P ];
475 472 parameter_dump_packet.sy_lfr_n_asm_p[1] = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_N_ASM_P+1 ];
476 473
477 474 return result;
478 475 }
479 476
480 477 int set_sy_lfr_n_bp_p0( ccsdsTelecommandPacket_t *TC )
481 478 {
482 479 /** This function sets the time between two basic parameter sets, in s (SY_LFR_N_BP_P0).
483 480 *
484 481 * @param TC points to the TeleCommand packet that is being processed
485 482 * @param queue_id is the id of the queue which handles TM related to this execution step
486 483 *
487 484 */
488 485
489 486 int status;
490 487
491 488 status = LFR_SUCCESSFUL;
492 489
493 490 parameter_dump_packet.sy_lfr_n_bp_p0 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_N_BP_P0 ];
494 491
495 492 return status;
496 493 }
497 494
498 495 int set_sy_lfr_n_bp_p1(ccsdsTelecommandPacket_t *TC )
499 496 {
500 497 /** This function sets the time between two basic parameter sets (autocorrelation + crosscorrelation), in s (sy_lfr_n_bp_p1).
501 498 *
502 499 * @param TC points to the TeleCommand packet that is being processed
503 500 * @param queue_id is the id of the queue which handles TM related to this execution step
504 501 *
505 502 */
506 503
507 504 int status;
508 505
509 506 status = LFR_SUCCESSFUL;
510 507
511 508 parameter_dump_packet.sy_lfr_n_bp_p1 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_N_BP_P1 ];
512 509
513 510 return status;
514 511 }
515 512
516 513 int set_sy_lfr_n_cwf_long_f3(ccsdsTelecommandPacket_t *TC )
517 514 {
518 515 /** This function allows to switch from CWF_F3 packets to CWF_LONG_F3 packets.
519 516 *
520 517 * @param TC points to the TeleCommand packet that is being processed
521 518 * @param queue_id is the id of the queue which handles TM related to this execution step
522 519 *
523 520 */
524 521
525 522 int status;
526 523
527 524 status = LFR_SUCCESSFUL;
528 525
529 526 parameter_dump_packet.sy_lfr_n_cwf_long_f3 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_N_CWF_LONG_F3 ];
530 527
531 528 return status;
532 529 }
533 530
534 531 //**********************
535 532 // BURST MODE PARAMETERS
536 533 int set_sy_lfr_b_bp_p0(ccsdsTelecommandPacket_t *TC)
537 534 {
538 535 /** This function sets the time between two basic parameter sets, in s (SY_LFR_B_BP_P0).
539 536 *
540 537 * @param TC points to the TeleCommand packet that is being processed
541 538 * @param queue_id is the id of the queue which handles TM related to this execution step
542 539 *
543 540 */
544 541
545 542 int status;
546 543
547 544 status = LFR_SUCCESSFUL;
548 545
549 546 parameter_dump_packet.sy_lfr_b_bp_p0 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_B_BP_P0 ];
550 547
551 548 return status;
552 549 }
553 550
554 551 int set_sy_lfr_b_bp_p1( ccsdsTelecommandPacket_t *TC )
555 552 {
556 553 /** This function sets the time between two basic parameter sets, in s (SY_LFR_B_BP_P1).
557 554 *
558 555 * @param TC points to the TeleCommand packet that is being processed
559 556 * @param queue_id is the id of the queue which handles TM related to this execution step
560 557 *
561 558 */
562 559
563 560 int status;
564 561
565 562 status = LFR_SUCCESSFUL;
566 563
567 564 parameter_dump_packet.sy_lfr_b_bp_p1 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_B_BP_P1 ];
568 565
569 566 return status;
570 567 }
571 568
572 569 //*********************
573 570 // SBM1 MODE PARAMETERS
574 571 int set_sy_lfr_s1_bp_p0( ccsdsTelecommandPacket_t *TC )
575 572 {
576 573 /** This function sets the time between two basic parameter sets, in s (SY_LFR_S1_BP_P0).
577 574 *
578 575 * @param TC points to the TeleCommand packet that is being processed
579 576 * @param queue_id is the id of the queue which handles TM related to this execution step
580 577 *
581 578 */
582 579
583 580 int status;
584 581
585 582 status = LFR_SUCCESSFUL;
586 583
587 584 parameter_dump_packet.sy_lfr_s1_bp_p0 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_S1_BP_P0 ];
588 585
589 586 return status;
590 587 }
591 588
592 589 int set_sy_lfr_s1_bp_p1( ccsdsTelecommandPacket_t *TC )
593 590 {
594 591 /** This function sets the time between two basic parameter sets, in s (SY_LFR_S1_BP_P1).
595 592 *
596 593 * @param TC points to the TeleCommand packet that is being processed
597 594 * @param queue_id is the id of the queue which handles TM related to this execution step
598 595 *
599 596 */
600 597
601 598 int status;
602 599
603 600 status = LFR_SUCCESSFUL;
604 601
605 602 parameter_dump_packet.sy_lfr_s1_bp_p1 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_S1_BP_P1 ];
606 603
607 604 return status;
608 605 }
609 606
610 607 //*********************
611 608 // SBM2 MODE PARAMETERS
612 609 int set_sy_lfr_s2_bp_p0(ccsdsTelecommandPacket_t *TC)
613 610 {
614 611 /** This function sets the time between two basic parameter sets, in s (SY_LFR_S2_BP_P0).
615 612 *
616 613 * @param TC points to the TeleCommand packet that is being processed
617 614 * @param queue_id is the id of the queue which handles TM related to this execution step
618 615 *
619 616 */
620 617
621 618 int status;
622 619
623 620 status = LFR_SUCCESSFUL;
624 621
625 622 parameter_dump_packet.sy_lfr_s2_bp_p0 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_S2_BP_P0 ];
626 623
627 624 return status;
628 625 }
629 626
630 627 int set_sy_lfr_s2_bp_p1( ccsdsTelecommandPacket_t *TC )
631 628 {
632 629 /** This function sets the time between two basic parameter sets, in s (SY_LFR_S2_BP_P1).
633 630 *
634 631 * @param TC points to the TeleCommand packet that is being processed
635 632 * @param queue_id is the id of the queue which handles TM related to this execution step
636 633 *
637 634 */
638 635
639 636 int status;
640 637
641 638 status = LFR_SUCCESSFUL;
642 639
643 640 parameter_dump_packet.sy_lfr_s2_bp_p1 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_S2_BP_P1 ];
644 641
645 642 return status;
646 643 }
647 644
648 645
649 646 //*******************
650 647 // TC_LFR_UPDATE_INFO
651 648 unsigned int check_update_info_hk_lfr_mode( unsigned char mode )
652 649 {
653 650 unsigned int status;
654 651
655 652 if ( (mode == LFR_MODE_STANDBY) || (mode == LFR_MODE_NORMAL)
656 653 || (mode == LFR_MODE_BURST)
657 654 || (mode == LFR_MODE_SBM1) || (mode == LFR_MODE_SBM2))
658 655 {
659 656 status = LFR_SUCCESSFUL;
660 657 }
661 658 else
662 659 {
663 660 status = LFR_DEFAULT;
664 661 }
665 662
666 663 return status;
667 664 }
668 665
669 666 unsigned int check_update_info_hk_tds_mode( unsigned char mode )
670 667 {
671 668 unsigned int status;
672 669
673 670 if ( (mode == TDS_MODE_STANDBY) || (mode == TDS_MODE_NORMAL)
674 671 || (mode == TDS_MODE_BURST)
675 672 || (mode == TDS_MODE_SBM1) || (mode == TDS_MODE_SBM2)
676 673 || (mode == TDS_MODE_LFM))
677 674 {
678 675 status = LFR_SUCCESSFUL;
679 676 }
680 677 else
681 678 {
682 679 status = LFR_DEFAULT;
683 680 }
684 681
685 682 return status;
686 683 }
687 684
688 685 unsigned int check_update_info_hk_thr_mode( unsigned char mode )
689 686 {
690 687 unsigned int status;
691 688
692 689 if ( (mode == THR_MODE_STANDBY) || (mode == THR_MODE_NORMAL)
693 690 || (mode == THR_MODE_BURST))
694 691 {
695 692 status = LFR_SUCCESSFUL;
696 693 }
697 694 else
698 695 {
699 696 status = LFR_DEFAULT;
700 697 }
701 698
702 699 return status;
703 700 }
704 701
705 702 //**********
706 703 // init dump
707 704
708 705 void init_parameter_dump( void )
709 706 {
710 707 /** This function initialize the parameter_dump_packet global variable with default values.
711 708 *
712 709 */
713 710
714 711 parameter_dump_packet.targetLogicalAddress = CCSDS_DESTINATION_ID;
715 712 parameter_dump_packet.protocolIdentifier = CCSDS_PROTOCOLE_ID;
716 713 parameter_dump_packet.reserved = CCSDS_RESERVED;
717 714 parameter_dump_packet.userApplication = CCSDS_USER_APP;
718 715 parameter_dump_packet.packetID[0] = (unsigned char) (APID_TM_PARAMETER_DUMP >> 8);
719 716 parameter_dump_packet.packetID[1] = (unsigned char) APID_TM_PARAMETER_DUMP;
720 717 parameter_dump_packet.packetSequenceControl[0] = TM_PACKET_SEQ_CTRL_STANDALONE;
721 718 parameter_dump_packet.packetSequenceControl[1] = TM_PACKET_SEQ_CNT_DEFAULT;
722 719 parameter_dump_packet.packetLength[0] = (unsigned char) (PACKET_LENGTH_PARAMETER_DUMP >> 8);
723 720 parameter_dump_packet.packetLength[1] = (unsigned char) PACKET_LENGTH_PARAMETER_DUMP;
724 721 // DATA FIELD HEADER
725 722 parameter_dump_packet.spare1_pusVersion_spare2 = SPARE1_PUSVERSION_SPARE2;
726 723 parameter_dump_packet.serviceType = TM_TYPE_PARAMETER_DUMP;
727 724 parameter_dump_packet.serviceSubType = TM_SUBTYPE_PARAMETER_DUMP;
728 725 parameter_dump_packet.destinationID = TM_DESTINATION_ID_GROUND;
729 726 parameter_dump_packet.time[0] = (unsigned char) (time_management_regs->coarse_time>>24);
730 727 parameter_dump_packet.time[1] = (unsigned char) (time_management_regs->coarse_time>>16);
731 728 parameter_dump_packet.time[2] = (unsigned char) (time_management_regs->coarse_time>>8);
732 729 parameter_dump_packet.time[3] = (unsigned char) (time_management_regs->coarse_time);
733 730 parameter_dump_packet.time[4] = (unsigned char) (time_management_regs->fine_time>>8);
734 731 parameter_dump_packet.time[5] = (unsigned char) (time_management_regs->fine_time);
735 732 parameter_dump_packet.sid = SID_PARAMETER_DUMP;
736 733
737 734 //******************
738 735 // COMMON PARAMETERS
739 736 parameter_dump_packet.unused0 = DEFAULT_SY_LFR_COMMON0;
740 737 parameter_dump_packet.bw_sp0_sp1_r0_r1 = DEFAULT_SY_LFR_COMMON1;
741 738
742 739 //******************
743 740 // NORMAL PARAMETERS
744 741 parameter_dump_packet.sy_lfr_n_swf_l[0] = (unsigned char) (SY_LFR_N_SWF_L >> 8);
745 742 parameter_dump_packet.sy_lfr_n_swf_l[1] = (unsigned char) (SY_LFR_N_SWF_L );
746 743 parameter_dump_packet.sy_lfr_n_swf_p[0] = (unsigned char) (SY_LFR_N_SWF_P >> 8);
747 744 parameter_dump_packet.sy_lfr_n_swf_p[1] = (unsigned char) (SY_LFR_N_SWF_P );
748 745 parameter_dump_packet.sy_lfr_n_asm_p[0] = (unsigned char) (SY_LFR_N_ASM_P >> 8);
749 746 parameter_dump_packet.sy_lfr_n_asm_p[1] = (unsigned char) (SY_LFR_N_ASM_P );
750 747 parameter_dump_packet.sy_lfr_n_bp_p0 = (unsigned char) SY_LFR_N_BP_P0;
751 748 parameter_dump_packet.sy_lfr_n_bp_p1 = (unsigned char) SY_LFR_N_BP_P1;
752 749 parameter_dump_packet.sy_lfr_n_cwf_long_f3 = (unsigned char) SY_LFR_N_CWF_LONG_F3;
753 750
754 751 //*****************
755 752 // BURST PARAMETERS
756 753 parameter_dump_packet.sy_lfr_b_bp_p0 = (unsigned char) DEFAULT_SY_LFR_B_BP_P0;
757 754 parameter_dump_packet.sy_lfr_b_bp_p1 = (unsigned char) DEFAULT_SY_LFR_B_BP_P1;
758 755
759 756 //****************
760 757 // SBM1 PARAMETERS
761 758 parameter_dump_packet.sy_lfr_s1_bp_p0 = (unsigned char) DEFAULT_SY_LFR_S1_BP_P0; // min value is 0.25 s for the period
762 759 parameter_dump_packet.sy_lfr_s1_bp_p1 = (unsigned char) DEFAULT_SY_LFR_S1_BP_P1;
763 760
764 761 //****************
765 762 // SBM2 PARAMETERS
766 763 parameter_dump_packet.sy_lfr_s2_bp_p0 = (unsigned char) DEFAULT_SY_LFR_S2_BP_P0;
767 764 parameter_dump_packet.sy_lfr_s2_bp_p1 = (unsigned char) DEFAULT_SY_LFR_S2_BP_P1;
768 765 }
769 766
770 767
771 768
772 769
773 770
774 771
775 772
General Comments 0
You need to be logged in to leave comments. Login now