You are here: Information > Application Notes > Automation Server: Why use it? > AutomationServer > Running Automation Server Script

Running Automation Server Script

In this section we will make a comparison between the main program code and the manual operation at the GUI in a sniffing and capture session. This approach will show that the Automation Server will duplicate the manual processes but automation offers reliable repetition of those manual process and will save time in development and regression testing.

Note: Note that this is sample script and that you will have to change the code in the main program to suit your specific sniffing and capture needs. The command set is outlined in the Programmers Guide in Chapter 3.

On or about line 824 of the sample script you will see the following code. StaertFTS tells the Automation Server to launch the ComProbe software by opening your version of Frontline ComProbe Protocol Analysis System and to use a specific personality.

StartFTS [format "%s;%s" $CPASVersion $Profile]

In the code above from the sample script $CPASVersion was defined at line 803, and the $Profile was set at line 823 to use ComProbe BPA 600 and ComProbe 802.11 in coexistence. This is equivalent to 1) double clicking on the Frontline desktop folder and starting the software and 2) selecting a capture method.

$Profile = BPA600_Coex", BPA600 and 802.11 in Coexistence

Moving to line 831 in the sample script we see a configuration setting command for the ComProbe BPA 600. The only parameters shown in this code are the address of the Master and Slave devices. If other parameters are omitted from the code the default values are selected. This line of code is equivalent to setting the BPA 600 datasource for Classic Bluetooth.

ConfigSettings [format "IOParameters;BPA600;Master=0x00025b01cb8b;Slave=0x00025b01cbe1"]

BPA 600 Datasource Classic Only

ConfigSettings equivalent: ComProbe BPA 600 Configuration Settings Dialog

Similar ConfigSettings code will appear in the sample script for the ComProbe 802.11.

At line 853 the StartSniffing command appears. This is equivalent to clicking the Start Sniffing buttonStart Sniffing on the BPA 600 datasource toolbar. Start Sniffing will start synchronization of the BPA 600 with the Bluetooth Devices. Once synchronization is acheived the arrow between the Classic devices will turn green with the arrow head point to the master device.

StartSniffing

Note: StartSniffing is unique to Bluetooth ComProbe devices, and it will automatically execute the Automation Server StartCapture command once synchronized. For non-Bluetooth devices use the StartCapture command that is equivalent to the Start Capture buttonStart Sniffing in the Control window.

At line 874 the following code will halt the capture after 10 seconds. This bit of code illustrates the control that you can have over the capture process.

after 10000

At line 879 we have another Bluetooth-unique command that stops the sniffing and is equivalent to clicking the Stop Sniffing buttonStop Sniffing on the BPA 600 datasource.

StopSniffing

Here is one of those Bluetooth-unique situations. At line 889 the Stop Capture command is issued. Unlike the Start Sniffing command , the Stop Sniffing command does not automatically execute the Stop Capture command so it must be in the program if using ComProbe Bluetooth hardware. Stop Capture will stop the capture of data. This command is equivalent to clicking on the Stop Capture buttonStop Sniffing on the Contrtol window.

StopCapture

BPA 600 Control Window

BPA 600 Control window; Stop Capture is to the right of the red button.

At the end of the program you will want to stop the ComProbe software, so at line 900 we have the following code.

StopFTS

Finally good programming housekeeping dictates that you should clear all connections. The following procedure will disconnect the client-server and breakdown the TCP connection.

FTEBaseCleanup

This section has hit only the highlights of the sample script, but it has illustrated the connection between Automation and the manual sniffing and capture of data. Your programs may be more detailed and will certainly use many more commands. Refer to the ComProbe Automation Server Protocol Programmers Guide for more information on the command set.

Next....