QST HamClock

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 3

HamClock

Keep track of much more than the time with this Wi-Fi enabled device.

Elwood Downey, WBØOEW


I thought it would be useful to build a
desk clock that could show accurate
time, geography, time zone, solar activ-
ity, sunrise and sunset times, Maiden-
head locators, beam heading, Northern
California DX Foundation (NCDXF)
beacons, news headlines, and other
timely information in one small device.
Here’s how I assembled a 7-inch diag-
onal thin-film transistor (TFT) touch-
screen color display, with a few
embedded components to access all
that data via Wi-Fi.
Figure 1 — The screen display of the HamClock.
HamClock Functions
A cylindrical projection of a color
world map dominates the screen in a
feature-rich presentation. In Figure 1, dotted line. This line automatically dis- To save display space, I compressed
you can see the day and night termina- appears after a few moments, to reduce Sun time information. The first row
tor, the projections of the overhead Sun screen clutter. always suggests a future, and the sec-
and Moon, the locations of the home ond row the past. For a station in day-
Fine tune the latitude and longitude of
(DE) and remote (DX) operators, the light in late afternoon, the display
the DX by tapping directly on these
antipode of DE, and optionally, the might read “S in 0:40, R 10:22 ago”
numbers. Tap on the upper or lower
locations and current transmission fre- where S means “Sets” and R means
half of the latitude digits to move the
quency of the NCDXF propagation “Rose.” For a station in nighttime
location one degree north or south, and
beacons. Tap on the touchscreen map approaching dawn, the display might
tap on the left or right half of the digits
to set a new DX location, and hold for read “R in 0:47, S 10:00 ago.” This
to move the location west or east. Tog-
a second to set a new DE location. eliminates dependencies on time zones.
gle between miles and kilometers by
Screen Details tapping on the DX bearing digits. Data Rows
Two boxes to the left of the map show Time A row of news headlines (collected
local time and date, latitude, longitude, from your selected website RSS feeds)
The software includes a table of time
Maidenhead grid square, sunrise, and overlays the bottom of the map. There
zones based on a grid spacing of
sunset information for the DE (orange) are five areas at the top section of the
approximately 11 miles. Time zones
and DX (green) locations. The short- display. On the left is your call sign
are determined by government policy,
path distance and beam heading from and UTC time. The time remains accu-
so they may change over time. Always
the DE location is shown for the DX rate by using a Network Time Protocol
double-check this information. You can
location. These color-coded locations (NTP) connection over Wi-Fi. The
manually add 1 hour to the displayed
are shown on the map. The small software automatically cycles through
time for DE and DX during daylight
orange map symbol drawn as the a list of several stratum-one NTP serv-
saving time. [Daylight saving time start
inverse of the DE symbol is the DE ers. If the software cannot contact any
and end times and dates do not neces-
antipode. Whenever a new DX location of the NTP servers, a large question
sarily occur on the same date and time
is tapped on the map, the great circle mark will appear to the right of the sec-
around the globe, and the offset might
connecting through DE and DX, the onds digits to indicate the time might
be a fraction of an hour. — Ed.]
DE antipode is displayed as a white not be correct.

QST ® – Devoted entirely to Amateur Radio www.arrl.org October 2017   1


The main clock need not stay on UTC. Figure 2 — Wiring
diagram of the main
You can tap on the upper or lower half 16
1 1
RST HamClock
of any word or digit to advance or slow 2 2 components.
SCK/14 SCK
3 3
the time by that one unit. If the time MOSI/13
4 4
MOSI RA8875
has been changed in this manner, the MISO/12 MISO display
5 5 controller
USB VIN
UTC button on the right will show all 2
6 6
CS
ESP8266
white characters to indicate the time is HUZZAH GND
7 7
GND
not UTC. Tap that button to instantly Feather
Photocell*
return to UTC. Changing time in this A0
8

manner causes the map to be redrawn 33 k*


