How Are PCB’s Made?

There are about 10 working days between finishing the PCB design in Eagle and the reception of the finished product at my doorstep. I have always wondered how the Sontheimer bridge PCB and the A4988 PCB were manufactured.

Scotty Allen from Strange Parts went on a factory tour and made a pretty extensive video about the production process of a PCB. If you have 26 minutes of time, check out his youtube video below. (If you have less time you can fast forward some parts πŸ˜‰ )

Automatic Magnetic Loop Tuner – Another Soldering Session

I took some time to solder another PCB for an Automatic Magnetic Loop Tuner. I made some pictures of the final result which I would like to share with you.

This is a view from the top of a populated PCB. The Teensy 3.2 and the A4988 stepper module are not yet installed. This loop controller won’t need the end stop feature. Therefor D2, D3, R25, R26, C19, C20, C21, C22, T3 and the 3 pin header for the end stop connector, are not installed.

C1 is located underneath the Teensy 3.2. This capacitor can be soldered upright. There is plenty of space, so no need to lay it flat on the board.

Populated PCB for Automatic Magnetic Loop Tuner

Here we have both the Teensy 3.2 and the A4988 stepper module installed. Note that a jumper is placed over JP1, but that JP2 is left open. JP1 connects “Sleep” and “Reset”. JP2 is for future use. When using a DRV8825 stepper module it gives us the possibility to connect the unused Teensy 3.2 pin 19 with pin MS3 of the DRV8825. With some additional programming to the software, this could enable the 1/32 step stepper resolution. This however has not yet been programmer, nor tested.

Populated PCB for Automatic Magnetic Loop Tuner

If there is one thing I would change to this board it’s the re-positioning of the LM7805 voltage regulator. The ground plane in facing inward which makes it difficult to attach a heat-sink. This can be solved easily by bending the legs of the LM7805 so the ground will face upwards, or by connecting it from the underside of the PCB and connecting the ground to the metal enclosure the whole PCB will be put in.

Populated PCB for Automatic Magnetic Loop Tuner

On this last picture, you can see capacitor C1 has plenty of space and is enjoying the company and security of the Teensy 3.2 πŸ˜‰

Populated PCB for Automatic Magnetic Loop Tuner

Automatic Magnetic Loop Tuner – Printed Circuit Board (PCB)

Using the original schematic as a starting point, I reworked the electrical diagram and incorporated an A4988/DRV8825 module.

You can download a pdf file of the reworked schematic here: MagLoopTuner.pdf

Automatic magnetic loop controller PCB

The two jumpers in the schematic deserve a little explanation:
JP1 connects the sleep and reset pins of the A4988/DRV8825 module board. I’ve seen schematics where these pins are soldered together, but I preferred to use a jumper. This way you have the possibility to add a reset switch, or if you think it’s not needed, just bridge the two contacts.
JP2 was incorporated for future use. It connects the unused pin 19 of the Teensy 3.2 with pin MS3 of the A4988/DRV8825 module. Without this connection, the maximum resolution of the magnetic loop controller is a 1/8th step. With some extra coding, we could drive the stepper motor as precise as 1/16th step (with the A4988) or even 1/32th step (with the DRV8825). This coding is not yet done, and I’m also not sure if this fine stepping is useful for this project, but I thought it was a nice idea to experiment with it. So for now, you can leave JP2 open.

If you are not using end-stop switches, then there is no need for D2, D3, R25, R26, C19, C20, C21, C22 and T3.

Depending on the type or brand of the rotary encoder, the A or B phase can be reversed. However, VCC and G must always be respected. You can check the correct wiring of A and B when you scroll through the menu. Turning the rotary encoder clockwise must increase the menu option, the steps and the frequency. When this is correctly done, you can start checking the wiring of the stepper motor. In order for the backlash and auto-tune function to work correctly, the capacity must go down when you turn the rotary encoder clockwise.

Don’t need the SWR / power meter function? Then you don’t need R15, R16, R17, R18, C25, C26 and R20, R21 and R22 (and their corresponding switches) either.

Please check Loftur’s project page for a more detailed explanation, the BOM and building instructions:

For any inquiries or questions about the PCB, please send an email to Add my email address in your contacts to prevent my response email from landing in your spam folder.

Automatic Magnetic Loop Tuner – A4975STB, A4988 or DRV8825

