Over and Out

It is with intense sadness that we announce that ZL4SAE/GW4SAE is now a Silent Key. Derwyn passed away, peacefully at home in New Zealand on 9th April 2019.

Thank you for supporting his blog, we know how much he enjoyed sharing his knowledge and discussing his passions with like minded enthusiasts.

The blog will remain online in his memory.

ZL4SAE Over and Out

A Mini HF Superhet Receiver for SSB

Mini HF Receiver


I have simplified the schematic by removing the transformers, as these may be difficult to source. The tuned circuit following the mixer will need to be peaked at 9MHz. Also removed the phase splitter that was driving the noise filter. This is now single ended, but seems to work OK.

The receiver was constructed on a single PCB using a mixture of techniques. The filters are mounted beneath the board with the remaining circuitry above. The TEENSY 3.2 controller is mounted on the rear of the front panel alongside the keypad and the AD9851 DDS. The controller circuitry is shielded.

The case is an ex-military PRC-351 shell. The handles just look nice.

Tuning is accomplished by ‘scanning’ the band in 1kHz steps, started and stopped from the keypad. The larger of the 2 knobs then allows fine tuning. Pressing the knob selects coarser steps for manual tuning.

The program ‘remembers’ the current frequency when changing bands and on return, that frequency is restored. This function does not survive a power cycle as it is in software and the EEPROM is not used.

Listening on 20m on my 35ft vertical, signals from Europe were heard here in NZ on the first evening of testing. None of these signals were particularly strong, but certainly readable. Maybe a pre-amp would help.

The mini HF Superhet main schematic.

The circuit consists of a Bandpass filter for each band, diode switched by the processor. These are followed by a level 7 diode ring mixer. The common gate FET amplifier is impedance matched to the AM bandwidth roofing filter by the tapping on the tuned winding. The post filter amplifier is a rugged MMIC the GPD202. The SSB filters are relay selected by the TEENSY 3.2 processor on a ‘per band’ basis. The filters were salvaged from the very popular KVN SSB board, available on eBay and a number of other places. See an earlier post for circuit details.

The product detector receives the I/F signal via the noise filter crystals. The output drives the audio preamp, and the single ended output drives the power amplifier. I have made an effort at impedance matching and noise reduction between these 2 stages. The LM380 can deliver 1W into 8 Ohms with some distortion, but is an order of magnitude improvement on the LM386.


The Bandpass Filters

The diode in each of the band-switch circuits serve to isolate the diode switching voltage from the TEENSY. The FET acts as a source follower, providing a few volts to the diodes. As long as the forward voltage drop of the BPF diodes is exceeded the diodes will switch the appropriate filter into circuit. The 220R resistors simply limit the forward current to a safe value. In this case around 10mA.


The Digital VFO and controller

This part of the radio took up most of my time. Between design, build, program and test I spent a few weeks here. The time spent was further extended when I burned out the original TEENSY controller and had to order a replacement. I’m not sure that the level converter is really needed, but once bitten ……

The AD9851 was available after being ‘rescued’ from a previous project. Due to there being insufficient drive for the diode SBL-1 mixer, I used a MMIC to amplify the VFO signal. This is followed by a low pass filter, as the DDS is not know for the cleanest signals. However, in use it performs very well.


The control software

The software was written in the Arduino IDE and downloaded to the processor in the usual way. The main DDS routines appear to be available from many places on the internet and I make no claims for originality here. The number of libraries has been kept to a minimum. Some functions have not been implemented at this time and the software is offered ‘as is’ with plenty of room for improvements and additions.

The .INO sketch is included here as a WORD text file, as WordPress would not allow the .INO file type. Probably for security reasons.


I suggest you cut and paste the text into the Arduino IDE in order to restore the original format.

The button functions that I have used or suggested, appear on the main schematic.

Any further suggestions or improvements are welcome. gw4sae at aol dot com

Hakko 907 soldering station controller for 12v DC

A temperature controller for Hakko and clones.

I have had a couple of problems in the latter part of 2017, which have prevented me updating my radio projects. Of major concern was a selection of leaky FETs that I purchased on eBay some time ago. These are 2N7000, a popular switching device. I used them in a level converter circuit, between my Teensy 3.1 controller and my 4 band receive filter board. The devices were ‘leaky’ and 12 volts got back to the Teensy pins and damaged them. I ordered a couple of Teensy 3.2 from Paul and the service was excellent. They arrived in NZ within 48hrs. NZ post are not so hot. They took 18 days to clear my shipment and deliver the parts.

