@@ -12,7 +12,7 SWVERSION=-1-0 | |||||
12 | DEFINES += SW_VERSION_N1=3 # major |
|
12 | DEFINES += SW_VERSION_N1=3 # major | |
13 | DEFINES += SW_VERSION_N2=0 # minor |
|
13 | DEFINES += SW_VERSION_N2=0 # minor | |
14 | DEFINES += SW_VERSION_N3=0 # patch |
|
14 | DEFINES += SW_VERSION_N3=0 # patch | |
15 |
DEFINES += SW_VERSION_N4= |
|
15 | DEFINES += SW_VERSION_N4=3 # internal | |
16 |
|
16 | |||
17 | # <GCOV> |
|
17 | # <GCOV> | |
18 | #QMAKE_CFLAGS_RELEASE += -fprofile-arcs -ftest-coverage |
|
18 | #QMAKE_CFLAGS_RELEASE += -fprofile-arcs -ftest-coverage |
@@ -57,7 +57,7 typedef struct { | |||||
57 | volatile unsigned int calData; |
|
57 | volatile unsigned int calData; | |
58 | } time_management_regs_t; |
|
58 | } time_management_regs_t; | |
59 |
|
59 | |||
60 | // PDB >= 0.1.28 |
|
60 | // PDB >= 0.1.28, 0x80000f54 | |
61 | typedef struct{ |
|
61 | typedef struct{ | |
62 | int data_shaping; // 0x00 00 *** R1 R0 SP1 SP0 BW |
|
62 | int data_shaping; // 0x00 00 *** R1 R0 SP1 SP0 BW | |
63 | int run_burst_enable; // 0x04 01 *** [run *** burst f2, f1, f0 *** enable f3, f2, f1, f0 ] |
|
63 | int run_burst_enable; // 0x04 01 *** [run *** burst f2, f1, f0 *** enable f3, f2, f1, f0 ] | |
@@ -94,7 +94,7 typedef struct{ | |||||
94 | volatile unsigned int f2_1_coarse_time; // 0x74 |
|
94 | volatile unsigned int f2_1_coarse_time; // 0x74 | |
95 | volatile unsigned int f2_1_fine_time; // 0x78 |
|
95 | volatile unsigned int f2_1_fine_time; // 0x78 | |
96 | // |
|
96 | // | |
97 | volatile unsigned int f3_0_coarse_time; // 0x7c |
|
97 | volatile unsigned int f3_0_coarse_time; // 0x7c => 0x7c + 0xf54 = 0xd0 | |
98 | volatile unsigned int f3_0_fine_time; // 0x80 |
|
98 | volatile unsigned int f3_0_fine_time; // 0x80 | |
99 | volatile unsigned int f3_1_coarse_time; // 0x84 |
|
99 | volatile unsigned int f3_1_coarse_time; // 0x84 | |
100 | volatile unsigned int f3_1_fine_time; // 0x88 |
|
100 | volatile unsigned int f3_1_fine_time; // 0x88 |
@@ -55,8 +55,8 void setCalibrationData( void ); | |||||
55 | void setCalibrationReload( bool state); |
|
55 | void setCalibrationReload( bool state); | |
56 | void setCalibrationEnable( bool state ); |
|
56 | void setCalibrationEnable( bool state ); | |
57 | void setCalibrationInterleaved( bool state ); |
|
57 | void setCalibrationInterleaved( bool state ); | |
58 |
void s |
|
58 | void setCalibration( bool state ); | |
59 | void stopCalibration( void ); |
|
59 | void set_hk_lfr_calib_enable( bool state ); | |
60 | void configureCalibration( bool interleaved ); |
|
60 | void configureCalibration( bool interleaved ); | |
61 | // |
|
61 | // | |
62 | void update_last_TC_exe( ccsdsTelecommandPacket_t *TC , unsigned char *time ); |
|
62 | void update_last_TC_exe( ccsdsTelecommandPacket_t *TC , unsigned char *time ); |
@@ -272,7 +272,7 int action_enable_calibration(ccsdsTelec | |||||
272 |
|
272 | |||
273 | result = LFR_DEFAULT; |
|
273 | result = LFR_DEFAULT; | |
274 |
|
274 | |||
275 |
s |
|
275 | setCalibration( true ); | |
276 |
|
276 | |||
277 | result = LFR_SUCCESSFUL; |
|
277 | result = LFR_SUCCESSFUL; | |
278 |
|
278 | |||
@@ -292,7 +292,7 int action_disable_calibration(ccsdsTele | |||||
292 |
|
292 | |||
293 | result = LFR_DEFAULT; |
|
293 | result = LFR_DEFAULT; | |
294 |
|
294 | |||
295 |
st |
|
295 | setCalibration( false ); | |
296 |
|
296 | |||
297 | result = LFR_SUCCESSFUL; |
|
297 | result = LFR_SUCCESSFUL; | |
298 |
|
298 | |||
@@ -981,21 +981,37 void setCalibrationInterleaved( bool sta | |||||
981 | } |
|
981 | } | |
982 | } |
|
982 | } | |
983 |
|
983 | |||
984 |
void s |
|
984 | void setCalibration( bool state ) | |
|
985 | { | |||
|
986 | if (state == true) | |||
985 | { |
|
987 | { | |
986 | setCalibrationEnable( true ); |
|
988 | setCalibrationEnable( true ); | |
987 | setCalibrationReload( false ); |
|
989 | setCalibrationReload( false ); | |
|
990 | set_hk_lfr_calib_enable( true ); | |||
988 | } |
|
991 | } | |
989 |
|
992 | else | ||
990 | void stopCalibration( void ) |
|
|||
991 | { |
|
993 | { | |
992 | setCalibrationEnable( false ); |
|
994 | setCalibrationEnable( false ); | |
993 | setCalibrationReload( true ); |
|
995 | setCalibrationReload( true ); | |
|
996 | set_hk_lfr_calib_enable( false ); | |||
|
997 | } | |||
|
998 | } | |||
|
999 | ||||
|
1000 | void set_hk_lfr_calib_enable( bool state ) | |||
|
1001 | { | |||
|
1002 | if (state == true) | |||
|
1003 | { | |||
|
1004 | housekeeping_packet.lfr_status_word[1] = housekeeping_packet.lfr_status_word[1] | 0x08; // [0000 1000] | |||
|
1005 | } | |||
|
1006 | else | |||
|
1007 | { | |||
|
1008 | housekeeping_packet.lfr_status_word[1] = housekeeping_packet.lfr_status_word[1] & 0xf7; // [1111 0111] | |||
|
1009 | } | |||
994 | } |
|
1010 | } | |
995 |
|
1011 | |||
996 | void configureCalibration( bool interleaved ) |
|
1012 | void configureCalibration( bool interleaved ) | |
997 | { |
|
1013 | { | |
998 |
st |
|
1014 | setCalibration( false ); | |
999 | if ( interleaved == true ) |
|
1015 | if ( interleaved == true ) | |
1000 | { |
|
1016 | { | |
1001 | setCalibrationInterleaved( true ); |
|
1017 | setCalibrationInterleaved( true ); |
General Comments 0
You need to be logged in to leave comments.
Login now