21 July 2017

playing with psk-Sounder and Stanag-4285

I used the word "play" because this post does not claim to be a scientific treatment or a in-depth study on propagation mechanisms. HF propagation is not a sort of "deterministic machine" with a certain set of known rules to apply, is not so immediate as a multiplication table, but rather it's a very complex science which involves several disciplines; there is a lot of things to know and a lot of still not clear things... and something unpredictable. Almost casually I found the psk-Sounder software and decided to have just a close look at it: the results are shown in this "cheap and cheerful" post. I want to thanks Murray Greenman, a great expert on HF propagation (20 years experience) and co-developer of psk-sounder, for the precious help and clarifications.

STANAG-4285 is basically a 2400 baud PSK-8 signal, transmitted in frames of 256 symbols in a frame. The intersting thing is an 80-symbol section of this frame which contains a repeated 31-bit pseudo-random binary sequence (PN). PSK-Sounder uses frames of the same length and its cross-correlator allows to locate each frame exactly in time. Since a PN sequence is transmitted every 256/2400 secs, by comparing the time of the frame with a clock in the computer, we can also measure changes in the propagation delay of the received signal over time and plot such measures in the so-termed Correlogram.
The Correlogram is then a representation of propagation delay (vertically), elapsed time (horizontally) and correlation significance (relative signal strength of each ray) as brightness. You can use the mouse to read off the delay between responses.

Fig. 1 - psk-Sounder monitoring a STANAG-4285 transmission on 17MHz from CTA Monsanto (Portugal)
"As an example, imagine we are receiving a signal from a station some distance away, which is providing both ground wave and F-layer ionospheric signals - the classic NVIS situation. The ground wave will be delayed by just a millisecond or two (300km per millisecond at the speed of light), while the F-layer signal, travelling a further 300km up to the ionosphere and another 300km back, will be delayed an extra 2ms. Both these signals arrive at the receiver, and the cross-correlator has to work with the combined signal. So, it will in fact find two peaks, about 2ms apart, and we can display or plot this information, and measure the delay. Very often the propagation is even more complex, especially at greater distances, and of course very often the ground wave signal is not received at all." 
PSK-Sounder, along with documentation, instructions and examples, can be downloaded from:

1) a serious approach requires the monitoring of several stations and frequencies for long periods, say one year at least, so to observe the changes in propagation in different seasons and in different hours of the day per each station/frequency (...the sun is not a light bulb). For my scope, I monitored only two S4285 stations at fixed times (for about a 5-minutes period) during the day:

- 5215.6 KHz French Navy Toulon F, 445 Km West from my QTH
- 8698.2 KHz Norwegian Navy Bodo NOR, 2721 Km North from my QTH

It's important to note that in the case of Toulon the path is in large part over the sea (83.5%).
Fig. 2 - the "monitored" STANAG-4285 stations
2) There are empty areas in some of the following correlograms which are due the lack of S4285 sync. It's always difficult to achieve really long monitoring times with PSK Sounder, as something inevitably disrupts the bitstream and consequently the synchronization with the incoming S4285 signal is lost. Obviously, real modems resynchronise to the PN sequence instantly, but PSK-Sounder is not locked at all and simply observes where the PN sequence is! (as said above).

3) I have no stations within ground wave range (say 50 km at 5 MHz, 100 at most), the closest is IDR  Italian Navy from Santa Rosa (Rome), so the lowest 0 seconds fligth-time track in Correlograms (that would be the ground wave) is here the E layer response, ie the region about 30-50 km up from earth. This means that the delays are not the real ones but are related to E responses, when present, or at least to the lower one.

4) Combined Correlograms (Toulon/Bodo) would be very interesting but unfortunately I do not have a such tool at my disposal.