While removing the original Teensy, my soldering iron cooled and refused to heat up any more. I have had this Hakko clone for almost 5 years so I fully expected the tool to have failed. A little investigating and the iron itself was ruled out. I traced the fault to the LM324 quad op-amp. I removed it using a 240 ac soldering poker, and fitted a socket in the board. After plugging in a new op-amp everything worked OK again, and the Teensy was eventually removed. I started to think about a 12v soldering iron as a spare. Then I found a DC-DC boost converter on eBay that would evidently produce 24v at some amps, from a 12v supply. So I ordered a couple. Delivery from Hong Kong to NZ is usually on the order of 4-5 weeks.

On our trip back to our daughters’ home for Christmas we rarely stayed anywhere with the motorhome for more than a couple of days. So the gear was stored away. On arriving at my daughters place in Marton we had mains power, so out came the soldering iron. After suffering another failed LM324 I examined the control board with a magnified headset. I touched up a couple of suspect joints and replaced the op-amp again. All appeared to work OK and it still does.

The 12v idea re-surfaced, and I now had the boost converters. I have a spare Hakko clone and I decided that I would use a simple amplifier/ comparator circuit based on an LM358 dual op-amp. This device is designed for single supply operation. A look in the spares locker revealed some suitable Zener diodes and an IRF640 power FET. The thermistor in the tool measures around 52R at 22°C and around 130R at 500°C. A bit of Ohms law mathematics, and I selected the 2k2 resistor fed from 20v to give me a voltage that varied with temperature from 0.45v at room temp, to 1.2v at 500°C. The feedback resistor and the preset pot, set the gain of the amplifier such that the voltage on pin 6 reaches a maximum of 4.9v. The reference voltage on pin 5 can get to just over 5 volts. This means that in the event that you set the temperature control to maximum, it will not exceed 500°C. Which is pretty hot. The calibration, if you can call it that, is adequate for hobby use. If you have a high temperature probe you can calibrate a scale that fits behind the control knob. I don’t have one. Setting the control to about 3/4 full scale gives me a suitable working temperature. If I need a bit more ‘grunt’ for a heavy terminal or something similar, I can wind it up a little further.

The schematic is a pic. For some reason WordPress could not access my Onedrive account in order to upload the PDF but you can click on this link to obtain it…. hakko_control_schematic

No it didn’t work first time. Well yes it did, but not for long. The ‘heater’ LED came on then flickered when the set temperature was reached. This fast flickering wasn’t too popular with the little switch mode power supply. It failed in less than an hour. I replaced it with the thoughtfully obtained spare, thinking that the first part was faulty when supplied. The flickering was apparent with the second unit. I switched off immediately. My first thought was to add some hysteresis around the op-amp. But that would be guess work as I had no idea how to work out the time constants. I then thought of slugging down the gate of the FET with a few uF of capacitance. By trial and error, 22uF finally gave me a steady LED. I left it running at fairly high temperature for more than an hour. The alloy box gets quite warm, but no other faults showed up.

The circuit is as simple as I could devise, and is built on prototype board. The FET is mounted on an aluminium angle bracket and then bolted to the case as a heatsink. I removed the 5 pin plug and wired the tool directly to the controller. The green anti-static wire is grounded. ( not shown in the schematic ) The thermistor wires are blue and red, the heater wires are black and white. Neither pair are polarity conscious. Your wiring may have a different colour code. A green LED is wired to the circuit side of the switch, and a yellow LED indicates that the heater is powered.

Not the neatest project I’ve built, but it works. I added an inductor in the switched leg of the FET in an attempt to ‘buck’ the pulses of energy drawn from the power supply. I don’t know if it helps but it was available so I tried it and I left it fitted.

KVN SSB Filters used in superhet receiver

KVN Filter PCB. SSB Receiver.
See an earlier post for schematic and details of the Telrad board. Also called the Israel board due to the location of the supplier, I believe.

HF Receiver for SSB.
After 6 months of construction and experimentation I am not really happy with the result of my efforts to create a ‘decent’ receiver from this board. The 1496 mixers are great as product detectors or modulators, but as front end mixers, they leave a lot to be desired. I believe that the whole board was designed to work at higher signal levels than the sub uV signals that we hams are used to listening for.
Furthermore, I really wasn’t too keen on the dual power supply requirement as I only have 12v DC available and the few inverters that I either built or bought were noisy.

Download the PDF Telrad filter SSB receiver


