Esempio n. 1
0
        internal void SetHeartbeatTelegramm()
        {
            List <byte> l = new List <byte>();

            KnxIpHeader header  = new KnxIpHeader(knxnetip_services.CONNECTIONSTATE_REQUEST);
            KnxHpai     Control = new KnxHpai(con.myIP, con.clientPort);

            header.Length = (short)(header.bytes.Length + Control.bytes.Length + 2);
            l.AddRange(header.bytes);
            l.Add(con.channelId);
            l.Add(0x00);
            l.AddRange(Control.bytes);

            _bytes = l.ToArray();
        }
Esempio n. 2
0
        /// <summary>
        ///
        /// </summary>
        internal void SetConnectTelegramm()
        {
            List <byte> l = new List <byte>();

            KnxIpHeader header     = new KnxIpHeader(knxnetip_services.CONNECT_REQUEST);
            KnxHpai     ControlCon = new KnxHpai(con.myIP, con.clientPort);
            KnxHpai     DataCon    = new KnxHpai(con.myIP, con.clientPort);
            KnxCri      Cri        = new KnxCri();

            header.Length = (short)(header.bytes.Length + ControlCon.bytes.Length + DataCon.bytes.Length + Cri.bytes.Length);
            l.AddRange(header.bytes);
            l.AddRange(ControlCon.bytes);
            l.AddRange(DataCon.bytes);
            l.AddRange(Cri.bytes);

            _bytes = l.ToArray();
        }