Ejemplo n.º 1
0
        /*
         * Transfer UDP message from bytes to a svframe
         */
        private Svframe BytesToSvframe(byte[] bytes)
        {
            float[] floats = BytesConverter.ToFloatArray(bytes);
            Svframe frame  = new Svframe();


            foreach (var item in get_offset)
            {
                float aaa    = floats[item.Value];
                var   name   = item.Key;
                var   offset = item.Value;



                frame.GetType().GetProperty(name).SetValue(frame, floats[item.Value]);
            }

            return(frame);
        }