I have removed the filters from one of the boards and used them in the design of a superhet receiver that works fine. Some of the parts I had at hand may not be available to everyone. However, just replace that building block with your favourite circuit. The pic is not quite the same as the schematic. The schematic is up to date. There was excess gain in the receiver, so I have removed the post AM filter amp, and also the audio preamp. I built this receiver into the same case that housed the TELRAD board, along with a second TELRAD board that was the ‘potential transmitter’. I also used the TFT touchscreen display and Si5131 VFO synth, controlled by an Arduino MEGA. Having used a Hybrid Cascode kit for the I/F amplifier, and no audio filtering, the whole thing is a bit more compact than the original design. There are a number of spurious signals emmanating from this setup, and as the screen is being constantly scanned by the Arduino MEGA for touch activity, there is also some noise being generated there. I really like the touch tuning on the screen and fine tuning with the encoder, but basic RF performance outweighs the ‘bells & whistles’ so its back to a ‘quieter’ LCD 2 line display. For a receiver, rather than a transceiver, this means a smaller case is possible.

The size difference is startling. I used a NOS case from a PRC351 ex military VHF transceiver, and it certainly has a military look about it.  I have reduced the band coverage from 9 bands to 4 bands in order to minimise the BPF. I also used the smaller Arduino, the UNO with an AD9851  based DDS. The UNO is overclocked to 28MHz, providing a bit more processing speed than the MEGA. See an earlier entry in my blog for information on overclocking the Arduino.

Update Sept 18-2017   I miscounted the I/O requirements for the control of the receiver by not including the band select lines. I have now decided to use an older Teensy 3.1. This is small and quite fast. It’s 3.3v so I can see further interface problems looming. Oh the joys of homebrewing !!

Main Up/Down tuning will be via the keypad. Fine tuning with the encoder. That leaves just the volume control needed on the front panel. Bandchange is actioned via the keypad with the Teensy programmed for correct mode per frequency. There are a number of spare buttons for extra functions. The rear of the front panel is a shielded box containing the control system and VFO. The back panel holds Anderson power poles and an audio jack. There is a BNC socket for the antenna, mounted in an existing hole in the left side of the case. I will post more details on this mini receiver, along with the schematic, once I have finished building and testing.
It won’t be too much different from the above drawing.

Overclocking the Arduino. UNO & MEGA.

Windows 10 Pro. Panasonic CF-C1 laptop. Arduino 1.8.2. Arduino 1.0.5-r2.

Having the need for a faster processor in order to speed up my touchscreen TFT response, I wondered if it was possible to make the Arduino Mega run with a faster crystal.

Short answer, Yes ! But first …….

A faster UNO.
Imagine my surprise when I discovered that overclocking the Arduino is quite popular. Since I have a spare UNO, and it has a ‘thro hole’ crystal, I decided to experiment with that. This type of Arduino build is the easiest to modify as will become apparent.
I removed the crystal and fitted a 3 pin socket with the centre pin removed. This gives the correct spacing for a HC-49 size crystal can. Experimenting with a couple of odd crystals that I have, I discovered, with some surprise, that the Uno will work OK, up to 28.224MHz. ( this frequency produces meaningful baud rates with integer division) This is the highest frequency fundamental crystal that I have. The crystal needs to be a fundamental type, as the Arduino internal oscillator will not function correctly with an overtone crystal, such as a 27MHz RC type. Which are 9MHz, 3rd harmonic. It will more than likely oscillate at 1/3rd of the Marked frequency. Also, if your UNO has a ceramic resonator ( much more difficult, but not impossible to work with ) you will need to add a ceramic capacitor of 22pF, from each crystal leg to ground. The can type crystal will have these on the Arduino board already.
Arduino IDE Serial monitor is compromised due to the incorrect clock frequency in relation to the baud rate. This can be resolved by editing the ‘boards.txt’ file in the Arduino\hardware\arduino path. Find the entry for UNO. You need to change the build.f_CPU= 16000000L to whatever value your crystal is, 282240000L in my case. Alternatively, create a complete new entry with a unique name, such as ‘Uno_28MHz’. Just cut, paste and edit the existing Uno entry. Rename every parameter including the name entry. The new ‘board’ will appear in the Arduino IDE under the TOOLS menu drop down, after restarting the IDE.
Sketch transfer still needs to be at the original 16MHz, ( hence the socket ) using the original 16MHz UNO board selection and correct COM port. I found this to work without any problems, other than the inconvenience of changing the crystal too often.
Ultimately the sketch can be developed at 16MHz, and the crystal and board selection finally changed when debugging is complete. Then the sketch can be uploaded with the new setup.
The 28.224 MHz crystal experiment would not work in the MEGA !

