Application Server listens on TCP/IP port 51234


In order to communicate with the server, we need to send TCP/IP text commands from some external utility to perClass Mira. In our example, the utility may run on the same computer as perClass Mira. This is necessary. Typical demonstrators will run perClass Mira on a separate computer dedicated to a "second screen" and control it from already available control computer or PLC system orchestrating the entire process (belt control, actuators, lights etc.)


In the following example, we use the free PacketSender software you may download from: https://packetsender.com/


To prepare perClass Mira for running the Application Server session, we need to initialize an acquisition device (either a camera or a filereader).


Once we are able to start and stop acquisition from perClass Mira side, we may do the same remotely. Application Server provides a number of text commands that invoke actions.


TIP: perClass Mira installation contains a ready-to-use data base of commands in PacketSender format in the lib directory. You may import these to a PacketSender session.

In PacketSender, we define two commands, namely "acq start" and "acq stop". For each command, its name and payload (content) are defined in the section . Secontion defines the Application Server machine address and port. In our situation, we fill "localhost" as both perClass Mira and the PacketSender run on the same machine.

We can send the command by pressing Send button . The command can be saved for later use with Save button.



In perClass Mira window, we will see the text command listed in the Output window and the acquisition will start:



Below you can see, that the PacketSender window lists both the command sent and also the response of the Application Server . The response always starts with "ok;" or "error;" string denoting whether the command is understood, followed with the actual command string, another semicolor delimiter and an aditional comment.