Lapsnaper TCP Connection Specification

I am using Lapsnapper (transponder sync system) running on Android.

Lapsnapper allows you to use a TCP / IP server that you can connect to, create a user interface, and get some other relevant RE data: transponders, etc. from the system.

I do not understand the Lapsnapper server TPS specification.

I used to do some tcp stuff, but I'm basically a higher level programmer, and to be honest, I'm a little out of depth with this raw TCP file.

The spectrum reads:

Lapsnapper Spec

I don't understand how to "send" tcp data? I don't understand how 0x70, 0x17

(6000) and 2 bytes match ... The same applies to 0x13, 0x00, 0x00, 0x00 = 19

which spec should be 4 bytes, but string "19" is 2 bytes?

I am trying to understand what I am reading. Any help would be appreciated as I have quite a few compromises to make on this server and I want to understand what I am doing ...

I have asked for help from lapsnapper support, but at the same time I would like to learn something new according to the above.

What am I really "sending" on a TCP connection?

Spectrum says I should wait for a message back, but with my current implementation, the connection seems to be established, but I never get anything.

Reply message:

lapsnapper response

My code: (PS This code block works if I make a simple connection to the SMTP server and I can make a basic connection with a response from the specified smtp server. However, I never get a response when I try to talk to the TCP Lapsnapper server using the code below)

                string lapSnapperIP = "10.0.0.131";
                int lapsnapperPort = 9001;

                string lapSnapperMessageID;
                string lapsnapperLengthOfMessage;
                string lapsnapperProductID;
                string lapsnapperServerVersion;
                string lapsnapperPasswordLength;
                string lapsnapperPassword;

                lapSnapperMessageID = "6000";
                lapsnapperLengthOfMessage = "19"; //to implement
                lapsnapperProductID = "50";
                lapsnapperServerVersion = "100000";
                lapsnapperPasswordLength = "4";
                lapsnapperPassword = "1234";

                string lapSnapperDataSend;

                lapSnapperDataSend = lapSnapperMessageID + lapsnapperLengthOfMessage + lapsnapperProductID + lapsnapperServerVersion + lapsnapperPasswordLength + lapsnapperPassword;

                s.Connect(lapSnapperIP, lapsnapperPort);

                byte[] sendMessage = Encoding.UTF8.GetBytes(lapSnapperDataSend);

                byte[] receiveBytes = new byte[256];

                int i = 0;
                string receivedMessage = "";

                //send data
                i = s.Send(sendMessage);

                //receive data
                i = s.Receive(receiveBytes);         // (no reply here...)

                receivedMessage = Encoding.UTF8.GetString(receiveBytes);

      

thank

0


source to share





All Articles