External Oscillator.
An external ‘canned’ oscillator can also be used as the clock source, but the Arduino ‘fuses’ will need to be programmed in order to tell the processor which clock source to use. The Arduino CANNOT modify its own fuses via the IDE. This will need to be done using an ISP device and a program such as AVRDUDE.EXE. This is not the friendliest utility and a quick search of the internet produced a GUI version called AVRDUDESS, which I find so much easier to use, rather than the command line version.
Download it here ….
Install the software and place a copy of libusb0.dll into the same folder. This dll file is buried inside the Arduino installation.
On my laptop this is at C:\Program Files (x86)\Arduino\hardware\tools\avr\bin\

I had already carefully removed the ceramic resonator from a MEGA clone and fitted a 28MHz crystal and capacitors, I later replaced the crystal with a 22MHz oscillator module. The output of the module connects to Xtal1 on the Atmega 2560 chip. This is the solder pad nearest the Mega I/O terminal strip, and furthest from the chip itself. It is powered from the 5v and GND connections on the Mega that are conveniently nearby.
Not having an ISP programmer I constructed a simple device using an Arduino Pro Mini, running the ArduinoISP sketch that is found in the Arduino EXAMPLES folder. The processor needs to be at least a 328. A UNO or NANO with 328p processor would be suitable of course.
See my previous post for details of a NANO version. The diagram shows the recommended circuit and the connections from the NANO to the Mega, as an example. The LED wiring was the most complicated part of that project.
After uploading the ArduinoISP sketch in the normal way, a 10uF at 10v or more capacitor needs to be fitted between RESET and GND, this prevents the processor from being reset when used as a programmer for the UNO or Mega, or any other device you choose.

The processor fuses that we are interested in are labeled lfuse and hfuse. Meaning low fuse and high fuse. The lfuse contains the bits that need to be changed in order to select the external oscillator as the clock source. The default value appears to be 0xFF. The lower 4 bits and bits 6 and 7, need to be programmed to 0. (The logic is inverted. See the datasheets for more info ) The new value is 0xA0. 1010 0000 in binary. The hfuse is 0xD8 by default and needs no changes.

Do not change any of the other values, it is possible to easily ‘brick, your device. Only a HV programmer can fix this unwanted situation. Beyond the scope of this article.

Connect up the devices and connect the programming board to the PC USB port. Check the COM port number of the ISP in the Arduino ISP TOOLS>PORT.
Using Windows explorer, navigate to the AVRDUDESS install folder and launch the application. In the Programmer drop down, select Arduino as the programming interface. Select the correct COM port from its drop down. Type in the baud rate, 19200 is the default for the ISP. At the top righthand side select the MEGA2560 in the 2 device boxes. This is sufficient information for avrdudess to read your device settings. Click on READ fuses. The program responds in the DOS window, and updates the fuse readings in the GUI. Clicking on CONFIG will allow you to see the individual fuse settings in bit patterns. They can be modified in this screen.
The default hfuse bit pattern is 110110001 = 0xD8
The NEW lfuse bit pattern is 10100000 = 0xC0
Exit the screen. Then write to the device by clicking WRITE in the fuses section.
Avrdudess reports the changes. Clicking on SAVE will remember your settings.

A NEW board.
Create a new MEGA entry in the boards.txt file with a unique name, such as Mega_22. Copy one of the existing entries and edit it. Change the lfuse and hfuse values. Change the build.f_CPU frequency as detailed previously. Save the changes. On restarting the IDE the new board appears in the TOOLS/BOARD drop down. Select it. Select the COM port of the ISP device. The Mega can now be programmed from the Arduino IDE, using the ISP programmer. The crystal does not control the baud rate of the ISP which is fixed at 19200 baud. Connect your newly programmed board to the USB port, and select the correct device and port inside the Arduino IDE TOOLS menu. The IDE serial monitor should work correctly due to the new crystal information in the boards.txt file. You will always need to use the ISP device for programming unless you modify the bootloader. I have not yet managed to do this with the MEGA, but the UNO was a different story………..

UNO Optiboot Bootloader.
In order to be able to program the faster UNO directly from the IDE, without a programmer, the boot loader files will need to be edited to reflect the new oscillator frequency. Then the MAKEFILE will have to be compiled with MAKE to produce a new boot loader hex file. This is straightforward as long as you get all the details correct. It can stretch your patience a little !!

MAKE is not shipped with the latest versions of Arduino. You will need an earlier version such as Arduino-1.0.5-r2, which is still available for download. Unzip this to a separate folder e.g. C:\ArduinoOld. Navigate to the \bootloaders directory and open the \optiboot sub-directory. Open “makefile” in a text editor. Similar to the boards.txt file, make a new entry in this makefile reflecting the changes to CPU speed. Give it a unique name as before, such as FastUNO. You will need a unique name for the bootloader that will be produced, such as FastUNO328.hex. Edit the entry and save the changes. If you have problems here see the footnote on permissions.

