14.3  piWebCAT  - development tools

The following were essential in achieving successful development of this project:

My Siglent SDS2202X-E oscilloscope.

This is a superb 200 MHz 2 - channel storage scope from China.

Its vital feature in developing piWebCAT was its very flexible ability to capture

and expand displays of serial data and to decode the data as ASCII or Hex.
(Note that piWebCAT was developed using serial radio connections.
 USB connectivity was added at the end of development, after data problems were solved)

This allowed me to examine in detail the data streams to and from the RPi serial port.

One particular issue was in reading the band stacking register on my Icom IC7000.

The radio was observed to return a 26 byte data string.
I could find no documentation on this at all  - I had no idea that there were 26 bytes to receive.
Firstly, it is essential to know how many bytes will be in a response.

- Without this scope, I could not determine this.
Secondly I needed to know the content / format of the string.
The decode on the scope revealed BCD coded frequency and operating mode at the
start of the data section.  That was what I needed - my system works.
(I still have no idea what is in the remainder of the 26 bytes!!

   If I have missed some documentation then all advice is welcome!)

Below is Noise Reduction level request  to the IC7000.

This is the TX request from piWeb to the IC7000

expanded to view the data decode.

The sequence is:

0xFE  0xFE -  obligatory header bytes

0x70   - IC7000's address

0xE0  -  address assigned to piWebCAT

0x05  0x01  0x14  the subcommand
           ( three bcd bytes for 050114)

0xFD  - obligatory terminator

Web Browser Inspect element facility

This is a right mouse option on most web browsers.

It is particularly good on Firefox developer  - and Chrome.

It provides a huge amount  of information on traffic to and from websites.
It has very useful debugging facilities.

Its most useful application was in examining Ajax requests to the RPi server and the resulting responses.

If there an error in the server PHP code which is processing the request, the PHP echos back a detailed
error message containing the location of the problem  

Firefox developer  - Inspector - display examples

For the display below, I first disabled repetitive tasks in the timing table  - network traffic comes to a stop.

- but the buttons are still active as evidenced by their effect on the radio.


I clicked right mouse over piWebCAT and then selected the network tab.

Then I clicked the DNR on/off button and the highlighted message appeared bottom left.

Then I selected the headers tab.
The display shows the complete URL sent to the server by Ajax code.

I have extracted the URL part and increased the contrast:


Further example - frequency read.

For the display adjacent, I turned repetitive tasks back on -> A fast scroll of network traffic appears on the left.

piWebCAT is reading the S meter every 100mS and the frequency every 200ms.

I clicked on the fast scrolling data and froze one item - a frequency read.

The result is shown. Its a VFO B read of

14.090116 Hz

Further example - S meter read  - FTdx101D

The above URL is a client to servers S meter level request.
Task=1 is code for read.  jobdata = 0 because there is no data for a read request,

The response data is to the left.

The level is 30 ( from a range of 0 -255)

The response contain's 10 ascii characters:

See answermask in meter table = RM0htu$$$;  

                     htu is hundreds, tens and units of answer.  $ are dont care characters