##// END OF EJS Templates
Removed last dead code function found and set FSW ver to 3.2.0.23
Removed last dead code function found and set FSW ver to 3.2.0.23

File last commit:

r390:1c936ff95146 No PWD scrub with...
r403:56ae035bb062 3.2.0.23 R3++
Show More
tc_load_dump_parameters.c
2088 lines | 75.9 KiB | text/x-c | CLexer
/ src / tc_load_dump_parameters.c
Added GPL header and documented some more functions
r390 /*------------------------------------------------------------------------------
-- Solar Orbiter's Low Frequency Receiver Flight Software (LFR FSW),
-- This file is a part of the LFR FSW
-- Copyright (C) 2012-2018, Plasma Physics Laboratory - CNRS
--
-- This program is free software; you can redistribute it and/or modify
-- it under the terms of the GNU General Public License as published by
-- the Free Software Foundation; either version 2 of the License, or
-- (at your option) any later version.
--
-- This program is distributed in the hope that it will be useful,
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-- GNU General Public License for more details.
--
-- You should have received a copy of the GNU General Public License
-- along with this program; if not, write to the Free Software
-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-------------------------------------------------------------------------------*/
/*-- Author : Paul Leroy
-- Contact : Alexis Jeandet
-- Mail : alexis.jeandet@lpp.polytechnique.fr
----------------------------------------------------------------------------*/
paul
Header files inclusion reworked...
r40 /** Functions to load and dump parameters in the LFR registers.
*
* @file
* @author P. LEROY
*
* A group of functions to handle TC related to parameter loading and dumping.\n
* TC_LFR_LOAD_COMMON_PAR\n
* TC_LFR_LOAD_NORMAL_PAR\n
* TC_LFR_LOAD_BURST_PAR\n
* TC_LFR_LOAD_SBM1_PAR\n
* TC_LFR_LOAD_SBM2_PAR\n
*
*/
#include "tc_load_dump_parameters.h"
paul
Bug #796 Don_Initialisation_P1
r321 Packet_TM_LFR_KCOEFFICIENTS_DUMP_t kcoefficients_dump_1 = {0};
Packet_TM_LFR_KCOEFFICIENTS_DUMP_t kcoefficients_dump_2 = {0};
ring_node kcoefficient_node_1 = {0};
ring_node kcoefficient_node_2 = {0};
paul
TC_LFR_LOAD_KCOEFFICIENTS...
r194
paul
Header files inclusion reworked...
r40 int action_load_common_par(ccsdsTelecommandPacket_t *TC)
{
/** This function updates the LFR registers with the incoming common parameters.
*
* @param TC points to the TeleCommand packet that is being processed
*
*
*/
paul
Minor changes in .h inclusion
r45
paul
R2 parameter added to TC_LFR_LOAD_COMMON_PAR...
r195 parameter_dump_packet.sy_lfr_common_parameters_spare = TC->dataAndCRC[0];
parameter_dump_packet.sy_lfr_common_parameters = TC->dataAndCRC[1];
paul
Sync
r97 set_wfp_data_shaping( );
paul
Header files inclusion reworked...
r40 return LFR_SUCCESSFUL;
}
paul
fsw-0-23...
r75 int action_load_normal_par(ccsdsTelecommandPacket_t *TC, rtems_id queue_id, unsigned char *time)
paul
Header files inclusion reworked...
r40 {
/** This function updates the LFR registers with the incoming normal parameters.
*
* @param TC points to the TeleCommand packet that is being processed
* @param queue_id is the id of the queue which handles TM related to this execution step
*
*/
paul
Minor changes in .h inclusion
r45
paul
Header files inclusion reworked...
r40 int result;
int flag;
paul
Minor modifications to meet Logiscope requirements
r78 rtems_status_code status;
paul
Header files inclusion reworked...
r40
flag = LFR_SUCCESSFUL;
paul
fsw-0-20
r58 if ( (lfrCurrentMode == LFR_MODE_NORMAL) ||
(lfrCurrentMode == LFR_MODE_SBM1) || (lfrCurrentMode == LFR_MODE_SBM2) ) {
paul
rev 1.0.0.2...
r104 status = send_tm_lfr_tc_exe_not_executable( TC, queue_id );
paul
Header files inclusion reworked...
r40 flag = LFR_DEFAULT;
}
paul
Bug #167...
r152 // CHECK THE PARAMETERS SET CONSISTENCY
paul
Bug #167
r142 if (flag == LFR_SUCCESSFUL)
{
paul
3.0.0.21...
r275 flag = check_normal_par_consistency( TC, queue_id );
paul
Bug #167
r142 }
paul
Bug #167...
r152 // SET THE PARAMETERS IF THEY ARE CONSISTENT
paul
There is a message queue between AVFO and MATR...
r118 if (flag == LFR_SUCCESSFUL)
{
paul
Bug #167...
r152 result = set_sy_lfr_n_swf_l( TC );
result = set_sy_lfr_n_swf_p( TC );
result = set_sy_lfr_n_bp_p0( TC );
result = set_sy_lfr_n_bp_p1( TC );
result = set_sy_lfr_n_asm_p( TC );
result = set_sy_lfr_n_cwf_long_f3( TC );
paul
ICD 2.0...
r92 }
paul
fsw-0-20
r58 return flag;
paul
Header files inclusion reworked...
r40 }
paul
fsw-0-23...
r75 int action_load_burst_par(ccsdsTelecommandPacket_t *TC, rtems_id queue_id, unsigned char *time)
paul
Header files inclusion reworked...
r40 {
/** This function updates the LFR registers with the incoming burst parameters.
*
* @param TC points to the TeleCommand packet that is being processed
* @param queue_id is the id of the queue which handles TM related to this execution step
*
*/
paul
Minor changes in .h inclusion
r45
paul
Sync...
r117 int flag;
paul
Minor modifications to meet Logiscope requirements
r78 rtems_status_code status;
paul
Sync...
r117 unsigned char sy_lfr_b_bp_p0;
unsigned char sy_lfr_b_bp_p1;
float aux;
paul
Header files inclusion reworked...
r40
paul
Sync...
r117 flag = LFR_SUCCESSFUL;
paul
Header files inclusion reworked...
r40
paul
Sync...
r117 if ( lfrCurrentMode == LFR_MODE_BURST ) {
paul
rev 1.0.0.2...
r104 status = send_tm_lfr_tc_exe_not_executable( TC, queue_id );
paul
Bug #176
r159 flag = LFR_DEFAULT;
paul
Header files inclusion reworked...
r40 }
paul
Bug #167...
r152 sy_lfr_b_bp_p0 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_B_BP_P0 ];
sy_lfr_b_bp_p1 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_B_BP_P1 ];
paul
correction de bug #485
r223 // sy_lfr_b_bp_p0 shall not be lower than its default value
paul
Bug #167...
r152 if (flag == LFR_SUCCESSFUL)
{
if (sy_lfr_b_bp_p0 < DEFAULT_SY_LFR_B_BP_P0 )
{
paul
Many corrections, mainly related to #807 Don_Enumeration
r318 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_B_BP_P0 + DATAFIELD_OFFSET, sy_lfr_b_bp_p0 );
paul
Bug #167...
r152 flag = WRONG_APP_DATA;
}
}
paul
correction de bug #485
r223 // sy_lfr_b_bp_p1 shall not be lower than its default value
paul
Bug #167...
r152 if (flag == LFR_SUCCESSFUL)
{
if (sy_lfr_b_bp_p1 < DEFAULT_SY_LFR_B_BP_P1 )
{
paul
Many corrections, mainly related to #807 Don_Enumeration
r318 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_B_BP_P1 + DATAFIELD_OFFSET, sy_lfr_b_bp_p1 );
paul
Bug #167...
r152 flag = WRONG_APP_DATA;
}
}
paul
Sync...
r117 //****************************************************************
// check the consistency between sy_lfr_b_bp_p0 and sy_lfr_b_bp_p1
if (flag == LFR_SUCCESSFUL)
{
sy_lfr_b_bp_p0 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_B_BP_P0 ];
sy_lfr_b_bp_p1 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_B_BP_P1 ];
aux = ( (float ) sy_lfr_b_bp_p1 / sy_lfr_b_bp_p0 ) - floor(sy_lfr_b_bp_p1 / sy_lfr_b_bp_p0);
paul
Many corrections done after Logiscope analysis
r166 if (aux > FLOAT_EQUAL_ZERO)
paul
Sync...
r117 {
paul
Many corrections, mainly related to #807 Don_Enumeration
r318 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_B_BP_P0 + DATAFIELD_OFFSET, sy_lfr_b_bp_p0 );
paul
Sync...
r117 flag = LFR_DEFAULT;
}
paul
Header files inclusion reworked...
r40 }
paul
correction de bug #485
r223 // SET THE PARAMETERS
paul
Sync...
r117 if (flag == LFR_SUCCESSFUL)
{
paul
Bug #176
r159 flag = set_sy_lfr_b_bp_p0( TC );
flag = set_sy_lfr_b_bp_p1( TC );
paul
Sync...
r117 }
return flag;
paul
Header files inclusion reworked...
r40 }
paul
fsw-0-23...
r75 int action_load_sbm1_par(ccsdsTelecommandPacket_t *TC, rtems_id queue_id, unsigned char *time)
paul
Header files inclusion reworked...
r40 {
/** This function updates the LFR registers with the incoming sbm1 parameters.
*
* @param TC points to the TeleCommand packet that is being processed
* @param queue_id is the id of the queue which handles TM related to this execution step
*
*/
paul
Sync...
r117 int flag;
rtems_status_code status;
unsigned char sy_lfr_s1_bp_p0;
unsigned char sy_lfr_s1_bp_p1;
float aux;
paul
Header files inclusion reworked...
r40
paul
Sync...
r117 flag = LFR_SUCCESSFUL;
if ( lfrCurrentMode == LFR_MODE_SBM1 ) {
paul
rev 1.0.0.2...
r104 status = send_tm_lfr_tc_exe_not_executable( TC, queue_id );
paul
Bug #176
r159 flag = LFR_DEFAULT;
paul
Header files inclusion reworked...
r40 }
paul
Bug #167...
r152 sy_lfr_s1_bp_p0 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_S1_BP_P0 ];
sy_lfr_s1_bp_p1 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_S1_BP_P1 ];
// sy_lfr_s1_bp_p0
if (flag == LFR_SUCCESSFUL)
{
if (sy_lfr_s1_bp_p0 < DEFAULT_SY_LFR_S1_BP_P0 )
{
paul
Many corrections, mainly related to #807 Don_Enumeration
r318 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_S1_BP_P0 + DATAFIELD_OFFSET, sy_lfr_s1_bp_p0 );
paul
Bug #167...
r152 flag = WRONG_APP_DATA;
}
}
// sy_lfr_s1_bp_p1
if (flag == LFR_SUCCESSFUL)
{
if (sy_lfr_s1_bp_p1 < DEFAULT_SY_LFR_S1_BP_P1 )
{
paul
Many corrections, mainly related to #807 Don_Enumeration
r318 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_S1_BP_P1 + DATAFIELD_OFFSET, sy_lfr_s1_bp_p1 );
paul
Bug #167...
r152 flag = WRONG_APP_DATA;
}
}
paul
Sync...
r117 //******************************************************************
// check the consistency between sy_lfr_s1_bp_p0 and sy_lfr_s1_bp_p1
if (flag == LFR_SUCCESSFUL)
{
paul
Many corrections, mainly related to #807 Don_Enumeration
r318 aux = ( (float ) sy_lfr_s1_bp_p1 / (sy_lfr_s1_bp_p0 * S1_BP_P0_SCALE) )
- floor(sy_lfr_s1_bp_p1 / (sy_lfr_s1_bp_p0 * S1_BP_P0_SCALE));
paul
Many corrections done after Logiscope analysis
r166 if (aux > FLOAT_EQUAL_ZERO)
paul
Sync...
r117 {
paul
Many corrections, mainly related to #807 Don_Enumeration
r318 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_S1_BP_P0 + DATAFIELD_OFFSET, sy_lfr_s1_bp_p0 );
paul
Sync...
r117 flag = LFR_DEFAULT;
}
paul
Header files inclusion reworked...
r40 }
paul
Bug #167...
r152 // SET THE PARAMETERS
paul
Sync...
r117 if (flag == LFR_SUCCESSFUL)
{
paul
Bug #176
r159 flag = set_sy_lfr_s1_bp_p0( TC );
flag = set_sy_lfr_s1_bp_p1( TC );
paul
Sync...
r117 }
return flag;
paul
Header files inclusion reworked...
r40 }
paul
fsw-0-23...
r75 int action_load_sbm2_par(ccsdsTelecommandPacket_t *TC, rtems_id queue_id, unsigned char *time)
paul
Header files inclusion reworked...
r40 {
/** This function updates the LFR registers with the incoming sbm2 parameters.
*
* @param TC points to the TeleCommand packet that is being processed
* @param queue_id is the id of the queue which handles TM related to this execution step
*
*/
paul
Sync...
r117 int flag;
paul
Minor modifications to meet Logiscope requirements
r78 rtems_status_code status;
paul
Sync...
r117 unsigned char sy_lfr_s2_bp_p0;
unsigned char sy_lfr_s2_bp_p1;
float aux;
paul
Header files inclusion reworked...
r40
paul
Sync...
r117 flag = LFR_SUCCESSFUL;
paul
Header files inclusion reworked...
r40
paul
Sync...
r117 if ( lfrCurrentMode == LFR_MODE_SBM2 ) {
paul
rev 1.0.0.2...
r104 status = send_tm_lfr_tc_exe_not_executable( TC, queue_id );
paul
Bug #176
r159 flag = LFR_DEFAULT;
paul
Header files inclusion reworked...
r40 }
paul
Bug #167...
r152 sy_lfr_s2_bp_p0 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_S2_BP_P0 ];
sy_lfr_s2_bp_p1 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_S2_BP_P1 ];
// sy_lfr_s2_bp_p0
if (flag == LFR_SUCCESSFUL)
{
if (sy_lfr_s2_bp_p0 < DEFAULT_SY_LFR_S2_BP_P0 )
{
paul
Many corrections, mainly related to #807 Don_Enumeration
r318 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_S2_BP_P0 + DATAFIELD_OFFSET, sy_lfr_s2_bp_p0 );
paul
Bug #167...
r152 flag = WRONG_APP_DATA;
}
}
// sy_lfr_s2_bp_p1
if (flag == LFR_SUCCESSFUL)
{
if (sy_lfr_s2_bp_p1 < DEFAULT_SY_LFR_S2_BP_P1 )
{
paul
Many corrections, mainly related to #807 Don_Enumeration
r318 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_S2_BP_P1 + DATAFIELD_OFFSET, sy_lfr_s2_bp_p1 );
paul
Bug #167...
r152 flag = WRONG_APP_DATA;
}
}
paul
Sync...
r117 //******************************************************************
// check the consistency between sy_lfr_s2_bp_p0 and sy_lfr_s2_bp_p1
if (flag == LFR_SUCCESSFUL)
{
sy_lfr_s2_bp_p0 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_S2_BP_P0 ];
sy_lfr_s2_bp_p1 = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_S2_BP_P1 ];
aux = ( (float ) sy_lfr_s2_bp_p1 / sy_lfr_s2_bp_p0 ) - floor(sy_lfr_s2_bp_p1 / sy_lfr_s2_bp_p0);
paul
Many corrections done after Logiscope analysis
r166 if (aux > FLOAT_EQUAL_ZERO)
paul
Sync...
r117 {
paul
Many corrections, mainly related to #807 Don_Enumeration
r318 status = send_tm_lfr_tc_exe_inconsistent( TC, queue_id, DATAFIELD_POS_SY_LFR_S2_BP_P0 + DATAFIELD_OFFSET, sy_lfr_s2_bp_p0 );
paul
Sync...
r117 flag = LFR_DEFAULT;
}
paul
Header files inclusion reworked...
r40 }
paul
Bug #167...
r152 // SET THE PARAMETERS
paul
Sync...
r117 if (flag == LFR_SUCCESSFUL)
{
paul
Bug #176
r159 flag = set_sy_lfr_s2_bp_p0( TC );
flag = set_sy_lfr_s2_bp_p1( TC );
paul
Sync...
r117 }
return flag;
paul
Header files inclusion reworked...
r40 }
paul
R3 updates. TC handlers added for the new telecommands:...
r192 int action_load_kcoefficients(ccsdsTelecommandPacket_t *TC, rtems_id queue_id, unsigned char *time)
{
/** This function updates the LFR registers with the incoming sbm2 parameters.
*
* @param TC points to the TeleCommand packet that is being processed
* @param queue_id is the id of the queue which handles TM related to this execution step
*
*/
int flag;
flag = LFR_DEFAULT;
paul
#426 corrected, sy_lfr_kcoeff_frequency >= 36 triggers the transmission of...
r211 flag = set_sy_lfr_kcoeff( TC, queue_id );
paul
R3 updates. TC handlers added for the new telecommands:...
r192
return flag;
}
int action_load_fbins_mask(ccsdsTelecommandPacket_t *TC, rtems_id queue_id, unsigned char *time)
{
/** This function updates the LFR registers with the incoming sbm2 parameters.
*
* @param TC points to the TeleCommand packet that is being processed
* @param queue_id is the id of the queue which handles TM related to this execution step
*
*/
int flag;
flag = LFR_DEFAULT;
paul
R2 parameter added to TC_LFR_LOAD_COMMON_PAR...
r195 flag = set_sy_lfr_fbins( TC );
paul
R3 updates. TC handlers added for the new telecommands:...
r192
paul
Bug #649 corrected, TC with Length > 228 are dropped by the driver, not parsed
r316 // once the fbins masks have been stored, they have to be merged with the masks which handle the reaction wheels frequencies filtering
merge_fbins_masks();
paul
R3 updates. TC handlers added for the new telecommands:...
r192 return flag;
}
paul
ICD 4.1 taken into account
r283 int action_load_filter_par(ccsdsTelecommandPacket_t *TC, rtems_id queue_id, unsigned char *time)
paul
TC_LFR_LOAD_PAS_FILTER_PAR added to the authorized telecommands...
r282 {
/** This function updates the LFR registers with the incoming sbm2 parameters.
*
* @param TC points to the TeleCommand packet that is being processed
* @param queue_id is the id of the queue which handles TM related to this execution step
*
*/
int flag;
paul
compliance with ICD 4.3...
r328 unsigned char k;
paul
TC_LFR_LOAD_PAS_FILTER_PAR added to the authorized telecommands...
r282
flag = LFR_DEFAULT;
paul
compliance with ICD 4.3...
r328 k = INIT_CHAR;
paul
TC_LFR_LOAD_PAS_FILTER_PAR added to the authorized telecommands...
r282
paul
minor updates
r285 flag = check_sy_lfr_filter_parameters( TC, queue_id );
paul
TC_LFR_LOAD_PAS_FILTER_PAR added to the authorized telecommands...
r282
if (flag == LFR_SUCCESSFUL)
{
paul
ICD 4.1 taken into account
r283 parameter_dump_packet.spare_sy_lfr_pas_filter_enabled = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_PAS_FILTER_ENABLED ];
parameter_dump_packet.sy_lfr_pas_filter_modulus = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_PAS_FILTER_MODULUS ];
paul
Many corrections, mainly related to #807 Don_Enumeration
r318 parameter_dump_packet.sy_lfr_pas_filter_tbad[BYTE_0] = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_PAS_FILTER_TBAD + BYTE_0 ];
parameter_dump_packet.sy_lfr_pas_filter_tbad[BYTE_1] = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_PAS_FILTER_TBAD + BYTE_1 ];
parameter_dump_packet.sy_lfr_pas_filter_tbad[BYTE_2] = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_PAS_FILTER_TBAD + BYTE_2 ];
parameter_dump_packet.sy_lfr_pas_filter_tbad[BYTE_3] = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_PAS_FILTER_TBAD + BYTE_3 ];
paul
ICD 4.1 taken into account
r283 parameter_dump_packet.sy_lfr_pas_filter_offset = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_PAS_FILTER_OFFSET ];
paul
Many corrections, mainly related to #807 Don_Enumeration
r318 parameter_dump_packet.sy_lfr_pas_filter_shift[BYTE_0] = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_PAS_FILTER_SHIFT + BYTE_0 ];
parameter_dump_packet.sy_lfr_pas_filter_shift[BYTE_1] = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_PAS_FILTER_SHIFT + BYTE_1 ];
parameter_dump_packet.sy_lfr_pas_filter_shift[BYTE_2] = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_PAS_FILTER_SHIFT + BYTE_2 ];
parameter_dump_packet.sy_lfr_pas_filter_shift[BYTE_3] = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_PAS_FILTER_SHIFT + BYTE_3 ];
parameter_dump_packet.sy_lfr_sc_rw_delta_f[BYTE_0] = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_SC_RW_DELTA_F + BYTE_0 ];
parameter_dump_packet.sy_lfr_sc_rw_delta_f[BYTE_1] = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_SC_RW_DELTA_F + BYTE_1 ];
parameter_dump_packet.sy_lfr_sc_rw_delta_f[BYTE_2] = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_SC_RW_DELTA_F + BYTE_2 ];
parameter_dump_packet.sy_lfr_sc_rw_delta_f[BYTE_3] = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_SC_RW_DELTA_F + BYTE_3 ];
paul
reaction wheels filtering implemented
r286
paul
3.1.0.2...
r293 //****************************
// store PAS filter parameters
paul
modulus, tbad, offset, shift are stored in finetime (uint64_t)...
r355
paul
3.1.0.2...
r293 // sy_lfr_pas_filter_enabled
filterPar.spare_sy_lfr_pas_filter_enabled = parameter_dump_packet.spare_sy_lfr_pas_filter_enabled;
paul
Many corrections, mainly related to #807 Don_Enumeration
r318 set_sy_lfr_pas_filter_enabled( parameter_dump_packet.spare_sy_lfr_pas_filter_enabled & BIT_PAS_FILTER_ENABLED );
paul
modulus, tbad, offset, shift are stored in finetime (uint64_t)...
r355
paul
3.1.0.2...
r293 // sy_lfr_pas_filter_modulus
paul
modulus, tbad, offset, shift are stored in finetime (uint64_t)...
r355 filterPar.modulus_in_finetime = ((uint64_t) parameter_dump_packet.sy_lfr_pas_filter_modulus) * CONST_65536;
paul
3.1.0.2...
r293 // sy_lfr_pas_filter_tbad
copyFloatByChar( (unsigned char*) &filterPar.sy_lfr_pas_filter_tbad,
parameter_dump_packet.sy_lfr_pas_filter_tbad );
paul
modulus, tbad, offset, shift are stored in finetime (uint64_t)...
r355 filterPar.tbad_in_finetime = (uint64_t) (filterPar.sy_lfr_pas_filter_tbad * CONST_65536);
paul
3.1.0.2...
r293 // sy_lfr_pas_filter_offset
paul
modulus, tbad, offset, shift are stored in finetime (uint64_t)...
r355 filterPar.offset_in_finetime = ((uint64_t) parameter_dump_packet.sy_lfr_pas_filter_offset) * CONST_65536;
paul
3.1.0.2...
r293 // sy_lfr_pas_filter_shift
copyFloatByChar( (unsigned char*) &filterPar.sy_lfr_pas_filter_shift,
parameter_dump_packet.sy_lfr_pas_filter_shift );
paul
modulus, tbad, offset, shift are stored in finetime (uint64_t)...
r355 filterPar.shift_in_finetime = (uint64_t) (filterPar.sy_lfr_pas_filter_shift * CONST_65536);
paul
3.1.0.2...
r293
//****************************************************
paul
reaction wheels filtering implemented
r286 // store the parameter sy_lfr_sc_rw_delta_f as a float
paul
3.1.0.2...
r293 copyFloatByChar( (unsigned char*) &filterPar.sy_lfr_sc_rw_delta_f,
parameter_dump_packet.sy_lfr_sc_rw_delta_f );
paul
compliance with ICD 4.3...
r328
// copy rw.._k.. from the incoming TC to the local parameter_dump_packet
for (k = 0; k < NB_RW_K_COEFFS * NB_BYTES_PER_RW_K_COEFF; k++)
{
parameter_dump_packet.sy_lfr_rw1_k1[k] = TC->dataAndCRC[ DATAFIELD_POS_SY_LFR_RW1_K1 + k ];
}
//***********************************************
// store the parameter sy_lfr_rw.._k.. as a float
// rw1_k
copyFloatByChar( (unsigned char*) &filterPar.sy_lfr_rw1_k1, parameter_dump_packet.sy_lfr_rw1_k1 );
copyFloatByChar( (unsigned char*) &filterPar.sy_lfr_rw1_k2, parameter_dump_packet.sy_lfr_rw1_k2 );
copyFloatByChar( (unsigned char*) &filterPar.sy_lfr_rw1_k3, parameter_dump_packet.sy_lfr_rw1_k3 );
copyFloatByChar( (unsigned char*) &filterPar.sy_lfr_rw1_k4, parameter_dump_packet.sy_lfr_rw1_k4 );
// rw2_k
copyFloatByChar( (unsigned char*) &filterPar.sy_lfr_rw2_k1, parameter_dump_packet.sy_lfr_rw2_k1 );
copyFloatByChar( (unsigned char*) &filterPar.sy_lfr_rw2_k2, parameter_dump_packet.sy_lfr_rw2_k2 );
copyFloatByChar( (unsigned char*) &filterPar.sy_lfr_rw2_k3, parameter_dump_packet.sy_lfr_rw2_k3 );
copyFloatByChar( (unsigned char*) &filterPar.sy_lfr_rw2_k4, parameter_dump_packet.sy_lfr_rw2_k4 );
// rw3_k
copyFloatByChar( (unsigned char*) &filterPar.sy_lfr_rw3_k1, parameter_dump_packet.sy_lfr_rw3_k1 );
copyFloatByChar( (unsigned char*) &filterPar.sy_lfr_rw3_k2, parameter_dump_packet.sy_lfr_rw3_k2 );
copyFloatByChar( (unsigned char*) &filterPar.sy_lfr_rw3_k3, parameter_dump_packet.sy_lfr_rw3_k3 );
copyFloatByChar( (unsigned char*) &filterPar.sy_lfr_rw3_k4, parameter_dump_packet.sy_lfr_rw3_k4 );
// rw4_k
copyFloatByChar( (unsigned char*) &filterPar.sy_lfr_rw4_k1, parameter_dump_packet.sy_lfr_rw4_k1 );
copyFloatByChar( (unsigned char*) &filterPar.sy_lfr_rw4_k2, parameter_dump_packet.sy_lfr_rw4_k2 );
copyFloatByChar( (unsigned char*) &filterPar.sy_lfr_rw4_k3, parameter_dump_packet.sy_lfr_rw4_k3 );
copyFloatByChar( (unsigned char*) &filterPar.sy_lfr_rw4_k4, parameter_dump_packet.sy_lfr_rw4_k4 );
paul
TC_LFR_LOAD_PAS_FILTER_PAR added to the authorized telecommands...
r282 }
return flag;
}
paul
R3 updates. TC handlers added for the new telecommands:...
r192 int action_dump_kcoefficients(ccsdsTelecommandPacket_t *TC, rtems_id queue_id, unsigned char *time)
{
/** This function updates the LFR registers with the incoming sbm2 parameters.
*
* @param TC points to the TeleCommand packet that is being processed
* @param queue_id is the id of the queue which handles TM related to this execution step
*
*/
paul
TC_LFR_LOAD_KCOEFFICIENTS...
r194 unsigned int address;
rtems_status_code status;
unsigned int freq;
unsigned int bin;
unsigned int coeff;
unsigned char *kCoeffPtr;
unsigned char *kCoeffDumpPtr;
paul
R3 updates. TC handlers added for the new telecommands:...
r192
paul
TC_LFR_LOAD_KCOEFFICIENTS...
r194 // for each sy_lfr_kcoeff_frequency there is 32 kcoeff
// F0 => 11 bins
// F1 => 13 bins
// F2 => 12 bins
// 36 bins to dump in two packets (30 bins max per packet)
paul
R3 updates. TC handlers added for the new telecommands:...
r192
paul
TC_LFR_LOAD_KCOEFFICIENTS...
r194 //*********
// PACKET 1
// 11 F0 bins, 13 F1 bins and 6 F2 bins
paul
bug #508 corrected (destination_id of TM_LFR_KCOEFFICIENTS_DUMP)
r221 kcoefficients_dump_1.destinationID = TC->sourceID;
paul
printf removed or replaced by PRINTF macros...
r227 increment_seq_counter_destination_id_dump( kcoefficients_dump_1.packetSequenceControl, TC->sourceID );
paul
Many corrections, mainly related to #807 Don_Enumeration
r318 for( freq = 0;
freq < NB_BINS_COMPRESSED_SM_F0;
paul
TC_LFR_LOAD_KCOEFFICIENTS...
r194 freq++ )
{
paul
Many corrections, mainly related to #807 Don_Enumeration
r318 kcoefficients_dump_1.kcoeff_blks[ (freq*KCOEFF_BLK_SIZE) + 1] = freq;
paul
TC_LFR_LOAD_KCOEFFICIENTS...
r194 bin = freq;
for ( coeff=0; coeff<NB_K_COEFF_PER_BIN; coeff++ )
{
paul
Many corrections, mainly related to #807 Don_Enumeration
r318 kCoeffDumpPtr = (unsigned char*) &kcoefficients_dump_1.kcoeff_blks[
(freq*KCOEFF_BLK_SIZE) + (coeff*NB_BYTES_PER_FLOAT) + KCOEFF_FREQ
]; // 2 for the kcoeff_frequency
paul
TC_LFR_LOAD_KCOEFFICIENTS...
r194 kCoeffPtr = (unsigned char*) &k_coeff_intercalib_f0_norm[ (bin*NB_K_COEFF_PER_BIN) + coeff ];
paul
R2 parameter added to TC_LFR_LOAD_COMMON_PAR...