//!;;Rpy::+
//!;;Rpy::ModelElement: iddtypes::idd_stt_types
//!;;Rpy::
//!;;Rpy::Component: IDDComponent 
//!;;Rpy::Configuration: IDDConfig
//!;;Rpy::Project: IDD
//!;;Rpy::
//!;;Rpy::FilePath: idd_stt_types.h
//!;;Rpy::Tag: $Tag
//!;;Rpy::
//!;;Rpy::Copyright: Leonardocompany - COMPANY RESTRICTED
//!;;Rpy::
//!;;Rpy::Generated by Rhapsody: 7.5.3 
//!;;Rpy::-


#ifndef idd_stt_types_H
#define idd_stt_types_H

//## auto_generated
#include "iddtypes.h"
//## dependency idd_base_types
#include "idd_base_types.h"
//## dependency idd_frequency_types
#include "idd_frequency_types.h"
namespace iddtypes
{
    //## package iddtypes::idd_stt_types
    
    
    //#[ type stt_mcp_results_t
    
    enum left_right_t CPP_ENUM_BASE(int) { left, right };
    
    enum ground_mover_t CPP_ENUM_BASE(int) { no_mover, mover };  
                               
    enum accuracy_t CPP_ENUM_BASE(int) { level_0, level_1, level_2, level_3 };
    
    enum track_quality_t CPP_ENUM_BASE(int)
    {
       trk_qual_not_active,
       aoj,
       hoj,
       normal_track,
       incomplete_track
    };
                               
    struct stt_radar_results_for_graphic_t
    {
        freq_channel_t     channel_number;
        band_indicator_t   band_indicator;
        active_t           hpt_coast;
    };
    
    struct mcp_time_t
    {
      validity_t     validity;
      unsigned short hour;
      unsigned short minute;
      unsigned short second;
    };
    
    struct stt_target_results_for_graphic_t
    {
        metres_t           target_range;
        radians_t          target_azimuth;
        radians_t          target_elevation;
        mcp_time_t         time_to_go_to_hpt;
        radians_t          hpt_aspect_angle;
        left_right_t       hpt_left_right_aspect;
        radians_t          cata_azimuth_for_gc;
        radians_t          target_ground_track;
        radians_t          track_angle;
        metres_per_sec_t   target_ground_speed;
        validity_t         angle_val_for_as_track;
        metres_t           target_altitude;
        metres_per_sec_t   target_cas_for_gc;
        mach_no_t          target_mach_no_for_gc;
        track_quality_t    hpt_target_qualifier;
        track_quality_t    hpt_target_status;
        boolean            quality_in_freeze;
        int                n_bar_jam_stt;
    
    };
    
    struct stt_results_for_graphic_t
    {
        stt_radar_results_for_graphic_t    stt_radar_results_for_graphic;
        stt_target_results_for_graphic_t   stt_target_results_for_graphic;
    };
    
    struct stt_results_for_antenna_t
    {
        radians_t   azimuth_command;
        radians_t   elevation_command;
    };
    
    typedef struct
    {
        validity_t   target_range_data_valid;
        validity_t   target_position_data_valid;
        validity_t   target_velocity_data_valid;
        validity_t   target_acceleration_data_valid;
        validity_t   target_range_rate_data_valid;
        validity_t   target_aspect_angle_data_valid;
        validity_t   target_cas_and_mach_no_data_valid;
    }                target_data_validity_flags_t;
    
    struct target_dynamic_t
    {
        float   magnitude;
        float   x;
        float   y;
        float   z;
    };
    
    
    struct estimation_stdev_t
    {
        float   x;
        float   y;
        float   z;
    }; /* added for SR1 */
    
    struct stt_results_for_avionic_t
    {
        boolean                        target_in_coast;
        boolean                        aoj_on_target;
        seconds_t                      target_time_tag;
        target_data_validity_flags_t   target_data_validity_flags;
        boolean                        hoj_on_target;
        target_dynamic_t               target_position_vector;
        target_dynamic_t               target_velocity_vector;
        target_dynamic_t               target_acceleration_vector;
        mach_no_t                      target_mach_no;
        metres_per_sec_t               target_cas;
        radians_t                      target_aspect_angle;
        metres_per_sec_t               target_range_rate;
        accuracy_t                     target_position_accuracy;
        accuracy_t                     target_velocity_accuracy;
        accuracy_t                     target_acceleration_accuracy;
        estimation_stdev_t             estimation_stdev;              /* added for SR1 */
        ground_mover_t                 ground_mover_indication;       /* added for SR9 */
    };
    
    struct stt_mcp_results_t
    {
        stt_results_for_graphic_t    stt_results_for_graphic;
        stt_results_for_antenna_t    stt_results_for_antenna;
        stt_results_for_avionic_t    stt_results_for_avionic;
    }
    ;
    //#]
    
    //#[ type stt_target_t
    struct stt_debug_info_t
    {
        float rcs;
        float snr;
    };
    
    struct mtt_info_t
    { 
        int track_id;   //id for MTT 1553 message
        int aux_id;     //auxiliary ID (special use by RIS)
        int priority;
    };
    
    struct stt_target_t
    {                   
        int valid;
        stt_mcp_results_t data;
        stt_debug_info_t dbg_info;
        
        mtt_info_t mtt_info;
        
        int pred_state; //0: predicted, <0: search plot associated, >=: active tracking
        
        uint32_t spare[2];
    };
    //#]
    
    //#[ type mtt_target_list_t
    struct mtt_target_list_t
    {                   
        enum { max_mtt_targets=10};
        
        unsigned int num_tracks;
        unsigned int tracks_valid_mask;//one bit per target
        //int priorities[max_mtt_targets];
        unsigned int num_unassociated_detections;
        
        int hpt_manual_id;
        
        unsigned int spare_sts[2];
        
        iddtypes::stt_target_t sttTgt[max_mtt_targets];
            
        //unsigned int spare_trailer[4];    
    };
    //#]
}

#endif
//;;Rpy:: end