One could say that similar tests do not make a great sense (and that's right), anyway, although the above limitations, some interesting observations can be noted.

Correlograms - Bodø (8698.2 KHz - 2721 Km North - 20 July)

Fig. 2a

Fig. 2b
Fig. 2c
Fig. 2d

I am not in a position to correctly describe the above scenarios, but I can give a rough description of what I see. While around 1000Z (Fig. 2b) the reception is sustained by E layer, around 1400Z (Fig. 2c) the propagation is mostly due to F layers: you can see the different heights (ie delays) of the thickest black line. Pobably, at that time (1420Z) the absorbing D layer is disappeared, signals have a greater strength and can penetrate E layer and reach the upper F region.

Correlograms - Toulon (5215.6 KHz - 445 Km West - 20 July)

Fig. 3a
Fig. 3b
Fig. 3c
Fig. 3d
In the morning (Fig. 3a) are visible two well distinct paths reception due to the refractions by E and F layers. In the central part of the day, the E response line is a less pronunciated line and delayed responses up to 4-5 msec begin to be visible (Figs. 3b, 3c); it's very interesting the short duration scatter in Figure 3c which causes a cloud of delay responses > 5 msec.
As said, I am not in a position to give an explanation to this, I asked Murray and I quote here the reply he sent me (it's worth reading it): "[...] It's very difficult to say from just the Correlogram. If you consider a triangle with a base of 450 km (the station's distance from you), which is a flight time of 1.5 ms, and a total 'distance' of the two sides of 4.5 ms (the delay added by the path you are interested in), then you can construct an isosceles triangle which will have the refractive point at the peak. The sides will each be 2.25 ms, and the vertical height to the peak can be calculated to be 4.44 ms, or a height of 1332 km above the base.
We know that the F layers are 200 - 300 km in altitude, so clearly the scenario I just described is not correct. There are two factors involved: (1) the possibility that the signal bounced around (is scatter); and (2) that the speed of light is much reduced at the refractive layer, since the refractive index is high here. So therefore the path is not a simple triangle, but has an area of multiple refractions with reduced propagation speed.
So the complicated answer is that I consider that area to be one of multiple scatter, the signal bouncing around between layers (probably F1 and F2) for some time before returning to earth. It is probably not a small  'cloud' as such, but a wide layer which was briefly in the right place for you to see the effect.
Another point to consider is that the ground wave range on 5 MHz is about 50 km, 100 at most, so what looks like the ground wave is most likely the E layer response, the layer about 30 - 50 km up. [...]". Anyway, bounces between sky and sea are also probable.
Around 2000Z (Fig. 3d) the E response returns to be preminent along with the lower F layer, probably still many bounces cause delayed responses up to 5msec. 

Final note
HF propagation is a fascinating part of our hobby but things get very complicated if one want to deepen his knowledge about it. Unlike what it may seem from reading some websites, propagation is not summarizable in a few simple rules but there are a lot of things to study ...and "The trouble is that this sort of study raises more questions than we have answers for!", as Murray Greenman says.

14 July 2017

short bit-analysis of a STANAG-4538 HDLn transfer (BW2 bursts)


Each HDLn transfer consists of n TX Frames (n = 24, 12, 6, or 3) each consisting of n data packets; each data packet consists of 233-byte data segment plus a 17-bit Sequence Number. Each TX Frame is sent using burst waveform BW2.
During the construction of BW2, a 32-bit Cyclic Redundancy Check (CRC) value is computed across the 1881 payload data bits of each data packet (233 bytes of user data, plus the 17-bit of Sequence Number) and is then appended to the data packet. Then, seven encoder flush bits with values of zero (Flush) are appended to produce an Extended Data packet of 1920 bit length,ie: 233 data bytes + 7 overhead bytes (17-bit sequence number + 32-bit CRC + 7-bit flush). See this post about the formation of a BW2 burst.

Fig. 1 - BW2 formation
That said, we can go back to the original datagram by inspecting the last 56 bits of the Extended Data packets in the two BW2 bursts (Fig. 2a).
The value of the Packet Number fields varies from 0 to 5, this means that it's a 2 x HDL6 transfer; looking carefully at CRC fields we note that the two HDL6 bursts carry exactly the same datagram: maybe the destination station requested a retransmission (the first BW1 ACK burst) or the datagram is sent twice so to improve the reliability of the transfer (Fig. 2a):

Fig. 2a
That said, we can focus on the Extended Data packets (below termed only "packets") of a single BW2 burst (Fig. 2b).
The values of the six Packet Number fields are: 0,1,2,3,0,1. If TxDatagram buffer is not completely emptied the remaining packet positions are filled with repetitions of packets already residing in other positions of TxFrame buffer. The HDL transmitter is at liberty to select packets from the current datagram to repeat as it pleases (the HDL receiver shall inspect the sequence number of each packet received without errors,and use this information to discard duplicate packets).
The original datagram, in this sample, is then composed of the packets #0 #1 #2 #3.

Fig. 2b
Looking at the Packet Byte Count fields in the first four packets (Fig. 2c) we see that the firts three packets carry 233 bytes of user data (as expected, since HDL) and the last packet carries 224 bytes of user data (the remaining 9 bytes are filled with "0" value bytes).
Thus, the length of the original datagram is (233 x 3 ) + 224 = 923 bytes. 

Fig. 2c
Back to the whole bitstream, once structured in a 1920-bit period (the Extended Data packet length), the original datagram can be extracted by isolating the firts 4 rows and removing the overhead bytes: the resulting is an HARRIS "Citadel" encrypted file of 923 bytes length (Fig. 3).

Fig. 3
The duplicated HDL6 burst (A,B), the retransmitted packets (C,D) and the "0" value bytes filling a single packet can be noted looking at the whole bitstream in Figure 4. 
Please note as the bitstream is misleading: at a superficial glance, one could think to four "Citadel" encrypted files!

Fig. 4

13 July 2017

a burst ARQ mixed system (MS110 & S4539)

transmission was spotted only once on 7906.0 KHz from 0603 UTC (tune time) until 0639 (signal off). It's a burst ARQ system in which one station uses STANAG-4539 and the other one uses MIL 188-110A, both running at fixed data rates (respectively4800 and 2400 bps) and carrying STANAG-5066 frames. 
Difficult to say who sends data and who send ACKs. Only the Stanag-4539 bursts have a relative good quality for their analysis (Figs. 1,2): these bursts in large part carry STANAG-5066 DTS control frames (D_PDU type 6) so the station that uses 188-110A could be the data sender, although their duration is very short. Most likely it's a test transmission.

Fig. 1 - frame structure of STANAG-4539 bursts
Fig. 2 - 287 symbols period of STANAG-4539 bursts
Since the different framings of MS110A and S4539, the two stations could use a "special" adhoc configuration or a sort of two-demodulation requirement so to discriminate the incoming signals.

It's worth noting that in many D_PDUs (S4539 bursts) the address of the destination node belongs to the block assigned to France (006.014.yyy.zzz) while the source address belongs to a reserved block (015.xxx.yyy.zzz).

Fig. 3

7 July 2017

STANAG-4538, optimized Asynchronous FLSU call ?

I copied these 3G-HF transmissions very often and, since the "extended" duration of the first burst, I always thinked to Asynchronous FLSU calls; but, apart from the un-expected ending BW5 burst, a careful examination of the first burst in some cases may reserve an interesting aspect as in the present sample.

Asynchronous FLSU calls consist of a sequence of Async_FLSU_Req PDUs sent consecutively on the channel: FLSU protocol use burst waveform 5 so an Async FLSU call can be easily detected in the ACF output screen just thanks to the BW5 spikes (Figs. 1,2).

Fig. 1 - BW5 timing
Fig. 2 - ACF output of an asynchronous FLSU request
Analyzing the recording in question, my analysis tool reveals only one initial BW5 burst, instead of the expected n-bursts (!), which is then followed by a block consisting of 2400Bd PSK-8 modulated symbols. I had a look at the on-air symbols and found that they have a 768-bit period length which corresponds to 256 PSK-8 symbols (Fig. 3).

Fig. 3
BW5 uses a Psuedo Noise spreading sequence that is generated using a table that just contains 256 values [S-4538 #13.9.6] thus the whole first burst match the BW5 waveform (also note the repeated patterns that characterize the bitstream).

Looking at the BW5 timing (Figure 1) and the ACF output screen of the signal (Fig. 4), it seems that the TLC (Transmit Level Control) section is sent only in the first BW5 burst while the following bursts are a bit shorter and consist only of the preamble and data sections, as shown in Figure 5.

Fig. 4
Fig. 5 - the Async FLSU request in question
This is in contrast with what I seen so far in Async FLSU requests in which the BW5 bursts are contiguously transmitted, each with its own TLC section (Figs. 2,6) 
Fig. 6 - ASsync FLSU request as depicted in STANAG-4538
Indeed, STANAG-4538 does not specify this point "The Asynchronous call begins with the LBT (for at least one dwell period), followed by the transmission of about 1.35N Async_FLSU_Request PDUs on the requested link frequency, where N is the number of channels in the scan list, and 1.35 is the duration of each dwell (in seconds)." [STANAG-4538 #5.1.3].

The initial TLC section is used for transmitter level control and receiver AGC settling [1], thus sending TLC sections in contiguous BWn bursts make a poor sense: it's my guess that probably the removal of the redundant TLCs is an optimized implementation adopted by this manufacturer.
By the way, my analysis tool fails because most likely uses a burst-duration approach in order to identify the waveform.

[1] Johnson, Koski, Furman, Jorgenson, "Third Generation and Wideband HF Radio Communications"
Existing HF radios were generally not designed with burst waveforms in mind. For example, MIL-STD- 188-141 military radios are allowed 25 ms to reach full transmit power after keying. While the transmitter radio frequency stages are ramping up, the input audio signal level is adjusted by a transmit level control (TLC) loop so that it fully modulates the transmit power. At the receiver, an automatic gain control (AGC) loop must also adjust to a new receive signal. To accommodate these characteristics of existing radios, the 3G burst waveforms begin with a TLC section of “throwaway” 8-ary PSK symbols that are passed through the system while the transmitter’s and receiver’s level control loops stabilize. 

5 July 2017

unid STANAG-5066 RCOP/UDOP client, Swedish Army (update-1)

[ previous post ]
A recent copy of S-5066 transmissions exhibits a change of paradigm in the so-termed "wrapper" protocol (depicted in the previous post), more precisely the content length of the header Timestamp is reduced from 10 to 9 bytes: 

Fig. 1
Most likely the change happened in coincidence with the reset of the timestamp, ie on 2 July 00:00:00 UTC as can be deduced from a simple calculation (time and date of reception has been taken as the starting date!) and the exposed timestamp (296595868):

Fig. 2
Other than a RCOP new transfer (the above copies regard UDOP protocol), we have also to wait for a capture of a multi-block transmissions to verify if the MTU too is changed.
Note that the copied transmission also offers the opportunity to see the new magic string "ZXPBG", so far never encountered.

For what concerns the source/destination IDs, I could find a possible clue about "HWK01".
Sweden Air Defense Regiment has two air defence battalions equipped with Robotsystem 70 (RBS 70) and Robotsystem 97 (RBS 97): 
Recently, defence and security company SAAB has signed a contract with the Swedish Defence Materiel Administration (FMV) for a service life extension of the RBS 97 air defence missile system, this order ensures the continuing effectiveness of a missile system that is the backbone of Sweden's two air defence battalions:
The RBS 97 is a surface-to-air missile system that is better known as "HAWK", then  it could be that HWK01 = HAWK 01 = Air Defence Battalion 1.

(to be continued)

1 July 2017


08195.0: BU4: Roumenian Police Bucuresti #4, ROU 0624 USB MIL 188-141A handshake 1PY followed by MIL 188-110A (30Jun17) (AAI)
07665.0: ---: Unid 0605 USB 3G-HF FLSU 2-way handshake followed by LDL128 transfer of 451 bytes Citadel encrypted msg (30Jun17) (AAI)
11421.0: ---: Unid prob. V22 Chinese Intel/Diplo 1520 BPSK 62.5 Bd, 9-bit ACF (29Jun17) (AAI)
06358.5: XSA: GBR-DHFCS, U 1517 USB MIL 188-141A sounding (29Jun17) (AAI)
08303.0: IDR: Italian Navy S.Rosa Rome, I 0824 J3E/USB working ASV, STANAG-4285 600bps/L KG-84 encrypton (29Jun17) (AAI)
07561.5: ---: Unid 0809 USB USB MIL 188-141A handshake in Linking Protection mode followed by MIL 188-110A (29Jun17) (AAI)
07559.0: ---: Unid 0715 USB 3G-HF FLSU 2-way handshake followed by LDL320 transfer of 591 bytes Citadel encrypted msg (29Jun17) (AAI)
07840.0: RD21: Algerian Military, ALG 0623 USB MIL 188-141A call NX20 (29Jun17) (AAI)
11130.0: X44: Moroccan Army, MRC 0535 USB MIL 188-141A sounding (29Jun17) (AAI)
08025.0: 1PYC3: Roumenian Police, ROU 0630 USB MIL 188-141A call GALc3 (28Jun17) (AAI)
07899.0: XS72: Unid 0610 USB MIL 188-141A call XN40 (28Jun17) (AAI)
07899.0: XS72: Unid 0556 USB MIL 188-141A handshake XS69 followed by unid vocoder/scrambler (28Jun17) (AAI)
11050.0: AI1: Unid 0845 USB MIL 188-141A call RE1 (25Jun17) (AAI)
11050.0: AI1: Unid 0842 USB MIL 188-141A call RF1 (25Jun17) (AAI)
10958.0: ---: Unid 1359 USB 3G-HF 1-way FLSU request followed by MDL/LDL288 transfer of 563 Citadel encrypted msg (24Jun17) (AAI)
11050.0: AI1: Unid 1313 USB MIL 188-141A handshake XV1 followed by MIL 188-110A serial (23Jun17) (AAI)
11250.0: MATHILDE: Unid French Air Force asset, F 0935 USB MIL 188-141A LQA Exchange w/EVI same QRGs as 0935 log (23Jun17) (AAI)
11250.0: EVI: French Air Force Istres, F 0935 USB MIL 188-141A call MATHILDE, repeated on 11187,11214, 11217, 11235,11250, and 11253. -80dB in JN52 (23Jun17) (AAI)
08218.0: ---: Unid 0716 USB 3G-HF 2-way FLSU handshake followed by LDL32 transfer of 139 Citadel encrypted msg (23Jun17) (AAI)
08350.0: ---: Unid 0711 USB 3G-HF 2-way FLSU LQA exchange (23Jun17) (AAI)
06255.7: HWK01: Swedish Armed Forces, S 0647 USB 3G-HF 1-way FLSU call followed by MIL 188-110A Circuit Mode carrying unid S-5066 UDOP client (23Jun17) (AAI)
10170.0: ---: Russian Mil/Gov, RUS 0540 CIS-VFT/3x100Bd/1440Hz (23Jun17) (AAI)
11111.0: 1OMFUM: French Navy OMAR Net, Papeete OCE 0455 USB MIL 188-141A call 1OMFUJ French Navy OMAR Net, Noumea NCL  (23Jun17) (AAI)
07500.0: SZ1: Unid 1245 USB MIL 188-141A call ND1 (21Jun17) (AAI)
07505.8: XLA: French Armed Forces, F 0632 USB MIL 188-141A handshake XLB followed THALES HFXL modem running on 12 channels (21Jun17) (AAI)
10330.0: 920007: Unid 2126 USB MIL 188-141A call 920001 (20Jun17) (AAI)
10425.0: SWI: Unid 2050 USB MIL 188-141A call SDS (20Jun17) (AAI)
10915.0: 105004: Unid 2034 USB MIL 188-141A sounding (20Jun17) (AAI)
10914.5: GWD111: Brasilian Navy unid vessel, B 2029 USB MIL 188-141A call GWPWZ33 (20Jun17) (AAI)
10390.0: 1304: Moroccan Civil Protection, MRC 2020 USB MIL 188-141A sounding (20Jun17) (AAI)
11340.0: 400001: Unid Mauretanian net, MTN 2015 USB MIL 188-141A call 400010 (20Jun17) (AAI)
11010.0: GWPWZ33: Brasilian Navy HQ Rio de Janeiro, B 2009 USB MIL 188-141A call GWPWSP Almirante Sabóia – G25 (20Jun17) (AAI)
06903.0: WI3 Polish Military, POL 0629 USB MIL 188-141A call AV5 (20Jun17) (AAI)
06903.0: TO9 Polish Military, POL 0626 USB MIL 188-141A call HU1 (20Jun17) (AAI)
06903.0: RO2 Polish Military, POL 0626 USB MIL 188-141A call AV5 (20Jun17) (AAI)
10390.0: 1325: Moroccan Civil Protection, MRC 2212 USB MIL 188-141A sounding (19Jun17) (AAI)
06906.0: 5003: Unid 0537 USB MIL 188-141A sounding (19Jun17) (AAI)
05731.0: E06: Russian Intel, RUS 2132 J3E/USB male voice repeating 315 then into 5FGs (16Jun17) (AAI)
08118.5: D02: Dutch Military, HOL 0754 USB MIL 188-141A call D12 (14Jun17) (AAI)
10900.0: VIR: Unid 0720 USB MIL 188-141A LQA exchange w/ PAA (14Jun17) (AAI)
11186.0: ---: Unid 0715 USB 3G-HF 2-way FLSU handshake followed by HDL3 transfer (14Jun17) (AAI)
11002.0: VIR: Unid 0710 USB MIL 188-141A LQA exchange w/ PAA (14Jun17) (AAI)
07457.0: ---: Unid 0624 USB MIL 188-110 Appendix B OFDM 39-tone followed by short Arabic voice comms (14Jun17) (AAI)
08224.0: ---: Unid 0617 USB HARRIS Autolink-I waveform (14Jun17) (AAI)
07860.0: RD21: Algerian Military, ALG 0602 USB MIL 188-141A call NX20 (13Jun17) (AAI)
06956.5: ---: Unid 0504 USB (offset 1500Hz) R&S ALIS 228Bd/170 calling 220 (13Jun17) (AAI)