Exemplo n.º 1
0
        public void TestATCommandDestinationHighWithFrameId()
        {
            var cmd = new ATCommand(AT.DestinationHigh);

            cmd.FrameId = 0x02;
            Assert.AreEqual(new byte[] { 0x08, 0x02, (byte)'D', (byte)'H' }, cmd.ToByteArray());
        }
Exemplo n.º 2
0
        public void TestATCommandNodeDiscover()
        {
            var cmd = new ATCommand(AT.NodeDiscover);

            Assert.AreEqual(new byte[] { 0x08, 0x00, (byte)'N', (byte)'D' }, cmd.ToByteArray());
        }
Exemplo n.º 3
0
        public void TestATCommandDestinationHigh()
        {
            var cmd = new ATCommand(AT.DestinationHigh);
            var v   = new ATLongValue(0x11223300);

            cmd.SetValue(v);
            Assert.AreEqual(new byte[] { 0x08, 0x00, (byte)'D', (byte)'H', 0x11, 0x22, 0x33, 0x00 }, cmd.ToByteArray());
        }