import ctypes
from Grifo_E_1553lib.data_types.dl_target_validity import DlTargetValidity
from Grifo_E_1553lib.data_types.semicircle import Semicircle
from Grifo_E_1553lib.data_types.target_presentation_data import TargetPresentationData
from Grifo_E_1553lib.data_types.target_half_call_sign import TargetHalfCallSign
from Grifo_E_1553lib.data_types.target_position import TargetPosition
from Grifo_E_1553lib.data_types.tws_status_and_targets import ValitidyWordAndHptIdentifier, TrackPriority0104, TrackPriority0508, TrackAccurancy0104, TrackAccurancy0508, TrackIdOfTwsTrackedTarget0102, TrackIdOfTwsTrackedTarget0304, TrackIdOfTwsTrackedTarget0506, TrackIdOfTwsTrackedTarget0708
from Grifo_E_1553lib.data_types.x_display_coord_of_the_hpt_target import XDisplayCoordOfTheHptTarget
from Grifo_E_1553lib.data_types.y_display_coord_of_the_hpt_target import YDisplayCoordOfTheHptTarget
from Grifo_E_1553lib.data_types.target_velocity_magnitude  import TargetVelocityMagnitude
from Grifo_E_1553lib.data_types.tws_velocity import TwsVelocity
from Grifo_E_1553lib.data_types.relative_timetag import RelativeTimetag

class TwsStatusAndTargets0102(ctypes.Structure):
    _fields_ = [
        ("valitidy_word_and_hpt_identifier", ValitidyWordAndHptIdentifier),
        ("track_priority_01_04", TrackPriority0104),
        ("track_priority_05_08", TrackPriority0508),
        ("track_accurancy_01_04", TrackAccurancy0104),
        ("track_accurancy_05_08", TrackAccurancy0508),
        ("track_id_of_tws_tracked_target_01_02", TrackIdOfTwsTrackedTarget0102),
        ("track_id_of_tws_tracked_target_03_04", TrackIdOfTwsTrackedTarget0304),
        ("track_id_of_tws_tracked_target_05_06", TrackIdOfTwsTrackedTarget0506),
        ("track_id_of_tws_tracked_target_07_08", TrackIdOfTwsTrackedTarget0708),
        ("x_display_coord_of_the_hpt_target", XDisplayCoordOfTheHptTarget),
        ("y_display_coord_of_the_hpt_target", YDisplayCoordOfTheHptTarget),
        ("time_tag_of_tracked_target_01_data", RelativeTimetag),
        ("range_of_tracked_01_target", TargetVelocityMagnitude),
        ("target_01_position_x", TwsVelocity),
        ("target_01_position_y", TwsVelocity),
        ("target_01_position_z", TwsVelocity),
        ("target_01_velocity_magnitude", TargetVelocityMagnitude),
        ("target_01_velocity_x", TwsVelocity),
        ("target_01_velocity_y", TwsVelocity),
        ("target_01_velocity_z", TwsVelocity),
        ("time_tag_of_tracked_target_02_data", RelativeTimetag),
        ("range_of_tracked_02_target", TargetVelocityMagnitude),
        ("target_02_position_x", TwsVelocity),
        ("target_02_position_y", TwsVelocity),
        ("target_02_position_z", TwsVelocity),
        ("target_02_velocity_magnitude", TargetVelocityMagnitude),
        ("target_02_velocity_x", TwsVelocity),
        ("target_02_velocity_y", TwsVelocity),
        ("target_02_velocity_z", TwsVelocity)
    ]

    def __init__(self):
        super().__init__()
        self.valitidy_word_and_hpt_identifier = ValitidyWordAndHptIdentifier()
        self.track_priority_01_04 = TrackPriority0104()
        self.track_priority_05_08 = TrackPriority0508()
        self.track_accurancy_01_04 = TrackAccurancy0104()
        self.track_accurancy_05_08 = TrackAccurancy0508()
        self.track_id_of_tws_tracked_target_01_02 = TrackIdOfTwsTrackedTarget0102()
        self.track_id_of_tws_tracked_target_03_04 = TrackIdOfTwsTrackedTarget0304()
        self.track_id_of_tws_tracked_target_05_06 = TrackIdOfTwsTrackedTarget0506()
        self.track_id_of_tws_tracked_target_07_08 = TrackIdOfTwsTrackedTarget0708()
        self.x_display_coord_of_the_hpt_target = XDisplayCoordOfTheHptTarget()
        self.y_display_coord_of_the_hpt_target = YDisplayCoordOfTheHptTarget()
        self.time_tag_of_tracked_target_01_data = RelativeTimetag()
        self.range_of_tracked_01_target = TargetVelocityMagnitude()
        self.target_01_position_x = TwsVelocity()
        self.target_01_position_y = TwsVelocity()
        self.target_01_position_z = TwsVelocity()
        self.target_01_velocity_magnitude = TargetVelocityMagnitude()
        self.target_01_velocity_x = TwsVelocity()
        self.target_01_velocity_y = TwsVelocity()
        self.target_01_velocity_z = TwsVelocity()
        self.time_tag_of_tracked_target_02_data = RelativeTimetag()
        self.range_of_tracked_02_target = TargetVelocityMagnitude()
        self.target_02_position_x = TwsVelocity()
        self.target_02_position_y = TwsVelocity()
        self.target_02_position_z = TwsVelocity()
        self.target_02_velocity_magnitude = TargetVelocityMagnitude()
        self.target_02_velocity_x = TwsVelocity()
        self.target_02_velocity_y = TwsVelocity()
        self.target_02_velocity_z = TwsVelocity()