The design Loftur published on the project site was built around two A4975SBT ic’s. Although they are available at they are rather expensive if you only need 2. even doesn’t have them in stock. When you need more of them to build multiple automatic magnetic loop tuners, you could start looking for them on AliExpress. A starting seller (who needs good reviews for credibility) will offer you 10 pieces for less than 12 euro. They have a 1,5 A continuous output current and have a step sequencing from 1 full step until an eighth of a step. When you are using a multi-turn variable vacuum capacitor or any capacitor connected to a geared motor, this will do just fine.

Allegro A4975SBT
Allegro A4975SBT.

If the steering cable is too long, and its resistance is becoming too high, you need to provide more than 1,5 A so your motor would still receive enough current to generate sufficient torque for turning the capacitor. Depending on the type of capacitor, you might need more than 1/8 of a micro-step. In both cases, you should look out for something more powerful or precise than the A4975STB. Two alternative stepper driver modules are the A4988 or the DRV8825. On top of being more precise and/or more powerful, they are easier to find and a lot cheaper than two A4975STB. Just like with the NEMA 17 stepper motors, these modules are widely used in all kinds of 3D printers and DIY CNC machines. There are plenty of suppliers on AliExpress, offering them for prices close to one euro.

The A4988 is capable to deliver 1A per phase without a heat sink or forced airflow and is rated for 2A per coil with sufficient additional cooling. On top of all kinds of over- and under-protection intelligence (voltage, temperature, current, crossover-current, short-to-ground and shorted-load) it features five different step resolutions: full-step, half-step, quarter-step, eighth-step, and sixteenth-step.

A4988 stepper module
A4988 stepper module.

The DRV8825 has a pinout and interface that are nearly identical to those of the A4988 stepper driver module, so it can be used as a higher-performance drop-in replacement for those modules in our automatic magnetic loop tuner. It can deliver up to approximately 1.5 A per phase without a heat sink or forced air flow and is rated for up to 2.2 A per coil with sufficient additional cooling.

DRV8825 stepper module.

It will not sound as a surprise to you when I tell you these two modules don’t fit in the original PCB layout Loftur designed. Joerg, a user in the loop controller yahoo group found a solution for that and made an adapter board to use an A4988 or DRV8825 module with Loftur’s print.

Joerg made me realise it wouldn’t be too difficult to adapt the original design and make a new PCB especially for the A4988 or DRV8825 stepper driver modules. After some hours redrawing the schematics and moving around the components I came up with the following PCB design.

Automatic magnetic loop controller PCB

It’s 67mm x 100mm and features besides the space for an A4988 or DRV8825 module, 3 (T1, T2 and T3) 2.2 A common mode chokes (CMS1-8-R). Loftur proposed these chokes as an upgrade for the 1 A common mode chokes of Wurth Electronics (744227S) originally used in his first design.

Automatic Magnetic Loop Tuner – Rotary Encoder

The rotary encoder is the most expensive part of the automatic magnetic loop tuner. It’s a little more expensive than the Teensy 3.2. Those of Bourns cost around 23,21 euro VAT excl. for the 64 ppr version without an incorporated push button. 64 ppr is the lowest resolution you should look for. If you go lower than 64 ppr you’ll have to turn around the encoder many times before you get to the desired stepper position for the right capacity.

Bourns EM14A0D-B28-L064N rotary encoder

You could always look for rotary encoders with a higher resolution. In the software, you can define how many pulses need to pass before the stepper motor makes a micro-step.
// File: ML.h
// Definitions for Rotary Encoder and Pushbuttons
#define ENC_MENURESDIVIDE 8 // Encoder resolution reduction when in Menu;
#define ENC_TUNERESDIVIDE 1 // Encoder resolution reduction when turning;

The ENC_MENURESDIVIDE variable is used to limit the scrolling speed in the menus. When using a 128 ppr encoder, use 16, with a 64 ppr encoder choose 8.
The ENC_TUNERESDIVIDE variable is used to determine the stepper motor response. When using a 128 ppr encoder use 2, with a 64 ppr encoder use 1.

This translates into the following: one full (360Β°) turn of the rotary encoder results in 8 menu steps or 64 micro-steps.

On AliExpress you can find 400 ppr rotary encoders for less than 10 euro. Since we know our math, we only need to changes the ENC_MENURESDIVIDE and ENC_TUNERESDIVIDE variables to respectively 50 and 6 (or 7), to use this cheaper alternative. These 400 ppr rotary encoders are a lot bigger than the 64 ppr Bourns rotary encoders. Functionally they will do just fine, but you need to take into account the extra space that the rotary encoder will occupy in your project box.

400 ppr rotary encoder bought on AliExpress

