Ejemplo n.º 1
0
        public void Send(Mcu.McuCommand api, params byte[] buffer)
        {
            var bb = new byte[buffer.Length + 1];

            bb[0] = (byte)api;
            for (var i = 0; i < buffer.Length; i++)
            {
                bb[i + 1] = buffer[i];
            }
            this.SendBuffer(bb);
        }
Ejemplo n.º 2
0
        public void Send(Mcu.McuCommand api, int param0, int param1, params byte[] buffer)
        {
            var bb = new byte[buffer.Length + 3];

            bb[0] = (byte)api;
            bb[1] = (byte)param0;
            bb[2] = (byte)param1;
            for (var i = 0; i < buffer.Length; i++)
            {
                bb[i + 3] = buffer[i];
            }
            this.SendBuffer(bb);
        }