WX-1 baud rate fix
On Thursday I wrote about how my WX-1 APRS weather station was not being received by my TH-D72 and the PIC TNC because the baud rate was slightly fast, and of my unsuccessful attempt to fix it. Glenn W9IQ offered to take a look at the PIC source code and see if there was an easy fix. I sent him a link to the code and a day later I got a reply back. Glenn’s suggestion solved the problem perfectly. But he didn’t just tell me what to change, he explained what the code did and how it worked. I thought that his explanation would be of interest to anyone trying to understand how packet tones are generated using a PIC, so with his permission I am copying it here.
“The baud rate is determined by an interrupt service routine. The interrupt is driven by Timer 0 (TMR0) that is configured to use the instruction clock as its input (frequency of Y1 divided by 4). The input of TMR0 is also initialized to have a divide by 32 prescaler (the code comment says 16 but that is wrong). So at this point the timer is being driven by the frequency of Y1 divided by 128 or (20 MHz / 128) = 156.25 kHZ or a period of 6.4 uS.
Now the math and routines get a little more complicated. The interrupt is serviced by the code in the “packet” file. This code sets the TMR0 count to start at a value of 127. This TMR0 count will tick up one count every 6.2 uS (the clock from the output of the prescaler). When the timer count rolls over from 255 to 0, the interrupt is triggered.
At first glance, it would appear that this would generate an interrupt every 129 counts or 825.6 uS (6.4 uS * 129). That would seem to put the interrupt at roughly 1211 Hertz ( 1/825.6 uS). But this is not correct due to the way the author wrote the interrupt routine plus a small nuance of how a PIC handles the reset of the prescaled interrupt timer.
The interrupt service routine in “packet” executes 6 instructions before resetting the interrupt timer to a value of 127. Each instruction takes 4 clock cycles so this adds another 1.2 uS to the time between interrupts. In addition, when the prescaled interrupt timer register is written, there are another 4 instruction cycles of delay before the timer starts to run again. This is another 0.8 uS added to the interrupt time. So we now have an interrupt cycle of 825.6 uS + 1.2 uS + 0.8 uS totaling 827.6 uS or 1208 Hz. I believe this is what you measured as the current baud rate from your board.
Improving this is fairly straight forward. The interrupt goal is 1200 Hz or 833.3 uS. If we change the TMR0 count to 126 instead of 127, this will add another 6.4 uS to the interrupt period. This would give us 827.6 uS + 6.4 uS = 834 uS. Then if we eliminate one instruction in the interrupt routine, we eliminate a 0.2 uS delay for a total interrupt time of 834 uS – 0.2 uS = 833.8 uS or 1199.3 Hz.
This change is effected in the code located in the “packet” file. Look for the following code fragment:
Change this code fragment to read like this:
Recompile everything and reload the processor and you should see the baud rate drop as described.”
When I ran the modified code the baud rate dropped from 1207/8 baud to 1198/9 baud which is pretty much just as Glenn predicted. The weather station is now being received by the Kenwood TH-D72 as well as my other APRS radios. It can also now be received using the PIC TNC though the level of the receiver audio is critical and unfortunately not the same as that needed to decode the VX-8R. I think that is because the maximum deviation I can get out of the Radiometrix transmitter module is a bit on the low side.
I had an anxious couple of minutes when I found that although the D72 was decoding the packets it was rejecting them as invalid. This turned out to be because the position co-ordinates had a lower case n for North and w for west: In my haste to see what effect the changed code had I had entered the settings carelessly, though the other radios didn’t seem to mind. That was soon fixed.
The WX-1 weather station is now back in position beaconing the temperature, humidity and pressure as G4ILO-5. I would like once again to express my thanks to Glenn W9IQ for acting in the finest spirit of ham radio and helping me out with this.
Julian Moss, G4ILO, is a regular contributor to AmateurRadio.com and writes from Cumbria, England. Contact him at [email protected].
Wallops Island SuperDARN
A few photographs from work on the Wallops Island SuperDARN radar last week…
Ethan Miller, K8GU, is a regular contributor to AmateurRadio.com and writes from Maryland, USA. Contact him at [email protected].
NA Sprints, ARRL DX, and other notes
February, like November, is a busy month for contesting: the CW edition of the NA Sprint leads off the month (along with the Minnesota QSO Party), followed by the phone edition of the NA Sprint the second weekend, and of course, the ARRL DX CW contest on the third weekend.
In short…
NA Sprint CW SO-LP: claimed 162 x 38 = 6156, preliminary 158 x 38 = 6004. Four busted QSOs is actually better than I felt at the end. So, that is good. Still not happy with the numbers, though.
NA Sprint Phone SO-LP: claimed 28 x 16 = 448 in 1 hour operating time. As KE3X told me, his NS score was higher that week! The phone Sprint is more fun from a bigger station, but really suffers from lack of participation.
ARRL DX SOAB-LP: claimed 544 x 243 = 396,576 in 14 hours. This should have been a bit better, but I got sucked into trying to make myself heard in EU on 160 before their sunrise. Killed almost 60 minutes on 15 QSOs there. Also only operated about 1-2 hours during prime EU time on each of Sat/Sun morning. Efforts at getting a run started were a complete failure. Need. More. Firepower. I was very pleased to work ZM1A on 10 meters, though.
Other notes…
After 17ish years of amateur radio, I finally installed my first 30-meter antenna—a dipole at 35ish feet. First QSO was ST2AR, so I guess it’s working alright.
A box full of goodies arrived from Down East Microwave this week and I started working on buttoning up the 1296-MHz W1GHZ transverter. Massive thanks to Ben, N3UM, who lives nearby for sharing his construction notes with me. Not too far along other than punching and tapping a few holes in a diecast box. The DEMI box also included a couple of LNA boards that I hope to tune up for 432.
High winds (90 km/h gusts, according the forecast) from Friday night through Saturday night did not manage to topple my FO12 and A50-3S from their perch on the chimney. I haven’t checked the rotator to see if they still turn, though. This antenna situation needs to change eventually.
Finally, I also managed to score about 250 feet of RG-213 and 10 feet of LMR-600 from a dumpster-diving excursion. The LMR will make nice jumpers from the 903 and 1296 transverters to their respective antennas and I can use the RG-213 to replace the RG-8X on some of my HF antennas.
Ethan Miller, K8GU, is a regular contributor to AmateurRadio.com and writes from Maryland, USA. Contact him at [email protected].
572B Breadboard Linear Amplifier – oh, the insanity!
Today I bring you a video by “bob4analog” on YouTube. His version of a breadboard is slightly different from mine!!!!
Really detailed description of his project and a great tour of it in operation. I have a 572 based amp and found this quite interesting. Others, may just find the layout utter insanity! I really thank him for posting this video, it was interesting and I did indeed learn a few things while watching this video.
From his video description:
An experimental ‘Breadboard’ Linear Amplifier for 80m, using two 572B tubes.
Jonathan Hardy, KB1KIX, is a regular contributor to AmateurRadio.com and writes from Connecticut, USA. Contact him at [email protected].
2011 ARRL DX CW Contest
This past weekend was the ARRL DX CW Contest, one of the biggest contests in all of radiosport. The object of this contest is for stations in the US and Canada to contact stations anywhere else. (In this particular contest, there is no credit for US & Canadian stations to work either country). Contestants may use 6 different bands, 10m, 15m, 20m, 40m, 80m, and 160m. As you might have guessed from the name, this is a CW (morse code) only contest. I’ve done this contest a few times in the past years, and as I’ve become more comfortable with using CW, I’ve participated more. The band conditions for this year looked to be pretty good, with the sun finally starting to wake up from the very long trough between solar cycles 23 and 24. The solar flux remained over 100 for the entire contest, and the sunspot number was over 100 as well for a time, then dropped back to around 79. (This will all be gibberish for non-hams, but for contesters and DXers, this is great news.) I figured that I’d try to spend a reasonable amount of time operating this year, and I wound up spending 17 hours (out of the 48 possible) in front of the radio.
I usually try to set some kind of goal to keep me going, though as I’ve admitted in the past, I tend to do it on the fly; I’ll see where I am at some given point and decide “ok, I can make another 30 contacts before turning in for the night” or “I think I can beat last year’s score”. I really did a lot of “on-the-fly” this year, though I decided after about 3 or 4 hours of operating that I wanted to be sure to beat my score from last year. Last year I wound up with a score of around 160,000 points after deductions for errors, and based on the early going I figured I’d be able to beat that. Not only did I beat it, but I actually doubled it (before error deductions, of course).
Band QSOs Mults ------------------- 160: 5 5 80: 53 36 40: 189 67 20: 172 68 15: 81 47 10: 25 19 ------------------- Total: 525 242 Total Score = 381,150
I should note that this year I entered in the new Single Operator All-Band Assisted Low Power Category (previously any assistance required you to be considered High Power), so comparing this to last year might not be 100% accurate, but I’m still pleased with my showing. I used the packet clusters to help find DX for me, and using the N1MM contesting program, I could easily move from station to station with a couple of keystrokes (or mouse clicks). There was enough activity and the band conditions were good enough that I didn’t have to tune for stations which, while perhaps a bit more “pure” (to some) in terms of the contest, dramatically slows things down in a busy contest like this, where I have to find a station, listen to get a callsign and then decide if I need to work that station. (I should say that I always use the packet cluster spots as a guide, since they are notorious for incorrectly identifying stations. If you log the wrong station callsign, it’s not only bad for you but also for the station that you contacted.)
The nice thing about the good band conditions were that for the most part, once I could hear a station I had little trouble working them. For some of the big stations that attract a lot of callers, it could be difficult, but I’ve learned that those guys will be around for the whole contest and it’s easier to just move off and work someone else, then come back when things are quieter. This is in contrast to a year or two ago when conditions were so bad that even when the other station heard me, or heard “something”, it could take several tries until we were able to both get the correct information that makes up the contact. This time for the most part once the station started a contact with me, we were able to complete it relatively easily. The most significant exception to this was with one station (who I’ll put in here when I can figure out who it was ) who spent almost 4 minutes working with me late at night on 80m to complete the contact. (A normal contact takes anywhere from 15 to 30 seconds, tops.)
Although I didn’t work any “all-time” new countries, I did pick up a few new band-countries: PJ2, V4, XE, and OM on 160, EU on 80, and J5 on 10. (Interestingly, as I was writing this on Sunday evening, the J5, which is Guinea-Bissau, was spotted on 80m and I was able to work him there as well, post-contest.) I was a little surprised that I only worked 87 different countries given the number of overall contacts that I made, but part of that is accounted for by the fact that I worked many, many stations on 2, 3, 4, 5, and even 6 different bands. (I worked PJ2T and V48M on all six, and I believe that’s the first time I’ve ever worked any station on all six contest bands.)
I did have a small visit from Murphy of course: We’ve had a couple of very windy days here, and Sharon commented that she thought she hear my antenna (it’s actually where the ladder line connects to the coaxial feed line) hitting the roof. (That particular portion of the roof is over the room where the TV is.) Sunday morning I took a look outside and realize that my G5RV had dropped about 10 feet from where it should be, the result of the winds blowing. I have it connected via bungee cords in such a way that they’ll take up some slack, but after a while it will drop a bit from the constant “pulling”. Fortunately, it was easy to fix and just required a quick trip up the ladder to both ends of the antenna to pull it back up and things were back to normal.
So, now that I’ve completed this blog entry, that wraps up my post-contest activities, having submitted my log to the ARRL, uploaded my contacts to Logbook of the World, eqsl, and Clublog, and submitted my score to the 3830 contesting reflector.
Longlands Fell, LDW-179
Today Geoff GM4WHA became the first Wainwrights On The Air (WOTA) chaser to claim a certificate. He worked me on Longlands Fell (LDW-179) thereby completing Wainwright’s Northern Fells having made contacts with stations operating from each of the fells in that book.
Noticing that a few chasers were just a few fells short of completing a book, I suggested in the WOTA forum that chasers should post the fells they need, which might motivate some activators to go out and activate them. Geoff duly posted, and Longlands Fell was one of the ones he needed. As it is only about 20 minutes drive from here and an easy walk, I thought it would be a good idea to blow away the cobwebs of more than two months of slothful inactivity by activating it. So I did.
Despite an early start (for me) I was lucky to find a place to park at Longlands near the Uldale Common track. The ascent is quite easy up a grass path, but due to the long period of inactivity (and having put on a couple of kilos since Christmas) I had to stop for a breather rather a lot. The photo shows the view from the top with the summit cairn in the foreground, Over Water in the middle distance and the often visited summit of Binsey (LDW-190) in the background. What it doesn’t show was the bitingly cold strong wind which numbed my fingers and made it too difficult to use the 5/8 telescopic antenna.
Despite using a 7in. helical antenna (which tests have shown to perform comparably to a 19in. quarter wave whip and much better than the dummy load supplied with the handheld rig) I made 9 contacts from the summit including the all-important one with Geoff, which is good going from such a summit which is well screened to the south.
I have probably said this too often, but WOTA keeps on getting more and more popular. I’m hearing new chasers all the time – the latest recruit is Steve, M6CDX – and even people who originally said they were getting too decrepit to climb the fells have been heard operating from some of the lower ones. So far this year I have worked 50 different summits and made 72 WOTA contacts from home, not far short of my total for the whole of 2010, and we’re only a bit over half way through the second month. I’m sure others have also noticed the greatly increased activity.
There is great camaraderie among all the participants, too, many of whom feel like old friends even though most of us have never met. I think it is fair to say that the success of WOTA has exceeded my wildest expectations. Combining two of my favourite activities – walking in our wonderful mountains and making contacts on the radio – it doesn’t get much better than this!
Julian Moss, G4ILO, is a regular contributor to AmateurRadio.com and writes from Cumbria, England. Contact him at [email protected].
Catching up on the week (Harwell rally, hands-free and 70MHz FM)
What no blog posts this week? It’s been a busy week with one thing and another and I don’t seem to have got around to it.
Last Sunday I enjoyed going to the Didcot rally. It was well attended – better, I think, than for some years. As far as I was concerned it was a mostly social event and it was good to see a number of friends face to face and have a quick chat. I didn’t spend too much money, but grabbed a 70MHz quarterwave mobile antenna for the car from the Garex stand and an audio lead to help Julie with her presentation about ‘Earthwatch, Cheetah’s and Me (her!)’ which she did for the local WI this week.
Coming back from the rally, I felt my foot go! Just an attack of tendonitis, but it’s been painful through the week and I’ve been avoiding walking which is unlike me!
What else has been happening? I noticed a conversation on Twitter about Digi-interfaces and noted that someone recommended Alan, M0AQC as being a good source of reasonably priced interfaces. His web page has the details. I also noticed that Alan makes hands-free kits. I’d hoped to see one at the Didcot rally but didn’t. I was conscious that if you are operating mobile these days, a hands-free kit is considered essential. I checked with Alan that one of his would work with the FT8900R – he said yes – so one has arrived and been installed.
The unit is a clip on microphone which could go on the sunvisor, although I just clipped it onto my collar to get a better audio level and a switch box with LED which I’ve attached to the dashboard. Reports so far have been good. The only downside is that I’ve lost the ability to scan or change power levels from the program keys on the microphone. No big deal, it’s something I can manage in different ways.
I’ve got a MyDel-5189 70MHz FM mobile rig in to review for Practical Wireless magazine. I’ve got it set up in the shack and it’s been working well. I’ll save the details for the review, BUT – something I immediately enjoyed was the ability to scan various channels on 70MHz. That was something that I’d never done with my Philips FM1000 converted rig.
I wondered if it was possible and after a quick look at the manual for the PA4DEN conversion I was able to store frequencies and scan them. Result!
Tim Kirby, G4VXE, is a regular contributor to AmateurRadio.com and writes from Oxfordshire, England. Contact him at [email protected].


