Today also 100 ppr versions are available, like this one:Β
If you use the 100 ppr version, you don’t need to change any code.

Automatic Magnetic Loop Tuner – Region 1 SSB Field day

CQ field day, CQ field day, this is ON5IA/P.

The proof of the pudding is in the eating, as they say, so what better way to test the Automatic Magnetic Loop Tuner than to participate in a field day?

The weather forecasts looked promising so I decided to subscribe myself for the Region 1 SSB field day of September 2017. The rules for the field day are simple: you’ll have to set up a portable station, and you can only start with the setup 24 hours before the beginning of the contest. In our case, we didn’t even need that much time. One hour before the contest, we unloaded the magnetic loops and installed them. A thick plastic tube was hammered in the grass, and the magnetic loop foot was shoved into it. We attached the coax- and the stepper motor steering-cable, hooked them to the radio, attached the batteries and we were QRV. There were still 30 minutes left before the start of the contest.

After configuring the automatic magnetic loop tuner, we still had 25 minutes left HI HI.

As we wanted to test the automatic tuning capabilities of our tuner, we actually never called CQ. Fixing yourself to one frequency and calling CQ for an hour will not learn you anything with regards to the automatic tuning possibilities, of the loop controller. Instead, we started at the bottom of the band and scrolled up until we reached the first OM calling CQ. When the contact was made and the signal report and numbers were exchanged, we moved to the next OM. When we reached the top of the band, we scrolled down again and picked all the stations we didn’t hear the first pass.
As time passed, band conditions changed. When we moved up and down twice, we switched band. We applied the same tactics on each band. It’s not a great contest tactic, but we did not participate in the field day to win the first price but to test our automatic magnetic loop tuner. The tuner did a fabulous job. We only had a hiccup once, when the mechanical coupling between the stepper motor and the capacitor broke loose.

We subscribed to the 12 hours open all band category, so we were obliged to take our times off. Here again, we didn’t plan them tactically to win the contest but to strengthen our inner man. We had a tasty BBQ and a great sleep. Next day we continued our testing. When we reached 120 contacts our pre-printed logbook was full and we called it a day. 45 minutes later, everything was packed as if the field day never took place.

When I entered the log, it became clear we were short in the number of QSO and multipliers. We ended up on the 5th place of five…

But these were only the claimed scores!

When the final results were known, we moved up two places to the 3rd place. Yeah, that’s a bronze medal.

I found it remarkable that some stations lost so many claimed QSO’s so I started to calculate the ratio between claimed and final scores.
BOOOM, the gold medal for ON5IA/P!

With correctness of 96,67%, we had the best claimed/final-ratio. This can be understood in two ways: 1 we are superb operators, or 2 our magnetic loop antennas gave us the big advantage of having less QRM and better readability.
Let’s assume the second option πŸ˜‰

This test made me conclude that the magnetic loop antenna is indeed a very good antenna if you don’t have a lot of space in your garden to put up a big tower, or if you live in an environment with a lot of QRM. You can have as much fun as all other OM’s and you don’t even need to skip the contests. That is if you have a solution for the biggest drawback of the magnetic loop antenna: it’s small bandwidth due to the high Q factor. And we have this solution: the automatic magnetic loop tuner!

Automatic Magnetic Loop Tuner – First QSO

On the 15th of March 2017, we were ready to test our final product. The Automatic Magnetic Loop Tuner was fully assembled, programmed and connected to the antenna and transceiver. Time to turn the VFO around and see if we can make some contacts.

Imagine the following situation: 15th of March 2017, 21:00 UCT, 20m band, no sunspots that day. One OM is alone in the workplace, the other OM is getting some stuff from the shack elsewhere in the house. When the second OM returns to the workplace, the first OM tells him he made a contact with K2GAV, Theodor from Connecticut, 5800 km away from their location. The signal report was 57

On top of that, the antenna setup is the one from the picture below. Inside the workplace, 1m apart from an aluminium garage door, steel beams in the roof.

Magnetic Loop And Automatic Magnetic Loop Tuner

I don’t have to explain to you the disbelieve of the second OM, who immediately grabs the mike and calls for K2GAV. K2GAV returns but the signal is getting weaker. A new contact is made, however this time with a report of 56. This antenna setup, the timing and the conditions were all but ideal, yet we managed to make a DX contact! This proves that the Magnetic Loop antenna is an ideal antenna for people with little space to put a big antenna. You don’t need to say your favourite hobby goodbye if you have to move to an apartment.

Long live the magnetic loop antenna and the Automatic Magnetic Loop Tuner!