예제 #1
0
        public void Test2()
        {
            var bytes = "0901".ToHexBytes();
            JT809_0x9500_0x9502 jT809_0X9500_0X9502 = JT809Serializer.Deserialize <JT809_0x9500_0x9502>(bytes);

            Assert.Equal(0x09, jT809_0X9500_0X9502.LensID);
            Assert.Equal(0x01, jT809_0X9500_0X9502.SizeType);
        }
예제 #2
0
        public void Test1()
        {
            JT809_0x9500_0x9502 jT809_0X9500_0X9502 = new JT809_0x9500_0x9502
            {
                LensID   = 0x09,
                SizeType = 0x01
            };
            var hex = JT809Serializer.Serialize(jT809_0X9500_0X9502).ToHexString();

            Assert.Equal("0901", hex);
        }