fsw_processing.h
54 lines
| 2.0 KiB
| text/x-c
|
CLexer
/ header / fsw_processing.h
paul
|
r45 | #ifndef FSW_PROCESSING_H_INCLUDED | ||
#define FSW_PROCESSING_H_INCLUDED | ||||
paul@pc-solar1.lab-lpp.local
|
r5 | |||
paul
|
r45 | #include <rtems.h> | ||
#include <grspw.h> | ||||
#include <math.h> | ||||
#include <stdlib.h> // abs() is in the stdlib | ||||
#include <stdio.h> // printf() | ||||
paul
|
r56 | #include <math.h> | ||
paul
|
r45 | |||
#include "fsw_params.h" | ||||
paul
|
r56 | #include "fsw_spacewire.h" | ||
paul
|
r45 | |||
paul
|
r106 | extern volatile int sm_f0[ ]; | ||
extern volatile int sm_f1[ ]; | ||||
extern volatile int sm_f2[ ]; | ||||
paul
|
r32 | |||
// parameters | ||||
extern struct param_local_str param_local; | ||||
// registers | ||||
paul
|
r31 | extern time_management_regs_t *time_management_regs; | ||
extern spectral_matrix_regs_t *spectral_matrix_regs; | ||||
paul
|
r45 | extern rtems_name misc_name[5]; | ||
extern rtems_id Task_id[20]; /* array of task ids */ | ||||
paul
|
r95 | void init_sm_rings( void ); | ||
void reset_current_sm_ring_nodes( void ); | ||||
paul
|
r93 | |||
paul@pc-solar1.lab-lpp.local
|
r5 | // ISR | ||
paul
|
r99 | void reset_nb_sm_f0( void ); | ||
paul
|
r31 | rtems_isr spectral_matrices_isr( rtems_vector_number vector ); | ||
paul
|
r34 | rtems_isr spectral_matrices_isr_simu( rtems_vector_number vector ); | ||
paul
|
r31 | |||
paul@pc-solar1.lab-lpp.local
|
r5 | // RTEMS TASKS | ||
paul@pc-solar1.lab-lpp.local
|
r9 | rtems_task avf0_task(rtems_task_argument argument); | ||
paul
|
r31 | rtems_task smiq_task(rtems_task_argument argument); // added to test the spectral matrix simulator | ||
rtems_task matr_task(rtems_task_argument argument); | ||||
paul@pc-solar1.lab-lpp.local
|
r17 | |||
paul
|
r31 | void matrix_reset(volatile float *averaged_spec_mat); | ||
paul
|
r95 | void BP1_set_old(float * compressed_spec_mat, unsigned char nb_bins_compressed_spec_mat, unsigned char * LFR_BP1); | ||
void BP2_set_old(float * compressed_spec_mat, unsigned char nb_bins_compressed_spec_mat); | ||||
paul
|
r31 | // | ||
void init_header_asm( Header_TM_LFR_SCIENCE_ASM_t *header); | ||||
paul
|
r103 | void ASM_reorganize( float *averaged_spec_mat, float *averaged_spec_mat_reorganized ); | ||
void ASM_compress( float *averaged_spec_mat, unsigned char fChannel, float *compressed_spec_mat ); | ||||
void ASM_convert(volatile float *input_matrix, char *output_matrix); | ||||
void ASM_send(Header_TM_LFR_SCIENCE_ASM_t *header, char *spectral_matrix, | ||||
paul
|
r35 | unsigned int sid, spw_ioctl_pkt_send *spw_ioctl_send, rtems_id queue_id); | ||
paul
|
r40 | void fill_averaged_spectral_matrix( void ); | ||
paul
|
r31 | void reset_spectral_matrix_regs(); | ||
paul@pc-solar1.lab-lpp.local
|
r5 | |||
paul
|
r45 | #endif // FSW_PROCESSING_H_INCLUDED | ||