1
GND
to synchronize all information to that 3V
9 2
VIN BME280
weather
moment. Thus, you can examine the SCL/5
10 3
SCK server
location of the terminator in the past or SDA/4
11 4
SDI
*optional
future, but only between January 1, QS1710-Downey02
1970 and January 19, 2038.
The second area across the top displays
plots of recent solar activity. Either
solar flux or sunspot number can be diction Center. Sunspot numbers are shows a list of my components and the
toggled by tapping on the plot. The accessed from Solar Influences Data prices I paid. The sensor and stand are
solar flux prediction is plotted 3 days Center in Belgium. Solar images are optional. Figure 2 shows the simple
into the future. The sunspot numbers from the SDO. I chose RSS feeds from wiring diagram. If the sensor connec-
are published starting from the begin- a wide variety available online. tion is longer than a few feet, connect
ning of the current month. For this rea- the SDA and SCL lines to 3 V with
The area to the far upper right is for the
son, the sunspot numbers will go back 5.6 kW resistors to help deal with the
NCDXF HF propagation beacons. The
less than 7 days for the first week of cable capacitance.
symbols for these beacons may be tog-
each month.
gled on or off by tapping on the button Display Controller
The third area toggles between plots labeled NCDXF. When the beacons are The RA8875 display controller relieves
for planetary Kp geomagnetic index on, they are color coded to indicate the processor from performing display
and X-ray solar flux. The data is plot- which frequency they are currently refresh, and adds hardware-assisted
ted for the previous 7 days and may be broadcasting, if any. The beacons drawing primitives. Unfortunately, it is
toggled by tapping on the plot. The Kp change frequencies, or go silent, every pretty slow to address individual pixels,
index prediction is plotted 2 days into 10 seconds in a pattern that moves so drawing the world map and updat-
the future. around the globe. These beacon sym- ing overlaid information still takes
The fourth area shows images from the bols may be removed from the map if noticeable time. The backlight for the
Solar Dynamics Observatory (SDO) they are of no interest. display can be brightened by closing
and, if the optional sensor is installed, Construction one or both of the solder bridges on the
plots of temperature, pressure, and back of the RA8875 display controller.
I purchased all my hardware for this
humidity for the past hour. The sensor I found that shorting the 25 mA bridge
project from www.adafruit.com. Other
for these data points can be located in was sufficient. Shorting the 100 mA
components may be substituted, but
the shack or extended outdoors if bridge draws too much current. The
take note of any differences. Table 1
desired. Tap on the graph to cycle
through the images and plots. If the
sensor is not connected, the software Table 1
displays only the SDO images. List of HamClock Parts (www.adafruit.com)
Solar flux is accessed from the Cana- Description Product Number Approximate Price
dian Space Weather Center, of Natural Adafruit HUZZAH ESP8266 Wi-Fi system-on-chip 2821 $16
Resources Canada. X-ray and geomag- RA8875 display controller 1590 $5
7" TFT display with resistive touch 2354 $48
netic information are from the NOAA/ FPC extension cable and board 2098 $5
NWS (National Oceanic and Atmo- Pimoroni Raspberry Pi 7" TFT stand, optional 2033 $15
spheric Administration/National Photo cell, optional 161 $1
BME280 weather sensor, optional 2652 $20
Weather Service) Space Weather Pre-
2   October 2017 ARRL, the national association for Amateur Radio® www.arrl.org  
manually control brightness without
the photocell.
Software
My software for this project is avail-
able on the QST in Depth web page, at
www.arrl.org/qst-in-depth. Also, be
sure to check for any last-minute
updates or changes on my web page
for this project, www.clearsky
institute.com/ham/HamClock.
You might wish to edit the list of RSS
feeds in my software in the “rss feeds
[ ]” array near the top of the “Wi-Fi.
cpp” file, or make the array empty to
Figure 3 — The rear of the HamClock shows how the main components are adhered disable RSS feeds. You can now pro-
to the back of the bezel and shows the wiring using female-female jumper wires.
ceed to compile and load the firmware.
Packaging
HUZZAH USB bridge does not nego- this IDE. If you use the optional sensor, I packaged my 7-inch HamClock in the
tiate for higher current, so you must install the sensor library. Adafruit Raspberry Pi bezel, product
supply about 1 A from a separate 5 V number 2033, and used double-sided
Powering Up
source. The display is very sensitive to tape to attach the circuit boards to the
small changes in supply voltage, so if Upon powering up for the first time, back (see Figure 3). I mounted my
the display flickers, check that you you are asked to calibrate the touch- 9-inch LCD version in a document dis-
have good power connections screen, enter Wi-Fi credentials, and play panel. My 7-inch unit draws about
everywhere. your call sign. These can also be 300 mA, so for portable expeditions I
changed later if desired. Next, a splash use a pocket-size 2,200 mAh lithium-
A Larger Display screen displays your call sign in a rain- ion polymer (LiPo) battery USB power
A 9-inch diagonal display has about bow of colors and the Wi-Fi attempts stick that runs the display for about 5
twice the total viewing area of the to connect with the designated access hours. My HamClock project met all
7-inch model, but has the same number point. After these preliminaries are my expectations, and I hope you find it
of pixels. I got one (part number ER- over, the screen renders the main useful as well.
TFTM090-2) from EastRising via display.
www.buydisplay.com. I also tried an
The HamClock attempts to connect to
alternative, smaller Adafruit HUZZAH
Wi-Fi when first powered up. If it fails Elwood Downey has been licensed
breakout board, product ID 2471. continuously since 1974 as WBØOEW. He
to connect, the map will continue to graduated with honors with a Bachelor’s in
There are a few minor differences, so
function, but the time sync and data electrical engineering from Purdue University
please contact me if you are interested in 1977. He passed all the FCC written tests
plots will not be available. In this case, (including Amateur Extra) on his first try, but
in trying these alternatives.
you could manually set UTC time. The waited for the no-code rules to achieve his
Amateur Extra class license in 2008. Elwood
Main Controller HamClock automatically retries web- is enjoying a career as both an electronics
sites and Wi-Fi as required. and software engineer, specializing in
The main controller of the HamClock telescope control systems and other related
is the Adafruit HUZZAH ESP8266 Add automatic brightness control by astronomical instrumentation. He can be
reached at wb0oew@arrl.net and maintains
Wi-Fi system-on-chip. It includes an connecting an optional photocell to the a small ham web presence at www.
80 MHz 32-bit RISC processor with analog input of the ESP8266 (see Fig- clearskyinstitute.com/ham.
1 MB flash memory and 80 KB RAM ure 2). To calibrate the brightness, tap For updates to this article,
available for applications after the the upper or lower portion of the see the QST Feedback page at
required Wi-Fi firmware. I developed NCDXF frequency list to set the www.arrl.org/feedback.
and loaded firmware for this device desired display brightness in a dark-
using the Arduino IDE. Adafruit has ened room. Then turn on the room
instructions on their HUZZAH support lights and repeat for the desired bright-
page for adding the ESP toolchain to ness in a well-lit room. You can also

QST ® – Devoted entirely to Amateur Radio www.arrl.org October 2017   3

You might also like