import ctypes
from Grifo_E_1553lib.data_types.rdr_status_tellback import RdrStatusTellback
from Grifo_E_1553lib.data_types.rdr_fun_and_param1_tellback import RdrFunAndParam1Tellback
from Grifo_E_1553lib.data_types.rdr_fun_and_param2_tellback import RdrFunAndParam2Tellback

class MsgRdrStatusTellback(ctypes.Structure):
    """
    A2: Radar Operation Command.

    Contains commands for radar mode, functions, and parameters.
    """
    _pack_ = 1  # Forza l'allineamento a 1 byte
    _fields_ = [
        ("rdr_mode_tellback", RdrStatusTellback),
        ("param1_tellback", RdrFunAndParam1Tellback),
        ("param2_tellback", RdrFunAndParam2Tellback)
    ]

    def __init__(self):
        super().__init__()  # Chiama il costruttore della classe base
        self.rdr_mode_tellback = RdrStatusTellback()
        self.param1_tellback = RdrFunAndParam1Tellback()
        self.param2_tellback = RdrFunAndParam2Tellback()