Open the Windows command line as Administrator. Failure to do this will probably result in the ‘access denied’ error message. Navigate to the directory which holds the edited makefile. The DOS command is CD ‘path’. Start with CD C:\ this gets you to the root. You can find the Arduino directory in Windows Explorer and copy the path from the Windows address bar, then CTRL v to paste it into the DOS window at the root prompt, usually C:\ >
The Windows batch file, “omake.bat” MUST be in the same folder as the “makefile” that you edited previously.
The MAKE command line entry MUST use the unique name you chose earlier. Such as “omake FastUNO” Any failures are probably due to the wrong path or privileges. I had to edit the omake.bat file to point directly to the make.exe location, which resides at C:\ArduinoOld\hardware\tools\avr\utils\make . Alternatively if you are sufficiently familiar with Windows environment variables, you can create a new path entry. Beyond my scope, but take a look here…. https://www.computerhope.com/issues/ch000549.htm
At the command prompt, try OMAKE -v. This will force MAKE to supply its version number, and confirm it is available, similarly avr-gcc –version will report the version number of the compiler.
Any error messages will be due to incorrect path or privileges. On successful completion of the OMAKE FASTUNO command, you should find the following 2 files in the bootloaders\optiboot folder.
Copy these to the \optiboot folder in your current Arduino installation. Launch AVRDUDESS again, Avrdudess can now be used to install FastUNO.hex as the new boot loader, by searching your local drive from within the avrdudess FLASH search bar.
This process has no affect on your current Arduino installation. Although I experienced some problems with the paths in omake.bat and in makefile, due to the Arduino file structure changes,  and the whole process is a bit long-winded, it all worked properly once the details were correct. Optiboot will NOT work on the MEGA due to the different addressing requirements.

Permissions in Arduino.
The Arduino installation protects its files by making them accessible only to special security privileges. Ensure you are logged in as Administrator. Open an Arduino ‘H’ file in Windows Notepad for example. After editing the file, you cannot save the changes because the file is write protected, even tho you are logged in as Admin. To get around this, open Windows Explorer and navigate to the Arduino installation. Right click on the Arduino folder, go to Properties, and select Security. In the GROUP box, select Users(computer)\Users. Then click EDIT. This pops up another GROUP box, click Users etc. then in the Permissions box tick the top 2 checkboxes, Full Control and Modify. Click Apply. Windows will scroll thro the Arduino directory entry applying the permissions. Click OK on any open pop-ups. You can now edit Arduino files with any suitable text editor and save your changes. I find Notepad ++ to be very useful.


You should now be able to create faster Arduino’s  for the price of a crystal or oscillator module. I’m an electronics hardware guy, not a programmer, so forgive the long and winding explanation. It has taken me at least a month of research to get this far. I really hope there are no errors and someone else finds this helpful.

I searched the forums as usual, only to find misleading info, typos and outright mis-information. One reply to a query on the Mega was a suggestion to “read the datasheet” all 435 pages of tables and equations. Another reply, and I quote ” you can’t do it like that. “, very constructive. One “Instructable” that I found had 3 incorrect steps, which I discovered the hard way.  How can anyone learn from that ?


Arduino NANO as ISP ( Atmega programmer )

I recently did some experiments with overclocking an Arduino UNO. One important piece of kit that is required is a programmer. These are available from a number of outlets, but I don’t like spending money on something that I can make for myself.  I have a number of smaller Arduino boards such as the Pro Mini and the NANO. I decided to use one of these as the ISP device.

I succeeded in my quest to overclock the UNO at over 28MHz. More details on that soon.

Click the pic to Download the PDF

Negative voltage generator using 555

Negative voltage generator.
I originally designed this circuit in order to repair an Icom 701. It is a fairly standard application of the ubiquitous 555 chip. The output is dependant on the supply voltage and the load, you will not get -9v out with 10v in for example. There is no such thing as a free lunch, and the diodes drop some volts. Replacing silicon diodes with Schottky types will improve things a little.  With a bit of imagination it can be constructed in a very small volume. 

The available current is quite small, about 20mA maximum into a 500R load. Efficiency around 30%. If I recall correctly, the 701 needed just a few uA, so well within the capability of this circuit.

Having recently purchased an SSB i/f PCB that needs -ve volts on the mixers and op-amps, I searched my notebook for
the schematic and made an electronic copy on my Samsung tablet, using the amazing app, SCHEMATIC.

Update .. Aug 2017   I found this to be rather noisy with the Telrad receiver PCB. I removed it and spent some time biasing the MC1496 mixers for single supply operation.