The Latest
Microwave step attenuator
Posted by AG6QV Frank

While searching through eBay listings I came across a step attenuator that was listed aa 0-50 dB in 10 dB steps attenuator, and good for DC to 18 GHz. It was recently priced so I decided to spring for it. When it arrived I started to research the origin. It turned out to be from an old HP 8555 spectrum analyzer. Most likely a unit no longer working, but the attenuator was advertised as tested. I found a users/service manual that described the operation and the voltages needed to activate the solenoids. It looked to be simple as it was using 12V solenoids. The attenuator has three solenoids that are used to enable/disable 3 different attenuators in series. After putting the attenuator on the test bench I confirmed that all 3 was working and providing 10, 20 and 40 dB attenuation respectively. So the range is 0-70 dB and not as the specs for the HP 8555 analyzer listed (0-50 db). In the spectrum analyzer the attenuator is placed between the N connector on the front panel and the mixer and can handle +33 dBm or 2W maximum. Good for many microwave applications.

With the information about how the attenuator is operated and the knowledge that all 3 stages was working as expected I started designing the control unit. The first step was to decide how to generate the voltage needed for each of the three solenoids. In order to engage the solenoid the two terminals needed a +12V pulse for 150 ms and in order to switch it back the polarization of the pulse should change ro -12V for 150 ms. This can be achieved with an H-bridge. This is basically 4 transistors configured to have 2 inputs and two outputs. This will allow a positive voltage when the input is high and low and a negative output when the inputs are low and high. In addition there would be no voltage across the outputs if both inputs are low. H-bridges are commonly known to drive DC motors, allowing them to turn in both directions depending on the voltage being positive or negative. Amazon is selling a package of 4 H-bridge modules based on the L298N chip for just $10. It would not make sense to try to build one from scratch at those prices. The module provides 5V input logic and 12V output, exactly what's needed to use an Arduino Nano as the controller.

With the parts ordered I designed a 3D printed enclosure that could be glued on to the side of the attenuator, covering the terminals for the solenoids and providing push buttons to change the attenuation up and down and a display to show the current value. Since the solenoids are latching it's possible to connect the power, set the desired attenuation and then disconnect the power. That way there will be no noise from the Arduino board while the attenuator is in use. I also made the code to set the default attenuation to 70 dB when the unit is powered up. This is needed to set the highest attenuation but also because it's not possible to read the current value/state of the each attenuator. Bringing them to a default value makes sense.

The finished attenuator and control box all assembled.

The inside of the control unit showing the two H-bridge boards on the left and the Arduino Nano on the right. I placed the Arduino nano on an breakout board that allow for 12V power input and easy access to the pins needed to control the H-bridges and the two input buttons.

And finally the unit with power applied. The small display is a 128*32 pixel OLED display with a I2C interface. When power is applied it will show my call sign and then set the attenuator to 70 dB.


Here are links to the Arduino sketch and the 3D stl file.


HackRF One - 5 band beacon
Posted by AG6QV Frank

Radio Beacons are used in HAM radio to test propagation. If you are able to receive a beacon on a given frequency you might also be able to make contacts with stations in the same area as the beacon, and on frequencies close by. Beacons can also be used to test antenna and receiver performances. Setting up test beacons for one or many HAM radio bands can be a large task. With HackRF One and Software Defined Radio (SDR) it can be a much easier task.

I have created a simple flowgraph that can select between 5 preconfigured frequencies on 6m, 2m, 70cm, 33cm, and 23cm. The flowgraph also includes a variable to define the beacon message. The message is a series of characters that will be translated into morse code when the program is launched.

Translation into morse code required the use of a custom block in GNU Radio Companion. Custom blocks can be written in Python and are relatively simple to get custom functionality into the flowgraph.

The image below shows the flowgraph with variables on the top and the logic at the bottom. I included a frequency sink to show where the signal is when the different frequencies are selected and to visualize the CW code.


The next image is a screenshot of the application running. The maximum output of HackRF One is 10-15dbm or 10-25mW so a small amplifier and an external antenna might help. In addition a valid HAM radio license is required to transmit any signal in the HAM bands.


Download the flowchart.

Update:

I made a new version of the flowchart for the multiband beacon. It now operates on 6 bands: 6m, 2m, 1.25m, 70cm, 33cm, 23cm. It can work on any number of bands/frequencies where each frequency is defined as an element in an array within the custom block that generates the CW code. It will automatically switch to the next band after completing a full transmission of the CW message.


RackRF One Signal Generator
Posted by AG6QV Frank

Signal Generators are important tools to test HAM radio equipment. A very simple version that can generate 4 different carriers in some of the HAM radio bands is used to illustrate the possibilities of the HackRF One and other SDR systems.

First step is to set up a few variables within GNU Radio Companion. When a new project is created there is one variable provided called samp_rate. This is used to define the sample rates used for the DA/AD converters in the SDR. HackRF One operates with sample rates between 1 and 20 million in steps of 1 million.

In this example there are two additional variables added. The first one is to set the drive or output level. This is created as a variable called drive with a min and max value of 0 and 1 respectively. The UI element is a knob, but there are several other ways to control the values of any variable from the GUI. For the frequency I chose a radio button style with 4 available options, one for each band and coded the frequencies tbe 50.1MHz (6m), 144.1MHZ (2m), 432.100 (70cm) and 1296.1MHZ (23cm). Having a simple input to enter the exact frequency is another option.

The two active component is the Constant Source used to generate the RF signal and the Soapy HackRF Sink to communicate with the hardware to generate the signal. In more advanced systems the source could be generated from audio files or a microphone input to allow transmission of a real signal.

When the application is running it will generate an application as shown below:

A copy of the GNU Radio Companion project file can be downloaded here.

To test the system I used my HT to listen to one of the 4 frequencies, turn up the drive until the signal was received. The maximum output power of the HackRF One device is in the range of 0-15dBm depending on the frequency selected.


Recent Blog Posts
    Calendar
    January 2025
    SuMoTuWeThFrSa
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31