Friday 22 August 2014

20dB or 40dB RF Attenuator

I have found that I need an RF Attenuator for my bench. My bench tools are primarily suited to QRP work and so whenever I have to mess with a 35W FM rig I find that my meters and sensors are inadequate. I've killed quite a few bits of test equipment by stuffing 50W of RF into a 5W power meter.

As part of a larger project to create a 0-500MHZ power meter I started with the attenuator. There's nothing special about this one other than perhaps the compact design. It can be either a 20dB or a 40dB device dictated by the resistors you populate it with. Indeed, if you buy the boards from oshpark.com you can make both variations for less than $5.
See how simple it is?

The attenuator will present a 50Ω load to the connected radio and with its 1/4W resistors should be good for small bursts of around 50W of RF. Adding 1/2W resistors should increase the power capability to 100W and allow for longer key-up times at lower powers.

The files are listed below in both Eagle and PDF formats.

20-40dB_RF_Attenuator.pdf
20-40dB_RF_Attenuator.brd
20-40dB_RF_Attenuator.sch

Tuesday 5 August 2014

Credit card sized Arduino with Ethernet

I dunno about you but I find the whole Arduino board format very cumbersome. It can also get very expensive too. Frustrated with boards stacked on top of each other I decided it was time to create a smaller board format that housed my most common components: ethernet, I2C, 12v PSU and of course the micro processor itself. 

One can find anything on Al Gore's Interweb if one looks hard enough. It was not long before I discovered something that could be fashioned into use. It had a few minor issues but as I would have to design a board anyway it was a good jumping off point.

The completed board
My version differs from drj113's in that I have removed the DIP switches and replaced them with a dual header so that one can use the header for either analog inputs or as a DIP selector. I returned all the components back to normal size (some were SMD). I've also brought out all the unused digital pins to a header on the edge of the board and added a FTDI interface so that one may connect a serial programmer.

Well, it almost worked first time. I stuffed the PCB, uploaded a sample sketch that would connect to the Internet and .... nothing. Crap! I hate diagnosing circuits. But for some odd reason rather than get the meter out and poke on about the board I decided that the problem MUST be with the software. I get like that after a beer or 3.



I was kinda sorta right too! It would seem that there are in fact 2 different libraries for the ENC28j60 Ethernet chip I'm using and of course, I had the other one. Easily fixed. I edited the library source code to reflect the moving of one of the signal pins used by the Arduino to talk to the Ethernet. It appears that the 2 libraries exist because of the addition of an SD card reader. The SD card would share some of the same pins as the Ethernet. To allow for both, the Ethernet pins get moved around a bit. Great! I fixed it. Upload the sketch and ..... nothing. 

Well, not nothing but not anything useful. I had established communication with the Ethernet chip but no further. This was proved by the reading of the Ethernet chip's version number and then the failing of any DHCP. CRAP!!!!

It turned out to be a trivial fix in the end but it took me over an hour to diagnose; I had neglected to add a pull down resistor onto one of the Ethernet controllers pins. 2K7 later and bingo! It did not take long to correct the PCB files and re-upload them to oshpark for others to use.

The final board with all the bugs ironed out
I've already pressed this board into service with my NTP shack clock. It works great!!

The design files in Eagle format . . .




Bitx DDS and frequency display

I built a Bitx20. I'm not happy with it. The VFO leaves much to be desired and whilst many folks find it acceptable I find it cumbersome and inexact. I never know what frequency its on. It appears that many users find this to be the case as is evidenced by the handful of digital VFO addons for the Bitx. Time to build my own.

So what do I want mine to do? Well, let's see . . .
  • Arduino based (because it's easy)
  • LCD readout
  • Use cheap Ebay 9850 DDS module 
  • CW keyer with paddle input
  • FT-817 style computer control
  • Channel buttons
  • S Meter and battery voltage etc.
  • Probably other things too
And here it is! It did not take too long to create. I borrowed much of the Arduino code from  other projects and hacked it all together.

The finished board
Observant bastards will have noticed the MIC and PTT inputs on the upper right of the board. This allows the PTT from the Mic to be wired through the board. The board will then compare the current frequency against it's internal band plan and then key the rig (or not). It will also display a TX or RX symbol on the readout.

The LCD readout showing the current frequency (upper line), battery volts (lower left), step rate (lower middle) and S-meter reading (lower right) 

The board under test

The IF + VFO combined output