@@ -1,6 +1,6 | |||
|
1 | 1 | ############################################################################# |
|
2 | 2 | # Makefile for building: bin/fsw |
|
3 |
# Generated by qmake (2.01a) (Qt 4.8.6) on: |
|
|
3 | # Generated by qmake (2.01a) (Qt 4.8.6) on: Tue Jun 24 09:17:30 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 |
@@ -10,7 +10,7 | |||
|
10 | 10 | |
|
11 | 11 | CC = sparc-rtems-gcc |
|
12 | 12 | CXX = sparc-rtems-g++ |
|
13 |
DEFINES = -DSW_VERSION_N1=1 -DSW_VERSION_N2=0 -DSW_VERSION_N3=0 -DSW_VERSION_N4=1 |
|
|
13 | DEFINES = -DSW_VERSION_N1=1 -DSW_VERSION_N2=0 -DSW_VERSION_N3=0 -DSW_VERSION_N4=13 -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 |
@@ -11,7 +11,7 SWVERSION=-1-0 | |||
|
11 | 11 | DEFINES += SW_VERSION_N1=1 # major |
|
12 | 12 | DEFINES += SW_VERSION_N2=0 # minor |
|
13 | 13 | DEFINES += SW_VERSION_N3=0 # patch |
|
14 |
DEFINES += SW_VERSION_N4=1 |
|
|
14 | DEFINES += SW_VERSION_N4=13 # internal | |
|
15 | 15 | |
|
16 | 16 | contains( CONFIG, debug_tch ) { |
|
17 | 17 | DEFINES += DEBUG_TCH |
@@ -1,6 +1,6 | |||
|
1 | 1 | <?xml version="1.0" encoding="UTF-8"?> |
|
2 | 2 | <!DOCTYPE QtCreatorProject> |
|
3 |
<!-- Written by QtCreator 3.0.1, 2014-06-2 |
|
|
3 | <!-- Written by QtCreator 3.0.1, 2014-06-24T12:52:17. --> | |
|
4 | 4 | <qtcreator> |
|
5 | 5 | <data> |
|
6 | 6 | <variable>ProjectExplorer.Project.ActiveTarget</variable> |
@@ -160,23 +160,29 void SM_average( float *averaged_spec_ma | |||
|
160 | 160 | |
|
161 | 161 | void ASM_reorganize_and_divide( float *averaged_spec_mat, float *averaged_spec_mat_reorganized, float divider ) |
|
162 | 162 | { |
|
163 | // reorganize the data to have a matrix in the VHDL format | |
|
164 | // INPUT (VHDL format) | |
|
165 | // component_0[0 .. 127] component_1[0 .. 127] .. component_24[0 .. 127] | |
|
166 | // OUTPUT (ICD format) | |
|
167 | // matrix_0[0 .. 24] matrix_1[0 .. 24] .. matrix_127[0 .. 24] | |
|
168 | ||
|
163 | 169 | int frequencyBin; |
|
164 | 170 | int asmComponent; |
|
165 |
unsigned int offsetA |
|
|
166 |
unsigned int offsetA |
|
|
171 | unsigned int offsetASMReorganized; | |
|
172 | unsigned int offsetASM; | |
|
167 | 173 | |
|
168 | 174 | for (asmComponent = 0; asmComponent < NB_VALUES_PER_SM; asmComponent++) |
|
169 | 175 | { |
|
170 | 176 | for( frequencyBin = 0; frequencyBin < NB_BINS_PER_SM; frequencyBin++ ) |
|
171 | 177 | { |
|
172 |
offsetA |
|
|
178 | offsetASM = | |
|
179 | asmComponent * NB_BINS_PER_SM | |
|
180 | + frequencyBin; | |
|
181 | offsetASMReorganized = | |
|
173 | 182 | frequencyBin * NB_VALUES_PER_SM |
|
174 | 183 | + asmComponent; |
|
175 | offsetAveragedSpecMat = | |
|
176 | asmComponent * NB_BINS_PER_SM | |
|
177 | + frequencyBin; | |
|
178 | averaged_spec_mat_reorganized[offsetAveragedSpecMatReorganized ] = | |
|
179 | averaged_spec_mat[ offsetAveragedSpecMat ] / divider; | |
|
184 | averaged_spec_mat_reorganized[ offsetASMReorganized ] = | |
|
185 | averaged_spec_mat[ offsetASM ] / divider; | |
|
180 | 186 | } |
|
181 | 187 | } |
|
182 | 188 | } |
@@ -215,6 +221,12 void ASM_compress_reorganize_and_divide( | |||
|
215 | 221 | |
|
216 | 222 | void ASM_convert( volatile float *input_matrix, char *output_matrix) |
|
217 | 223 | { |
|
224 | // convert the data to have a matrix in compressed float, 16 bits = [sign 1 bit *** exp 8 bits *** fraction 7 bits] | |
|
225 | // INTPUT (ICD format) | |
|
226 | // matrix_0[0 .. 24] matrix_1[0 .. 24] .. matrix_127[0 .. 24] | |
|
227 | // OUTPUT (ICD format) | |
|
228 | // matrix_0[0 .. 24] matrix_1[0 .. 24] .. matrix_127[0 .. 24] | |
|
229 | ||
|
218 | 230 | unsigned int frequencyBin; |
|
219 | 231 | unsigned int asmComponent; |
|
220 | 232 | char * pt_char_input; |
General Comments 0
You need to be logged in to leave comments.
Login now