##// END OF EJS Templates
Sync...
Sync Beginning of the BP packets emission implementation NORMAL and SBM1 packets are emitted together when in SBM1

File last commit:

r116:4710a866a7d2 VHDLib206
r116:4710a866a7d2 VHDLib206
Show More
fsw_processing.c
824 lines | 31.4 KiB | text/x-c | CLexer
/ src / fsw_processing.c
paul
Minor changes in .h inclusion
r45 /** Functions related to data processing.
*
* @file
* @author P. LEROY
*
* These function are related to data processing, i.e. spectral matrices averaging and basic parameters computation.
*
*/
paul@pc-solar1.lab-lpp.local
Updates of the ICD taken into account...
r18 #include <fsw_processing.h>
paul@pc-solar1.lab-lpp.local
Minor updates to use the time management VHDL module
r12
paul
Minor changes in .h inclusion
r45 #include "fsw_processing_globals.c"
paul@pc-solar1.lab-lpp.local
automatic reconnexion of the spacewire link...
r17
paul
Minor changes
r93 //************************
// spectral matrices rings
paul
Sync
r115 ring_node_sm sm_ring_f0[ NB_RING_NODES_ASM_F0 ];
ring_node_sm sm_ring_f1[ NB_RING_NODES_ASM_F1 ];
ring_node_sm sm_ring_f2[ NB_RING_NODES_ASM_F2 ];
paul
sync
r113 ring_node_sm *current_ring_node_sm_f0;
ring_node_sm *ring_node_for_averaging_sm_f0;
ring_node_sm *current_ring_node_sm_f1;
ring_node_sm *current_ring_node_sm_f2;
paul
Minor changes
r93
paul
Sync
r115 //**********************
// basic parameter rings
ring_node_bp *current_node_sbm1_bp1_f0;
paul
Sync...
r116 ring_node_bp *current_node_sbm1_bp2_f0;
ring_node_bp bp_ring_sbm1_bp1[ NB_RING_NODES_SBM1_BP1 ];
ring_node_bp bp_ring_sbm1_bp2[ NB_RING_NODES_SBM1_BP2 ];
paul
sync
r113
//*****
// NORM
// F0
paul
Sync...
r116 float asm_norm_f0 [ TIME_OFFSET + TOTAL_SIZE_SM ];
float asm_f0_reorganized [ TIME_OFFSET + TOTAL_SIZE_SM ];
char asm_f0_char [ TIME_OFFSET_IN_BYTES + (TOTAL_SIZE_SM * 2) ];
float compressed_sm_norm_f0[ TIME_OFFSET + TOTAL_SIZE_COMPRESSED_ASM_F0 ];
paul
Minor changes
r93
paul
sync
r113 //*****
// SBM1
paul
Sync...
r116 float asm_sbm1_f0 [ TIME_OFFSET + TOTAL_SIZE_SM ];
float compressed_sm_sbm1[ TIME_OFFSET + TOTAL_SIZE_COMPRESSED_ASM_SBM1 ];
paul
sync
r113
paul
Sync
r115 unsigned char LFR_BP1_F0[ TIME_OFFSET_IN_BYTES + TOTAL_SIZE_NORM_BP1_F0 * 2 ];
unsigned char LFR_BP1_F1[ TIME_OFFSET_IN_BYTES + TOTAL_SIZE_NORM_BP1_F1 ];
unsigned char LFR_BP1_F2[ TIME_OFFSET_IN_BYTES + TOTAL_SIZE_NORM_BP1_F2 ];
paul
Corrections:...
r107
paul
Sync
r99 unsigned int nb_sm_f0;
paul
Sync
r95 void init_sm_rings( void )
paul
Minor changes
r93 {
unsigned char i;
// F0 RING
paul
sync
r113 sm_ring_f0[0].next = (ring_node_sm*) &sm_ring_f0[1];
sm_ring_f0[0].previous = (ring_node_sm*) &sm_ring_f0[NB_RING_NODES_ASM_F0-1];
paul
snapshots extraction fully functionnal in SBM1 and SBM2
r106 sm_ring_f0[0].buffer_address =
(int) &sm_f0[ 0 ];
paul
Minor changes
r93
paul
sync
r113 sm_ring_f0[NB_RING_NODES_ASM_F0-1].next = (ring_node_sm*) &sm_ring_f0[0];
sm_ring_f0[NB_RING_NODES_ASM_F0-1].previous = (ring_node_sm*) &sm_ring_f0[NB_RING_NODES_ASM_F0-2];
paul
snapshots extraction fully functionnal in SBM1 and SBM2
r106 sm_ring_f0[NB_RING_NODES_ASM_F0-1].buffer_address =
(int) &sm_f0[ (NB_RING_NODES_ASM_F0-1) * TOTAL_SIZE_SM ];
paul
Minor changes
r93
for(i=1; i<NB_RING_NODES_ASM_F0-1; i++)
{
paul
sync
r113 sm_ring_f0[i].next = (ring_node_sm*) &sm_ring_f0[i+1];
sm_ring_f0[i].previous = (ring_node_sm*) &sm_ring_f0[i-1];
paul
snapshots extraction fully functionnal in SBM1 and SBM2
r106 sm_ring_f0[i].buffer_address =
(int) &sm_f0[ i * TOTAL_SIZE_SM ];
}
// F1 RING
paul
sync
r113 sm_ring_f1[0].next = (ring_node_sm*) &sm_ring_f1[1];
sm_ring_f1[0].previous = (ring_node_sm*) &sm_ring_f1[NB_RING_NODES_ASM_F1-1];
paul
snapshots extraction fully functionnal in SBM1 and SBM2
r106 sm_ring_f1[0].buffer_address =
(int) &sm_f1[ 0 ];
paul
sync
r113 sm_ring_f1[NB_RING_NODES_ASM_F1-1].next = (ring_node_sm*) &sm_ring_f1[0];
sm_ring_f1[NB_RING_NODES_ASM_F1-1].previous = (ring_node_sm*) &sm_ring_f1[NB_RING_NODES_ASM_F1-2];
paul
snapshots extraction fully functionnal in SBM1 and SBM2
r106 sm_ring_f1[NB_RING_NODES_ASM_F1-1].buffer_address =
(int) &sm_f1[ (NB_RING_NODES_ASM_F1-1) * TOTAL_SIZE_SM ];
for(i=1; i<NB_RING_NODES_ASM_F1-1; i++)
{
paul
sync
r113 sm_ring_f1[i].next = (ring_node_sm*) &sm_ring_f1[i+1];
sm_ring_f1[i].previous = (ring_node_sm*) &sm_ring_f1[i-1];
paul
snapshots extraction fully functionnal in SBM1 and SBM2
r106 sm_ring_f1[i].buffer_address =
(int) &sm_f1[ i * TOTAL_SIZE_SM ];
}
// F2 RING
paul
sync
r113 sm_ring_f2[0].next = (ring_node_sm*) &sm_ring_f2[1];
sm_ring_f2[0].previous = (ring_node_sm*) &sm_ring_f2[NB_RING_NODES_ASM_F2-1];
paul
snapshots extraction fully functionnal in SBM1 and SBM2
r106 sm_ring_f2[0].buffer_address =
(int) &sm_f2[ 0 ];
paul
sync
r113 sm_ring_f2[NB_RING_NODES_ASM_F2-1].next = (ring_node_sm*) &sm_ring_f2[0];
sm_ring_f2[NB_RING_NODES_ASM_F2-1].previous = (ring_node_sm*) &sm_ring_f2[NB_RING_NODES_ASM_F2-2];
paul
snapshots extraction fully functionnal in SBM1 and SBM2
r106 sm_ring_f2[NB_RING_NODES_ASM_F2-1].buffer_address =
(int) &sm_f2[ (NB_RING_NODES_ASM_F2-1) * TOTAL_SIZE_SM ];
for(i=1; i<NB_RING_NODES_ASM_F2-1; i++)
{
paul
sync
r113 sm_ring_f2[i].next = (ring_node_sm*) &sm_ring_f2[i+1];
sm_ring_f2[i].previous = (ring_node_sm*) &sm_ring_f2[i-1];
paul
snapshots extraction fully functionnal in SBM1 and SBM2
r106 sm_ring_f2[i].buffer_address =
(int) &sm_f2[ i * TOTAL_SIZE_SM ];
paul
Minor changes
r93 }
DEBUG_PRINTF1("asm_ring_f0 @%x\n", (unsigned int) sm_ring_f0)
paul
snapshots extraction fully functionnal in SBM1 and SBM2
r106 DEBUG_PRINTF1("asm_ring_f1 @%x\n", (unsigned int) sm_ring_f1)
DEBUG_PRINTF1("asm_ring_f2 @%x\n", (unsigned int) sm_ring_f2)
paul
Minor changes
r93
paul
Sync
r99 spectral_matrix_regs->matrixF0_Address0 = sm_ring_f0[0].buffer_address;
DEBUG_PRINTF1("spectral_matrix_regs->matrixF0_Address0 @%x\n", spectral_matrix_regs->matrixF0_Address0)
paul
Minor changes
r93 }
void reset_current_sm_ring_nodes( void )
{
paul
snapshots extraction fully functionnal in SBM1 and SBM2
r106 current_ring_node_sm_f0 = sm_ring_f0;
current_ring_node_sm_f1 = sm_ring_f1;
current_ring_node_sm_f2 = sm_ring_f2;
paul
Sync
r95 ring_node_for_averaging_sm_f0 = sm_ring_f0;
paul
Minor changes
r93 }
paul
SID corrected in TM_LFR_TC_EXE packets...
r31
paul
Sync...
r116 void reset_current_bp_ring_nodes( void )
paul
Sync
r115 {
paul
Sync...
r116 current_node_sbm1_bp1_f0 = bp_ring_sbm1_bp1;
current_node_sbm1_bp2_f0 = bp_ring_sbm1_bp2;
paul
Sync
r115 }
paul@pc-solar1.lab-lpp.local
All modes implemented for the waveforms...
r23 //***********************************************************
// Interrupt Service Routine for spectral matrices processing
paul
Sync
r99 void reset_nb_sm_f0( void )
{
nb_sm_f0 = 0;
}
paul@pc-solar1.lab-lpp.local
All modes implemented for the waveforms...
r23 rtems_isr spectral_matrices_isr( rtems_vector_number vector )
{
paul
the function asm_reorganize format the spectral matrix to the ICD format
r103 rtems_event_send( Task_id[TASKID_DUMB], RTEMS_EVENT_8 );
if ( (spectral_matrix_regs->status & 0x1) == 0x01)
{
current_ring_node_sm_f0 = current_ring_node_sm_f0->next;
spectral_matrix_regs->matrixF0_Address0 = current_ring_node_sm_f0->buffer_address;
spectral_matrix_regs->status = spectral_matrix_regs->status & 0xfffffffe; // 1110
nb_sm_f0 = nb_sm_f0 + 1;
}
else if ( (spectral_matrix_regs->status & 0x2) == 0x02)
{
current_ring_node_sm_f0 = current_ring_node_sm_f0->next;
spectral_matrix_regs->matrixFO_Address1 = current_ring_node_sm_f0->buffer_address;
spectral_matrix_regs->status = spectral_matrix_regs->status & 0xfffffffd; // 1101
nb_sm_f0 = nb_sm_f0 + 1;
}
paul
sy_lfr_n_swf_p implemented...
r32
paul
the function asm_reorganize format the spectral matrix to the ICD format
r103 if ( (spectral_matrix_regs->status & 0x30) != 0x00)
{
rtems_event_send( Task_id[TASKID_DUMB], RTEMS_EVENT_8 );
spectral_matrix_regs->status = spectral_matrix_regs->status & 0xffffffcf; // 1100 1111
}
spectral_matrix_regs->status = spectral_matrix_regs->status & 0xfffffff3; // 0011
paul
sy_lfr_n_swf_p implemented...
r32
paul
Sync...
r116 if (nb_sm_f0 == (NB_SM_BEFORE_AVF0-1) )
paul
the function asm_reorganize format the spectral matrix to the ICD format
r103 {
ring_node_for_averaging_sm_f0 = current_ring_node_sm_f0;
if (rtems_event_send( Task_id[TASKID_AVF0], RTEMS_EVENT_0 ) != RTEMS_SUCCESSFUL)
{
rtems_event_send( Task_id[TASKID_DUMB], RTEMS_EVENT_3 );
}
nb_sm_f0 = 0;
}
else
{
nb_sm_f0 = nb_sm_f0 + 1;
}
paul@pc-solar1.lab-lpp.local
Naming convention changed...
r5 }
paul
Commit before working on the ERR 4 due to message queue...
r34 rtems_isr spectral_matrices_isr_simu( rtems_vector_number vector )
{
paul
Sync...
r116 if (nb_sm_f0 == (NB_SM_BEFORE_AVF0-1) )
paul
SM simulator functionnal...
r100 {
paul
the function asm_reorganize format the spectral matrix to the ICD format
r103 ring_node_for_averaging_sm_f0 = current_ring_node_sm_f0;
paul
SM simulator functionnal...
r100 if (rtems_event_send( Task_id[TASKID_AVF0], RTEMS_EVENT_0 ) != RTEMS_SUCCESSFUL)
{
rtems_event_send( Task_id[TASKID_DUMB], RTEMS_EVENT_3 );
}
nb_sm_f0 = 0;
}
else
{
nb_sm_f0 = nb_sm_f0 + 1;
}
paul
Commit before working on the ERR 4 due to message queue...
r34 }
paul@pc-solar1.lab-lpp.local
automatic reconnexion of the spacewire link...
r17 //************
// RTEMS TASKS
paul
Commit before working on the ERR 4 due to message queue...
r34
paul@pc-solar1.lab-lpp.local
Message queue implemented for valid TC processing...
r9 rtems_task smiq_task(rtems_task_argument argument) // process the Spectral Matrices IRQ
paul@pc-solar1.lab-lpp.local
All modes implemented for the waveforms...
r23 {
paul@pc-solar1.lab-lpp.local
Naming convention changed...
r5 rtems_event_set event_out;
paul@pc-solar1.lab-lpp.local
Several TC actions added...
r11
paul
Last commit before release 0-13...
r35 BOOT_PRINTF("in SMIQ *** \n")
paul@pc-solar1.lab-lpp.local
All modes implemented for the waveforms...
r23
while(1){
paul@pc-solar1.lab-lpp.local
Naming convention changed...
r5 rtems_event_receive(RTEMS_EVENT_0, RTEMS_WAIT, RTEMS_NO_TIMEOUT, &event_out); // wait for an RTEMS_EVENT0
}
}
paul@pc-solar1.lab-lpp.local
All modes implemented for the waveforms...
r23
paul
SID corrected in TM_LFR_TC_EXE packets...
r31 rtems_task avf0_task(rtems_task_argument argument)
{
paul
Commit before working on the ERR 4 due to message queue...
r34 int i;
paul
Sync...
r116 static unsigned int nb_sm_norm_bp1_f0;
static unsigned int nb_sm_norm_bp2_f0;
static unsigned int nb_sm_norm_asm_f0;
static unsigned int nb_sm_sbm1_bp1_f0;
static unsigned int nb_sm_sbm1_bp2_f0;
paul@pc-solar1.lab-lpp.local
All modes implemented for the waveforms...
r23 rtems_event_set event_out;
paul
Sync...
r116 rtems_event_set event_for_matr;
paul@pc-solar1.lab-lpp.local
automatic reconnexion of the spacewire link...
r17 rtems_status_code status;
paul
sync
r113 ring_node_sm *ring_node_tab[8];
paul@pc-solar1.lab-lpp.local
automatic reconnexion of the spacewire link...
r17
paul
Sync...
r116 nb_sm_norm_bp1_f0 = 0;
nb_sm_norm_bp2_f0 = 0;
nb_sm_norm_asm_f0 = 0;
nb_sm_sbm1_bp1_f0 = 0;
nb_sm_sbm1_bp2_f0 = 0;
paul@pc-solar1.lab-lpp.local
automatic reconnexion of the spacewire link...
r17
paul
Last commit before release 0-13...
r35 BOOT_PRINTF("in AVFO *** \n")
paul@pc-solar1.lab-lpp.local
All modes implemented for the waveforms...
r23
while(1){
rtems_event_receive(RTEMS_EVENT_0, RTEMS_WAIT, RTEMS_NO_TIMEOUT, &event_out); // wait for an RTEMS_EVENT0
paul
Sync...
r116 ring_node_tab[NB_SM_BEFORE_AVF0-1] = ring_node_for_averaging_sm_f0;
for ( i = 2; i < (NB_SM_BEFORE_AVF0+1); i++ )
paul
Sync
r95 {
ring_node_for_averaging_sm_f0 = ring_node_for_averaging_sm_f0->previous;
paul
Sync...
r116 ring_node_tab[NB_SM_BEFORE_AVF0-i] = ring_node_for_averaging_sm_f0;
paul
Sync
r95 }
paul
rev 1.0.0.2...
r104
paul
Sync
r115 // copy time information in the asm_f0 buffer
paul
Sync...
r116 asm_norm_f0[0] = ring_node_tab[7]->coarseTime;
asm_norm_f0[1] = ring_node_tab[7]->fineTime;
asm_sbm1_f0[0] = ring_node_tab[7]->coarseTime;
asm_sbm1_f0[1] = ring_node_tab[7]->fineTime;
paul
sync
r113
// compute the average and store it in the averaged_sm_f1 buffer
paul
Sync...
r116 SM_average( asm_norm_f0, asm_sbm1_f0,
paul
sync
r113 ring_node_tab,
paul
Sync...
r116 nb_sm_norm_bp1_f0, nb_sm_sbm1_bp1_f0 );
paul
sync
r113
// update nb_average
paul
Sync...
r116 nb_sm_norm_bp1_f0 = nb_sm_norm_bp1_f0 + NB_SM_BEFORE_AVF0;
nb_sm_norm_bp2_f0 = nb_sm_norm_bp2_f0 + NB_SM_BEFORE_AVF0;
nb_sm_norm_asm_f0 = nb_sm_norm_asm_f0 + NB_SM_BEFORE_AVF0;
nb_sm_sbm1_bp1_f0 = nb_sm_sbm1_bp1_f0 + NB_SM_BEFORE_AVF0;
nb_sm_sbm1_bp2_f0 = nb_sm_sbm1_bp2_f0 + NB_SM_BEFORE_AVF0;
paul
sync
r113
paul
Sync...
r116 //***********************************************************
// build a composite event that will be sent to the MATR task
event_for_matr = 0x00;
paul
rev 1.0.0.5
r114
paul
Sync...
r116 if (nb_sm_sbm1_bp1_f0 == NB_SM_BEFORE_SBM1_BP1_F0)
paul
Sync
r99 {
paul
Sync...
r116 nb_sm_sbm1_bp1_f0 = 0;
paul
rev 1.0.0.5
r114 if (lfrCurrentMode == LFR_MODE_SBM1)
{
paul
Sync...
r116 event_for_matr = event_for_matr | RTEMS_EVENT_SBM1_BP1_F0;
paul
sync
r113 }
paul
Commit before working on the ERR 4 due to message queue...
r34 }
paul
rev 1.0.0.5
r114
paul
Sync...
r116 if (nb_sm_sbm1_bp2_f0 == NB_SM_BEFORE_SBM1_BP2_F0)
{
nb_sm_sbm1_bp2_f0 = 0;
if (lfrCurrentMode == LFR_MODE_SBM1)
{
event_for_matr = event_for_matr | RTEMS_EVENT_SBM1_BP2_F0;
}
}
if (nb_sm_norm_bp1_f0 == NB_SM_BEFORE_NORM_BP1_F0) {
nb_sm_norm_bp1_f0 = 0;
if (lfrCurrentMode == LFR_MODE_NORMAL)
{
event_for_matr = event_for_matr | RTEMS_EVENT_NORM_BP1_F0;
paul@pc-solar1.lab-lpp.local
All modes implemented for the waveforms...
r23 }
}
paul
Sync...
r116
if (nb_sm_norm_bp2_f0 == NB_SM_BEFORE_NORM_BP2_F0) {
nb_sm_norm_bp2_f0 = 0;
if (lfrCurrentMode == LFR_MODE_NORMAL)
{
event_for_matr = event_for_matr | RTEMS_EVENT_NORM_BP2_F0;
}
}
if (nb_sm_norm_asm_f0 == NB_SM_BEFORE_NORM_ASM_F0) {
nb_sm_norm_asm_f0 = 0;
if (lfrCurrentMode == LFR_MODE_NORMAL)
{
event_for_matr = event_for_matr | RTEMS_EVENT_NORM_ASM_F0;
}
}
//*********************************
// send the composite event to MATR
status = rtems_event_send( Task_id[TASKID_MATR], event_for_matr );
if (status != RTEMS_SUCCESSFUL) {
printf("in AVF0 *** Error sending RTEMS_EVENT_0, code %d\n", status);
}
paul@pc-solar1.lab-lpp.local
All modes implemented for the waveforms...
r23 }
}
paul
SID corrected in TM_LFR_TC_EXE packets...
r31 rtems_task matr_task(rtems_task_argument argument)
{
spw_ioctl_pkt_send spw_ioctl_send_ASM;
rtems_event_set event_out;
paul
Last commit before release 0-13...
r35 rtems_status_code status;
rtems_id queue_id;
paul
SID corrected in TM_LFR_TC_EXE packets...
r31 Header_TM_LFR_SCIENCE_ASM_t headerASM;
paul
Sync...
r116 ring_node_bp_with_spare current_node_norm_bp1_f0;
ring_node_bp current_node_norm_bp2_f0;
paul
SID corrected in TM_LFR_TC_EXE packets...
r31
init_header_asm( &headerASM );
paul
Sync...
r116 init_header_bp_with_spare( &current_node_norm_bp1_f0.header,
APID_TM_SCIENCE_NORMAL_BURST, SID_NORM_BP1_F0,
PACKET_LENGTH_TM_LFR_SCIENCE_NORM_BP1_F0, NB_BINS_COMPRESSED_SM_F0 );
init_header_bp( &current_node_norm_bp2_f0.header,
APID_TM_SCIENCE_NORMAL_BURST, SID_NORM_BP2_F0,
PACKET_LENGTH_TM_LFR_SCIENCE_NORM_BP2_F0, NB_BINS_COMPRESSED_SM_F0);
paul
SID corrected in TM_LFR_TC_EXE packets...
r31
paul
fsw-1-0...
r82 status = get_message_queue_id_send( &queue_id );
paul
Last commit before release 0-13...
r35 if (status != RTEMS_SUCCESSFUL)
{
paul
fsw-1-0...
r82 PRINTF1("in MATR *** ERR get_message_queue_id_send %d\n", status)
paul
Last commit before release 0-13...
r35 }
BOOT_PRINTF("in MATR *** \n")
paul
SID corrected in TM_LFR_TC_EXE packets...
r31
while(1){
paul
Sync...
r116 rtems_event_receive( RTEMS_EVENT_NORM_BP1_F0 | RTEMS_EVENT_NORM_BP2_F0 | RTEMS_EVENT_NORM_ASM_F0
| RTEMS_EVENT_SBM1_BP1_F0 | RTEMS_EVENT_SBM1_BP2_F0,
paul
sync
r113 RTEMS_WAIT | RTEMS_EVENT_ANY, RTEMS_NO_TIMEOUT, &event_out);
paul
Sync...
r116 //*****
//*****
// SBM1
//*****
//*****
if (event_out & RTEMS_EVENT_SBM1_BP1_F0)
paul
sync
r113 {
// 1) compress the matrix for Basic Parameters calculation
paul
Sync...
r116 ASM_compress_reorganize_and_divide( asm_sbm1_f0, compressed_sm_sbm1,
NB_SM_BEFORE_SBM1_BP1_F0,
NB_BINS_COMPRESSED_SM_SBM1_F0, NB_BINS_TO_AVERAGE_ASM_SBM1_F0,
ASM_F0_INDICE_START);
// 2) compute the BP1 set
// 3) send the BP1 set
set_time( current_node_sbm1_bp1_f0->header.time,
current_node_sbm1_bp1_f0->coarseTime, current_node_sbm1_bp1_f0->fineTime);
set_time( current_node_sbm1_bp1_f0->header.acquisitionTime,
current_node_sbm1_bp1_f0->coarseTime, current_node_sbm1_bp1_f0->fineTime);
BP_send( (char *) &current_node_sbm1_bp1_f0->header, queue_id,
PACKET_LENGTH_TM_LFR_SCIENCE_SBM1_BP1_F0 + PACKET_LENGTH_DELTA);
// 4) update current_node_sbm1_bp1_f0
current_node_sbm1_bp1_f0 = current_node_sbm1_bp1_f0->next;
if (event_out & RTEMS_EVENT_SBM1_BP2_F0)
{
// 1) compute the BP2 set
// 2) send the BP2 set
set_time( current_node_sbm1_bp2_f0->header.time,
current_node_sbm1_bp2_f0->coarseTime, current_node_sbm1_bp2_f0->fineTime);
set_time( current_node_sbm1_bp2_f0->header.acquisitionTime,
current_node_sbm1_bp2_f0->coarseTime, current_node_sbm1_bp2_f0->fineTime);
BP_send( (char *) &current_node_sbm1_bp2_f0->header, queue_id,
PACKET_LENGTH_TM_LFR_SCIENCE_SBM1_BP1_F0 + PACKET_LENGTH_DELTA);
}
}
//*****
//*****
// NORM
//*****
//*****
if (event_out & RTEMS_EVENT_NORM_BP1_F0)
{
// 1) compress the matrix for Basic Parameters calculation
ASM_compress_reorganize_and_divide( asm_norm_f0, compressed_sm_norm_f0,
NB_SM_BEFORE_NORM_BP1_F0,
paul
Sync
r115 NB_BINS_COMPRESSED_SM_F0, NB_BINS_TO_AVERAGE_ASM_F0,
ASM_F0_INDICE_START );
paul
sync
r113 // 2) compute the BP1 set
paul
rev 1.0.0.5
r114 // 3) send the BP1 set
paul
Sync...
r116 set_time( current_node_norm_bp1_f0.header.time,
current_node_norm_bp1_f0.coarseTime, current_node_norm_bp1_f0.fineTime);
set_time( current_node_norm_bp1_f0.header.acquisitionTime,
current_node_norm_bp1_f0.coarseTime, current_node_norm_bp1_f0.fineTime);
BP_send( (char *) &current_node_norm_bp1_f0.header, queue_id,
PACKET_LENGTH_TM_LFR_SCIENCE_NORM_BP1_F0 + PACKET_LENGTH_DELTA);
if (event_out & RTEMS_EVENT_NORM_BP2_F0)
{
// 1) compute the BP2 set
// 2) send the BP2 set
set_time( current_node_norm_bp2_f0.header.time,
current_node_norm_bp2_f0.coarseTime, current_node_norm_bp2_f0.fineTime);
set_time( current_node_norm_bp2_f0.header.acquisitionTime,
current_node_norm_bp2_f0.coarseTime, current_node_norm_bp2_f0.fineTime);
BP_send( (char *) &current_node_norm_bp2_f0.header, queue_id,
PACKET_LENGTH_TM_LFR_SCIENCE_NORM_BP2_F0 + PACKET_LENGTH_DELTA);
}
}
if (event_out & RTEMS_EVENT_NORM_ASM_F0)
{
// 1) reorganize the ASM and divide
ASM_reorganize_and_divide( asm_norm_f0, asm_f0_reorganized, NB_SM_BEFORE_NORM_BP1_F0 );
// 2) convert the float array in a char array
paul
Sync
r115 ASM_convert( asm_f0_reorganized, asm_f0_char);
paul
Sync...
r116 // 3) send the spectral matrix packets
paul
Sync
r115 ASM_send( &headerASM, asm_f0_char, SID_NORM_ASM_F0, &spw_ioctl_send_ASM, queue_id);
paul
sync
r113 }
paul
SID corrected in TM_LFR_TC_EXE packets...
r31 }
}
paul@pc-solar1.lab-lpp.local
automatic reconnexion of the spacewire link...
r17 //*****************************
paul@pc-solar1.lab-lpp.local
All modes implemented for the waveforms...
r23 // Spectral matrices processing
paul
Sync...
r116 void SM_average( float *averaged_spec_mat_f0, float *averaged_spec_mat_f1,
paul
sync
r113 ring_node_sm *ring_node_tab[],
paul
rev 1.0.0.5
r114 unsigned int nbAverageNormF0, unsigned int nbAverageSBM1F0 )
paul
sync
r113 {
float sum;
unsigned int i;
for(i=0; i<TOTAL_SIZE_SM; i++)
{
sum = ( (int *) (ring_node_tab[0]->buffer_address) ) [ i ]
+ ( (int *) (ring_node_tab[1]->buffer_address) ) [ i ]
+ ( (int *) (ring_node_tab[2]->buffer_address) ) [ i ]
+ ( (int *) (ring_node_tab[3]->buffer_address) ) [ i ]
+ ( (int *) (ring_node_tab[4]->buffer_address) ) [ i ]
+ ( (int *) (ring_node_tab[5]->buffer_address) ) [ i ]
+ ( (int *) (ring_node_tab[6]->buffer_address) ) [ i ]
+ ( (int *) (ring_node_tab[7]->buffer_address) ) [ i ];
paul
rev 1.0.0.5
r114 if ( (nbAverageNormF0 == 0) && (nbAverageSBM1F0 == 0) )
paul
sync
r113 {
paul
rev 1.0.0.5
r114 averaged_spec_mat_f0[ TIME_OFFSET + i ] = sum;
averaged_spec_mat_f1[ TIME_OFFSET + i ] = sum;
paul
sync
r113 }
paul
rev 1.0.0.5
r114 else if ( (nbAverageNormF0 != 0) && (nbAverageSBM1F0 != 0) )
paul
sync
r113 {
paul
rev 1.0.0.5
r114 averaged_spec_mat_f0[ TIME_OFFSET + i ] = ( averaged_spec_mat_f0[ TIME_OFFSET + i ] + sum );
averaged_spec_mat_f1[ TIME_OFFSET + i ] = ( averaged_spec_mat_f1[ TIME_OFFSET + i ] + sum );
paul
sync
r113 }
paul
rev 1.0.0.5
r114 else if ( (nbAverageNormF0 != 0) && (nbAverageSBM1F0 == 0) )
paul
sync
r113 {
paul
rev 1.0.0.5
r114 averaged_spec_mat_f0[ TIME_OFFSET + i ] = ( averaged_spec_mat_f0[ TIME_OFFSET + i ] + sum );
averaged_spec_mat_f1[ TIME_OFFSET + i ] = sum;
paul
sync
r113 }
else
{
paul
Sync...
r116 PRINTF2("ERR *** in SM_average *** unexpected parameters %d %d\n", nbAverageNormF0, nbAverageSBM1F0)
paul
sync
r113 }
}
}
paul
Sync
r115 void ASM_reorganize_and_divide( float *averaged_spec_mat, float *averaged_spec_mat_reorganized, float divider )
paul
the function asm_reorganize format the spectral matrix to the ICD format
r103 {
int frequencyBin;
int asmComponent;
// copy the time information
averaged_spec_mat_reorganized[ 0 ] = averaged_spec_mat[ 0 ];
averaged_spec_mat_reorganized[ 1 ] = averaged_spec_mat[ 1 ];
for (asmComponent = 0; asmComponent < NB_VALUES_PER_SM; asmComponent++)
{
for( frequencyBin = 0; frequencyBin < NB_BINS_PER_SM; frequencyBin++ )
{
paul
rev 1.0.0.5
r114 averaged_spec_mat_reorganized[ TIME_OFFSET + frequencyBin * NB_VALUES_PER_SM + asmComponent ] =
paul
Sync
r115 averaged_spec_mat[ TIME_OFFSET + asmComponent * NB_BINS_PER_SM + frequencyBin ] / divider;
paul
the function asm_reorganize format the spectral matrix to the ICD format
r103 }
}
}
paul
Sync
r115 void ASM_compress_reorganize_and_divide(float *averaged_spec_mat, float *compressed_spec_mat , float divider,
unsigned char nbBinsCompressedMatrix, unsigned char nbBinsToAverage, unsigned char ASMIndexStart )
paul@pc-solar1.lab-lpp.local
All modes implemented for the waveforms...
r23 {
paul
Bug #60 corrected...
r102 int frequencyBin;
int asmComponent;
int offsetASM;
int offsetCompressed;
int k;
paul
Sync
r115 for (asmComponent = 0; asmComponent < NB_VALUES_PER_SM; asmComponent++)
{
for( frequencyBin = 0; frequencyBin < nbBinsCompressedMatrix; frequencyBin++ )
paul
Bug #60 corrected...
r102 {
paul
Sync
r115 offsetCompressed = TIME_OFFSET
+ frequencyBin * NB_VALUES_PER_SM
+ asmComponent;
offsetASM = TIME_OFFSET
+ asmComponent * NB_BINS_PER_SM
+ ASMIndexStart
+ frequencyBin * nbBinsToAverage;
compressed_spec_mat[ offsetCompressed ] = 0;
for ( k = 0; k < nbBinsToAverage; k++ )
paul
Bug #60 corrected...
r102 {
paul
Sync
r115 compressed_spec_mat[offsetCompressed ] =
( compressed_spec_mat[ offsetCompressed ]
+ averaged_spec_mat[ offsetASM + k ] ) / (divider * nbBinsToAverage);
paul
Bug #60 corrected...
r102 }
}
}
}
paul
the function asm_reorganize format the spectral matrix to the ICD format
r103 void ASM_convert( volatile float *input_matrix, char *output_matrix)
paul
Bug #60 corrected...
r102 {
unsigned int i;
paul
the function asm_reorganize format the spectral matrix to the ICD format
r103 unsigned int frequencyBin;
unsigned int asmComponent;
paul
Bug #60 corrected...
r102 char * pt_char_input;
char * pt_char_output;
paul
the function asm_reorganize format the spectral matrix to the ICD format
r103 pt_char_input = (char*) &input_matrix;
pt_char_output = (char*) &output_matrix;
paul
Bug #60 corrected...
r102
paul
the function asm_reorganize format the spectral matrix to the ICD format
r103 // copy the time information
for (i=0; i<TIME_OFFSET_IN_BYTES; i++)
paul
Bug #60 corrected...
r102 {
paul
the function asm_reorganize format the spectral matrix to the ICD format
r103 pt_char_output[ i ] = pt_char_output[ i ];
}
// convert all other data
for( frequencyBin=0; frequencyBin<NB_BINS_PER_SM; frequencyBin++)
{
for ( asmComponent=0; asmComponent<NB_VALUES_PER_SM; asmComponent++)
paul
Bug #60 corrected...
r102 {
paul
the function asm_reorganize format the spectral matrix to the ICD format
r103 pt_char_input = (char*) &input_matrix [ (frequencyBin*NB_VALUES_PER_SM) + asmComponent + TIME_OFFSET ];
pt_char_output = (char*) &output_matrix[ 2 * ( (frequencyBin*NB_VALUES_PER_SM) + asmComponent ) + TIME_OFFSET_IN_BYTES ];
paul
Bug #60 corrected...
r102 pt_char_output[0] = pt_char_input[0]; // bits 31 downto 24 of the float
pt_char_output[1] = pt_char_input[1]; // bits 23 downto 16 of the float
}
}
}
paul
the function asm_reorganize format the spectral matrix to the ICD format
r103 void ASM_send(Header_TM_LFR_SCIENCE_ASM_t *header, char *spectral_matrix,
paul
Bug #60 corrected...
r102 unsigned int sid, spw_ioctl_pkt_send *spw_ioctl_send, rtems_id queue_id)
{
unsigned int i;
unsigned int length = 0;
rtems_status_code status;
for (i=0; i<2; i++)
{
// (1) BUILD THE DATA
switch(sid)
{
case SID_NORM_ASM_F0:
spw_ioctl_send->dlen = TOTAL_SIZE_ASM_F0_IN_BYTES / 2;
paul
the function asm_reorganize format the spectral matrix to the ICD format
r103 spw_ioctl_send->data = &spectral_matrix[
( (ASM_F0_INDICE_START + (i*NB_BINS_PER_PKT_ASM_F0) ) * NB_VALUES_PER_SM ) * 2
+ TIME_OFFSET_IN_BYTES
];
paul
Bug #60 corrected...
r102 length = PACKET_LENGTH_TM_LFR_SCIENCE_ASM_F0;
header->pa_lfr_asm_blk_nr[0] = (unsigned char) ( (NB_BINS_PER_PKT_ASM_F0) >> 8 ); // BLK_NR MSB
header->pa_lfr_asm_blk_nr[1] = (unsigned char) (NB_BINS_PER_PKT_ASM_F0); // BLK_NR LSB
paul@pc-solar1.lab-lpp.local
All modes implemented for the waveforms...
r23 break;
paul
Bug #60 corrected...
r102 case SID_NORM_ASM_F1:
break;
case SID_NORM_ASM_F2:
paul@pc-solar1.lab-lpp.local
All modes implemented for the waveforms...
r23 break;
default:
paul
the function asm_reorganize format the spectral matrix to the ICD format
r103 PRINTF1("ERR *** in ASM_send *** unexpected sid %d\n", sid)
paul@pc-solar1.lab-lpp.local
All modes implemented for the waveforms...
r23 break;
paul
Bug #60 corrected...
r102 }
spw_ioctl_send->hlen = HEADER_LENGTH_TM_LFR_SCIENCE_ASM + CCSDS_PROTOCOLE_EXTRA_BYTES;
spw_ioctl_send->hdr = (char *) header;
spw_ioctl_send->options = 0;
// (2) BUILD THE HEADER
header->packetLength[0] = (unsigned char) (length>>8);
header->packetLength[1] = (unsigned char) (length);
header->sid = (unsigned char) sid; // SID
header->pa_lfr_pkt_cnt_asm = 2;
header->pa_lfr_pkt_nr_asm = (unsigned char) (i+1);
// (3) SET PACKET TIME
header->time[0] = (unsigned char) (time_management_regs->coarse_time>>24);
header->time[1] = (unsigned char) (time_management_regs->coarse_time>>16);
header->time[2] = (unsigned char) (time_management_regs->coarse_time>>8);
header->time[3] = (unsigned char) (time_management_regs->coarse_time);
header->time[4] = (unsigned char) (time_management_regs->fine_time>>8);
header->time[5] = (unsigned char) (time_management_regs->fine_time);
//
header->acquisitionTime[0] = (unsigned char) (time_management_regs->coarse_time>>24);
header->acquisitionTime[1] = (unsigned char) (time_management_regs->coarse_time>>16);
header->acquisitionTime[2] = (unsigned char) (time_management_regs->coarse_time>>8);
header->acquisitionTime[3] = (unsigned char) (time_management_regs->coarse_time);
header->acquisitionTime[4] = (unsigned char) (time_management_regs->fine_time>>8);
header->acquisitionTime[5] = (unsigned char) (time_management_regs->fine_time);
// (4) SEND PACKET
status = rtems_message_queue_send( queue_id, spw_ioctl_send, ACTION_MSG_SPW_IOCTL_SEND_SIZE);
if (status != RTEMS_SUCCESSFUL) {
paul
the function asm_reorganize format the spectral matrix to the ICD format
r103 printf("in ASM_send *** ERR %d\n", (int) status);
paul
Bug #60 corrected...
r102 }
paul@pc-solar1.lab-lpp.local
All modes implemented for the waveforms...
r23 }
}
paul
Sync...
r116 void BP_send(char *data, rtems_id queue_id, unsigned int nbBytesToSend )
paul
sync
r113 {
paul
Sync
r115 rtems_status_code status;
paul
sync
r113
paul
Sync...
r116 // SEND PACKET
status = rtems_message_queue_send( queue_id, data, nbBytesToSend);
paul
Sync
r115 if (status != RTEMS_SUCCESSFUL)
{
paul
Sync...
r116 printf("ERR *** in BP_send *** ERR %d\n", (int) status);
paul@pc-solar1.lab-lpp.local
All modes implemented for the waveforms...
r23 }
}
paul
SID corrected in TM_LFR_TC_EXE packets...
r31 void init_header_asm( Header_TM_LFR_SCIENCE_ASM_t *header)
{
header->targetLogicalAddress = CCSDS_DESTINATION_ID;
header->protocolIdentifier = CCSDS_PROTOCOLE_ID;
header->reserved = 0x00;
header->userApplication = CCSDS_USER_APP;
paul
Sync...
r116 header->packetID[0] = (unsigned char) (APID_TM_SCIENCE_NORMAL_BURST >> 8);
header->packetID[1] = (unsigned char) (APID_TM_SCIENCE_NORMAL_BURST);
paul
SID corrected in TM_LFR_TC_EXE packets...
r31 header->packetSequenceControl[0] = 0xc0;
header->packetSequenceControl[1] = 0x00;
header->packetLength[0] = 0x00;
header->packetLength[1] = 0x00;
// DATA FIELD HEADER
header->spare1_pusVersion_spare2 = 0x10;
header->serviceType = TM_TYPE_LFR_SCIENCE; // service type
header->serviceSubType = TM_SUBTYPE_LFR_SCIENCE; // service subtype
header->destinationID = TM_DESTINATION_ID_GROUND;
// AUXILIARY DATA HEADER
header->sid = 0x00;
header->biaStatusInfo = 0x00;
paul
Sync
r99 header->pa_lfr_pkt_cnt_asm = 0x00;
header->pa_lfr_pkt_nr_asm = 0x00;
paul
SID corrected in TM_LFR_TC_EXE packets...
r31 header->time[0] = 0x00;
header->time[0] = 0x00;
header->time[0] = 0x00;
header->time[0] = 0x00;
header->time[0] = 0x00;
header->time[0] = 0x00;
paul
Sync
r99 header->pa_lfr_asm_blk_nr[0] = 0x00; // BLK_NR MSB
header->pa_lfr_asm_blk_nr[1] = 0x00; // BLK_NR LSB
paul
SID corrected in TM_LFR_TC_EXE packets...
r31 }
paul
Sync...
r116 void init_bp_ring_sbm1_bp1( void )
{
unsigned int i;
//********
// F0 RING
bp_ring_sbm1_bp1[0].next = (ring_node_bp*) &bp_ring_sbm1_bp1[1];
bp_ring_sbm1_bp1[0].previous = (ring_node_bp*) &bp_ring_sbm1_bp1[NB_RING_NODES_SBM1_BP1-1];
bp_ring_sbm1_bp1[NB_RING_NODES_SBM1_BP1-1].next = (ring_node_bp*) &bp_ring_sbm1_bp1[0];
bp_ring_sbm1_bp1[NB_RING_NODES_SBM1_BP1-1].previous = (ring_node_bp*) &bp_ring_sbm1_bp1[NB_RING_NODES_SBM1_BP1-2];
for(i=1; i<NB_RING_NODES_SBM1_BP1-1; i++)
{
bp_ring_sbm1_bp1[i].next = (ring_node_bp*) &bp_ring_sbm1_bp1[i+1];
bp_ring_sbm1_bp1[i].previous = (ring_node_bp*) &bp_ring_sbm1_bp1[i-1];
}
//
//********
for (i=0; i<NB_RING_NODES_SBM1_BP1; i++)
{
init_header_bp( &bp_ring_sbm1_bp1[ i ].header,
APID_TM_SCIENCE_SBM1_SBM2, SID_SBM1_BP1_F0,
PACKET_LENGTH_TM_LFR_SCIENCE_SBM1_BP1_F0, NB_BINS_COMPRESSED_SM_SBM1_F0
);
bp_ring_sbm1_bp1[ i ].status = 0;
}
}
void init_bp_ring_sbm1_bp2( void )
paul
Sync
r115 {
unsigned int i;
//********
// F0 RING
paul
Sync...
r116 bp_ring_sbm1_bp2[0].next = (ring_node_bp*) &bp_ring_sbm1_bp2[1];
bp_ring_sbm1_bp2[0].previous = (ring_node_bp*) &bp_ring_sbm1_bp2[NB_RING_NODES_SBM1_BP2-1];
paul
Sync
r115
paul
Sync...
r116 bp_ring_sbm1_bp2[NB_RING_NODES_SBM1_BP2-1].next = (ring_node_bp*) &bp_ring_sbm1_bp2[0];
bp_ring_sbm1_bp2[NB_RING_NODES_SBM1_BP2-1].previous = (ring_node_bp*) &bp_ring_sbm1_bp2[NB_RING_NODES_SBM1_BP2-2];
paul
Sync
r115
paul
Sync...
r116 for(i=1; i<NB_RING_NODES_SBM1_BP2-1; i++)
paul
Sync
r115 {
paul
Sync...
r116 bp_ring_sbm1_bp2[i].next = (ring_node_bp*) &bp_ring_sbm1_bp2[i+1];
bp_ring_sbm1_bp2[i].previous = (ring_node_bp*) &bp_ring_sbm1_bp2[i-1];
paul
Sync
r115 }
//
//********
paul
Sync...
r116 for (i=0; i<NB_RING_NODES_SBM1_BP2; i++)
paul
Sync
r115 {
paul
Sync...
r116 init_header_bp( &bp_ring_sbm1_bp2[ i ].header,
APID_TM_SCIENCE_SBM1_SBM2, SID_SBM1_BP2_F0,
PACKET_LENGTH_TM_LFR_SCIENCE_SBM1_BP2_F0, NB_BINS_COMPRESSED_SM_SBM1_F0
);
bp_ring_sbm1_bp2[ i ].status = 0;
paul
Sync
r115 }
}
paul
Sync...
r116 void init_header_bp( Header_TM_LFR_SCIENCE_BP_t *header,
unsigned int apid, unsigned char sid,
unsigned int packetLength, unsigned char blkNr )
paul
sync
r113 {
header->targetLogicalAddress = CCSDS_DESTINATION_ID;
header->protocolIdentifier = CCSDS_PROTOCOLE_ID;
header->reserved = 0x00;
header->userApplication = CCSDS_USER_APP;
paul
Sync...
r116 header->packetID[0] = (unsigned char) (apid >> 8);
header->packetID[1] = (unsigned char) (apid);
header->packetSequenceControl[0] = TM_PACKET_SEQ_CTRL_STANDALONE;
paul
sync
r113 header->packetSequenceControl[1] = 0x00;
paul
Sync...
r116 header->packetLength[0] = (unsigned char) (packetLength >> 8);
header->packetLength[1] = (unsigned char) (packetLength);
paul
sync
r113 // DATA FIELD HEADER
header->spare1_pusVersion_spare2 = 0x10;
header->serviceType = TM_TYPE_LFR_SCIENCE; // service type
header->serviceSubType = TM_SUBTYPE_LFR_SCIENCE; // service subtype
header->destinationID = TM_DESTINATION_ID_GROUND;
// AUXILIARY DATA HEADER
paul
Sync...
r116 header->sid = sid;
paul
sync
r113 header->biaStatusInfo = 0x00;
header->time[0] = 0x00;
header->time[0] = 0x00;
header->time[0] = 0x00;
header->time[0] = 0x00;
header->time[0] = 0x00;
header->time[0] = 0x00;
header->pa_lfr_bp_blk_nr[0] = 0x00; // BLK_NR MSB
paul
Sync...
r116 header->pa_lfr_bp_blk_nr[1] = blkNr; // BLK_NR LSB
}
void init_header_bp_with_spare(Header_TM_LFR_SCIENCE_BP_with_spare_t *header,
unsigned int apid, unsigned char sid,
unsigned int packetLength , unsigned char blkNr)
{
header->targetLogicalAddress = CCSDS_DESTINATION_ID;
header->protocolIdentifier = CCSDS_PROTOCOLE_ID;
header->reserved = 0x00;
header->userApplication = CCSDS_USER_APP;
header->packetID[0] = (unsigned char) (apid >> 8);
header->packetID[1] = (unsigned char) (apid);
header->packetSequenceControl[0] = TM_PACKET_SEQ_CTRL_STANDALONE;
header->packetSequenceControl[1] = 0x00;
header->packetLength[0] = (unsigned char) (packetLength >> 8);
header->packetLength[1] = (unsigned char) (packetLength);
// DATA FIELD HEADER
header->spare1_pusVersion_spare2 = 0x10;
header->serviceType = TM_TYPE_LFR_SCIENCE; // service type
header->serviceSubType = TM_SUBTYPE_LFR_SCIENCE; // service subtype
header->destinationID = TM_DESTINATION_ID_GROUND;
// AUXILIARY DATA HEADER
header->sid = sid;
header->biaStatusInfo = 0x00;
header->time[0] = 0x00;
header->time[0] = 0x00;
header->time[0] = 0x00;
header->time[0] = 0x00;
header->time[0] = 0x00;
header->time[0] = 0x00;
header->pa_lfr_bp_blk_nr[0] = 0x00; // BLK_NR MSB
header->pa_lfr_bp_blk_nr[1] = blkNr; // BLK_NR LSB
paul
sync
r113 }
paul
Sync
r115 void reset_spectral_matrix_regs( void )
paul
SID corrected in TM_LFR_TC_EXE packets...
r31 {
paul
Header files inclusion reworked...
r40 /** This function resets the spectral matrices module registers.
*
* The registers affected by this function are located at the following offset addresses:
*
* - 0x00 config
* - 0x04 status
* - 0x08 matrixF0_Address0
* - 0x10 matrixFO_Address1
* - 0x14 matrixF1_Address
* - 0x18 matrixF2_Address
*
*/
paul
the function asm_reorganize format the spectral matrix to the ICD format
r103 spectral_matrix_regs->config = 0x00;
spectral_matrix_regs->status = 0x00;
paul
Minor changes
r93 spectral_matrix_regs->matrixF0_Address0 = current_ring_node_sm_f0->buffer_address;
spectral_matrix_regs->matrixFO_Address1 = current_ring_node_sm_f0->buffer_address;
spectral_matrix_regs->matrixF1_Address = current_ring_node_sm_f1->buffer_address;
spectral_matrix_regs->matrixF2_Address = current_ring_node_sm_f2->buffer_address;
paul
SID corrected in TM_LFR_TC_EXE packets...
r31 }
paul
sy_lfr_n_swf_p implemented...
r32
//******************
// general functions
paul
Sync...
r116 void set_time( unsigned char *time, unsigned int coarseTime, unsigned int fineTime )
{
time[0] = (unsigned char) (coarseTime>>24);
time[1] = (unsigned char) (coarseTime>>16);
time[2] = (unsigned char) (coarseTime>>8);
time[3] = (unsigned char) (coarseTime);
time[4] = (unsigned char) (fineTime>>8);
time[5] = (unsigned char) (fineTime);
}
paul
sy_lfr_n_swf_p implemented...
r32