Yet more new AVRs

In a previous blog I mentioned the new atmega4809 and AVR128DA parts. Well, it seems I missed two other new families, the AVR128DB and AVR128DD series. I’ve requested some engineering samples of the AVR128DB64, and will attempt to solder one to a breadboard adapter. Will update on that later…..

The AVRxxxDB family is very similar to the DA but adds an external HF crystal oscillator (up to 32mhz), a level translator for one of the ports (so if you run the chip at 3.3volts it will be able to interface with 5v logic), and some OP amp stages that can be used as buffer amps for the A/D input, or D/A output. Only the 64 pin 128k flash variant is currently available, the rest of the variants will be shipping some time late this year, or early next year (I’m guessing).

The AVRxxDD family is a cut down version of the DB with less memory, and is only available in low pin count packages. It’s another option for those who would otherwise turn to the atTiny line of microcontrollers. The DD’s will be available in SMT 14, 20, 28, and 32 pin packages, as well as a 28 pin DIP (300 mil) package. These parts were recently announced, but are not yet available, even as samples.

No, I’m not associated with Microchip, but I’ve been following their AVR family having used these parts for years. I have also looked at the SAMD family of ARM Cortex M devices for use in ham projects. These microcontrollers offer much in memory size and processor speed, but they are much more complex than the AVR line. Except for DSP (SDR) applications, there is simply no need to go 32 bits, and the 8 bit AVR solution is usually the preferred option. The new SAMD parts did have a cost vs feature advantage over the older atMega devices, but the newest AVR parts, which are spin offs from the ‘failed’ Atmel Xmega offerings have caught up to the ARM Cortex M devices in this regard.

I had wondered if the sale of Atmel to Microchip would spell the end of the AVR. I guess I shouldn’t have worried, the product line seems to be in good hands.


I bought my first camera around 1977. Upon the advise of my father, and a fellow ham, I decided upon a Nikon FE 35mm SLR. I bought it at 47th Street Photo in NYC. Back then, the camera makers didn’t offer a bundle with a ‘kit’ lens included, the camera bodies and lenses were sold separately. Nikon had recently come out with their introductory model, the Nikon “EM”, along with the ‘Series E’ lenses. These were low cost entry level equipment, using a lot of plastic instead of metal in their construction. The series E lenses had good glass, no serious compromises here, they lacked the coupling shoe, so they would only work with the newer ‘AI’ cameras (which the ‘FE’ was). 47th Street Photo offered a kit bundle with the FE, which included the series E 50mm F1.8 lens, a cleaning brush with air bulb, a battery for the camera, and a roll of film.

A few years later, Nikon introduced their model FA camera that featured some advanced metering modes (‘matrix’ metering, and programmed automation). This camera looked like a nice upgrade from the FE, and I eventually bought one when a local camera store had them on sale. My FE was a black body, but the FE that was on sale had a silver body. You’d think that the silver body cameras would be more in demand, and command a higher price, but most professional photographers prefer the black body cameras, and those are the more expensive models.

I slowly added to my lens collection, getting the Nikon 70-210 F4 series E zoom telephoto, and the 105mm F2.8 ‘Micro’ lens with the matching extension ring. This latter lens is a close focusing lens that closes down to F32 for greater depth of field. It was the perfect lens for photographing model railroad layouts. I also had my fathers Nikkor 28mm f2.8 wide angle lens on a semi-permanent loan. He rarely ever used it, so he let me hold on to it for my own use. I returned it to him years later after I sold off my Nikon equipment.

Auto focusing 35mm SLRs came out in the mid to late 1980’s, and was standard equipment by the 1990’s. Auto focus cameras required getting a new set of AF lenses, but the older manual focus lenses would work on the newer AF cameras, without auto focus. I resisted upgrading to an AF camera as I had a nice selection of non AF lenses, and could not justify the expense of starting from scratch. I could focus the camera rather quickly, and accurately enough not to need the auto focus feature, though I could see where it would come in handy.

The 21st century marked the beginning of the decline for film with the introduction of digital cameras that were no longer ‘toys’. I went through two Olympus ‘point and shoot’ digital cameras, the first with a 1 megapixel sensor, and the second a two mega pixel. The latter camera had a zoom lens. They were small cameras that could fit in the pocket, yet produced decent images in strong light. They did suffer with high magnification, and low light conditions due to their small sensors and low resolution. I later bought an Olympus C5050, a small 5 megapixel camera. I also got a telephoto adapter lens to fit the camera, and an external flash. The image quality was now good enough to replace my film SLR’s for many occasions. This camera made it obvious to me that digital was the future of photography.

I wanted to get one of the new digital SLR’s to replace my Nikons, but again this would mean getting new lenses. In 2008, Sony had purchased Minolta’s camera line, which included their Maximum DSLR cameras. There were many Minolta auto focus lenses from their older film cameras which fit their digital camera bodies, and would also fit the new cameras that Sony was now selling. I could find a suitable used Minolta auto focus zoom telephoto lens to fit the 10 megapixel Sony A200 camera cheaper than one for Nikon’s similarly priced entry level DSLR. A kit bundle including the A200 and a wide angle to portrait zoom lens fit my budget after selling my two Nikon bodies and lenses. (I still regret selling my 105 F2.8 Micro Nikkor though). I also found a used Minolta flash that would work in semi-automatic or manual mode with the Sony A200.

The A200 served me well for a few years while my daughters were in the High School marching band. However digital camera technology was quickly advancing with the newer cameras having faster auto focus, and higher resolution sensors. Olympus had introduced their 4/3 sensor equipment at the time I had bough the A200, and now they had morphed that into the mirror less Micro 4/3 system.

Panasonic was a partner with Olympus, selling their own brand of cameras. They were now selling a DSLR like mirror less body, the G1, and a hybrid video / still version, the GH1. Both were introduced at 12 mega pixels. I was impressed with the light weight and small size of these cameras, enough to trade in the Sony for the Panasonic Lumix G3 when it came out. Now at 16 mega pixels, the G3 was lighter and easier to carry then the larger APSC sized DSLRs. At this time I had ‘discovered’ KEH, and their cache of used equipment. I was able to find a 40-200mm Panasonic zoom telephoto and an Olympus flash that would work with the G3. Due to the smaller sensor, and the resulting 2:1 ‘crop factor’, the 200mm telephoto will give the same magnification as a 400mm lens on a ‘full frame’ 35mm camera.

I’ve just recently upgraded to a Panasonic Lumix G85 camera. While still a 16 mega pixel camera, it now has in body image stabilization (the G3 relied on image stabilization built into the lens), 4K video, a better image processor, and weather sealing. The newer camera is a bit larger and heavier than the older one, but it has a better grip. I also replaced the 18-42mm zoom lens that came with the G3 with the current 12-60mm zoom.
The newer lens is weather sealed, and has a longer zoom range. The in body image stabilization will work with older manual focus lenses mounted on the camera. My old Spiratone 400mm F6.3 manual telephoto lens works on this camera, with an effective 800mm focal length. I also have the matching 2x telephoto adapter for this lens, which gives an effective 1600mm focal length with the 2x crop factor. The cameras image stabilization enabled me to shoot photos of airplanes in route to the Fort Lauderdale airport hand held at 1600mm with this lens!

The transition from film to digital has been an evolutionary process. Along the way, we’ve seen the shift from photographers using a large collection of fixed focal length prime lenses to a small set (1-3) of zoom lenses. In the early days of zoom optics, the breed was considered inferior to a fixed focal length lens, but today this isn’t a concern. With optics now designed by computer ray tracing techniques, lens design is today more of a science than a black art.

Another change has been the shift to variable apertures on zooms, instead of a fixed F stop during the focal length change. This is a cost cutting ‘feature’, allowing for sharp optics at a price range within a beginners budget. Today, many of the kit lenses have a higher minimum F stop than what we used in the film era. The common 50mm prime kit lens sold with a film camera was usually an F1.8 or F2, today the zoom sold with most cameras opens up no wider than F3.5, and that at the widest zoom setting. The reason for this is once again price, but with the higher ISO settings available on digital cameras (ASA 1600 or higher vs 400 on film) the need for a fast prime lens isn’t as great.

Still there is one drawback, today’s slower lenses mounted on an APSC or Micro 4/3 sensor sized camera don’t have the narrow depth of field that one could get in the film era. You need a fast lens to blur the background. To get the effect given by an F1.8 lens on a full frame camera when using Micro 4/3, you’ll have to find a suitable F1.2 (or faster!) lens. There are some manual F0.95 prime lenses being made today for Micro 4/3 for those needing the narrow depth of field, but they come at a cost! Still, except for this one case, lenses for Micro 4/3 are usually less expensive then their full frame equivalents.

One nice thing about Micro 4/3, is the ability to mount old manual lenses with an adapter. This is why I’m kicking myself for selling that 105mm F2.8 micro Nikkor! I could use it for close up photography. I did manage to find a ‘bargain’ grade 55mm F3.5 micro Nikkor at KEH. With the 2x crop factor the lens does give me the same magnification as the 105mm did on my full frame 35mm film camera, and I don’t need the speed. (I usually shot the 105mm at F32 back in the day.) Lens adapters for M4/3 are made to fit almost every lens made by Nikon, Canon, etc. Some of the older auto focus lenses can even auto focus on M4/3 with a suitable adapter, though this will be on a case by case for specific cameras and lenses.

A special kind of lens adapter is one having built in optics to lengthen or shorten the effective focal length of the adapted lens. An adapter that reduces the effective focal length will also reduce the effective F stop as far as depth of field is concerned. Except for the high price of these adapters, this is a solution to the availability of fast primes to get the desired background blur.

Background blur is one feature advantage of full frame cameras over Micro 4/3 and APSC sensor cameras. Another feather in the hat for full frame is low light performance. Both M4/3 and APSC seem to have peaked at the 20-25 mega pixel plateau while Full frame cameras can reach 45-60 mega pixels. However, both the Nikon Z5 and Z6, and the Panasonic S5, S1, and S1H are only 24 mega pixels. Why? To maximize low light performance. Full frame sensors at this pixel density have larger pixel cells to capture more light per pixel. Unless you are shooting an image that will be blown up to a wall sized mural you don’t need more than about 25 mega pixels.

Both Nikon and Panasonic are now making full frame mirror less cameras. Their first ventures into this product have been at the high end professional level. Both have recently introduced new lower cost cameras closer to the entry level category. The Nikon Z5 body is priced at $1400, while Panasonic’s S5 lists for $1999. While both of these are far less expensive than earlier full frame offerings from these makes, they are still about double what I’d want to spend on a new camera body. Also lenses for both the Nikon Z mount, and Panasonic’s L mount, are still quite expensive. Perhaps in a few more years we will see true entry level product in the full frame mirror less camera market.
Until then, I’ll stick with my current camera. At the 16 mega pixel level I probably have a little better low light performance than the newer 20 mega pixel M4/3 cameras (Panasonic G95 and G9), and more than enough resolution for what my needs.

Using the new AVR chips

I’ve been playing around with the MicroChip AVR128DA48 Curiosity Nano board for a few weeks now. This is a development board for the AVRxxxDAnn family (xxx is the size of the flash rom, 16k,32k,64k, and 128k, nn is the pin count, 28,32,48 and 64).

These devices are available in 28pin DIP, SOIC and SSOP, and 32, 48, and 64 pin VQFN and TQFP packages. The SMT packages have pin spacing of 1.27mm to 0.4mm depending on the package size. The 1.27mm spaced SOIC, 0.8mm spaced TQFP, and maybe the 0.65mm spaced SSOP are not too hard to hand solder, however the 0.5mm spaced TQFP (48 and 64 pin packages) are better soldered using paste applied with a stencil and a hot air station than by hand with a soldering iron. (Digikey carries stencils for various sized SMT IC footprints.) Still, it CAN be done if you have a good magnifier, a very narrow tipped soldering iron, and 0.2mm (or thinner!) solder wire. SMT to DIP adapter boards for these parts are available, look for ones with a good solder mask layer between the pins, and either gold or tin plating on the pads. A steady hand is also required!

I purchased some extra chips in the 32 and 48 pin TQFP packages. I’ve soldered 100 pin 0.5mm packages before (Atmega2560) so I have some hope of being able to work with these. I’ve also ordered some stencils and solder paste, just in case!

In addition to the AVR128DA parts, I’ve ordered some of the ATmega4808/4809 parts in both 32 pin TQFP, and 40 pin DIP packages. The ATmega4809PF is an interesting throwback. Housed in a 40pin DIP package (and available for $2.02 in single pieces), it’s ideal for bread boarding. Cheaper than the ATmega1284, and with more features, this may be the ‘goto’ part for most QRP rig front panels. This part is actually using the same die as the 48 pin TQFP/QFN parts, with 8 of the port pins not connected. Microchip recommends disabling the unused port pins in software to save power. BTW, the Arduino Nano Every which uses the ATmega4809 is advertised to run at 20mhz, but it really is clocked at the 16mhz rate out of the box. You’ll have to reflash the boot loader (or the fuses) to get it to go at the 20mhz rate.

The 32 pin ATmega4808-AU is the same size as the ATmega328p used on the Arduino Uno, with 50% more flash memory, and more I/O. It’s also cheaper, and should be considered for any application where you’re currently using the older AVR.

The AVR128DA family has some advantages over the ATmega480x family. The internal clock oscillator can be synchronized against an external 32khz crystal, which is also used as an RTC clock source. The ‘480X family also has the external crystal oscillator for use as an RTC, but no built in automatic clock synch for the HF main oscillator. Max clock frequencies for the ‘DA family goes up to 24mhz, selectable under software control.  Also the available 64 pin package provides a few more Usarts, A/D inputs, as well as more I/O pins.

The ‘480x family runs at either 16 or 20 mhz, selected by a fuse bit in flash. There are software configurable clock dividers, but the base frequency can’t be changed under program control.

You have two choices of how to write code for these parts, either use the Arduino IDE, or ‘bare metal’ C/C++ code. I’ve used the Arduino IDE in the past to create rapid prototypes for AVR based projects as a contract software engineer.   Often, I’ve been criticized for doing this, other software engineers have pointed out that Arduino is for hobbyist’s, and isn’t suitable for production work. For the most part, I’d say ‘Balderdash!”. The Arduino platform is really C++ and a collection of libraries and macros. It uses the GNU GCC compiler and binary tools, along with the GNU C library. You do have to bend over backwards a bit to save the resulting binary and linker outputs which are deleted whenever the IDE is closed. One thing that the Arduino framework brings to the table is a set of routines that enable the programmer to do single bit manipulation of I/O pins without having to know about the port structure. The pinMode()digitalWrite(), and digitalRead() functions make use of a pin to port lookup, and then perform the necessary read/modify write using bit masks to isolate the single port pins. However, doing this yourself directly isn’t difficult, and will result in faster code operation than letting the framework perform a lot of extra work under the hood.  We’ll look at this a bit later.

The port structure of the older Atmega AVR’s consisted of just three registers for each port. For example, considering PORTA, there was the PORTA, DDRA, and PINA registers. PORTA is the output register for the port, each bit corresponding to one of the I/O bits in the port. Setting a bit places a high on the output pin. setting a zero places a low on that pin (assuming the pin direction has been set to output). The DDRA register controls the direction of each bit, a zero makes the port pin an input, a one sets it as an output. Writing a one to the PORTn register when the DDRn register has set that pin to an input will activate the internal pull up, a zero will disable the pull up. Finally, there is the PINn register. This is where we read the input of the port pin. If the PIN direction is set to OUTPUT, then the PINn register will reflect the state of the output, if the direction is input, the PIN register will reflect the actual signal level present on the port hardware pin.

The new AVR processors have the port structure first defined on the XMEGA AVR’s about a decade ago. We now have more registers, and they are logically defined in a C structure. So we have PORTn.DIR (the DDR register), PORTn.DIRSET (register to set the direction to output on a pin), PORTnDIRCLR (register to clear the direction to input on a pin), and PORTn.DIRTGL (register to toggle or switch the direction on a pin).

Similarly we now have the PORTn.OUT, PORTn.OUTSET, PORTn.OUTCLR, and PORTn.OUTTGL registers for outputting to a pin.

Input is via the PORTn.IN registers, and we have also have the PORTn.INTFLAGS, PORTn.PORTCTRL, PORTn.PINCONFIG registers. These latter registers have the interrupt flags, hardware slew control, and pin control (invert, pullup, and interrupt sense options). There are also a few other registers that allow configuration of multiple port bits at a time.

Finally, there are the VPORT registers. There a four of these for each port, DIR,OUT, IN, and INTFLAGS. The VPORT registers allow accessing the ports in I/O space instead of data space. This means using the IN, OUT, SBI and CBI instructions, instead of LD and ST. If you use the VPORT register names the GCC compiler can optimize the generated code to make use of the faster instructions. However, if you are not writing your code purely in assembler, the optimizations of using the VPORT registers may not buy you that much.

Now that we’ve seen how the port structure logic has changed, we can see how to program the ports to act the same way as the Arduino ports. Lets assume bit 0 on PORTA is an output and bit 1 on PORTB will be an input. This might be the same as having IO pin 0 on the Arduino as an output, and IO pin 9 as an input. Instead of writing in the Arduino framework:

digitalWrite(0, digitalRead(9)); //echo state of pin 0 onto pin 9


We can write the following C/C++ code:

PORTA.DIRSET = 0x01; //set bit 0 of porta as output
PORTB.DIRCLR = 0x02; //set bit 1of portb as input

//if PORTB bit 1 is true then set PORTA bit 0
if(PORTB.IN & 0x02) PORTA.OUTSET = 1;
//else clear PORTA bit 0
else PORTA.OUTCLR = 1; 

Note that we must keep track of the ports and bits assigned for each I/O function, while on the Arduino we need only concern ourselves with the absolute pin numbers. However, what you don’t see in the Arduino code is all of the lookup and decoding that the framework must do to act on the required ports and pins, along with masking off the unused bits. There will be MUCH more code generated by the Arduino functions shown than the raw metal coding. Yes, there is one less line of source code in the Arduino version than in our bare metal version. But ours will run MUCH faster and take up less flash space!

Another wrinkle with these parts is the portmux. Rather than hard wiring each of the internal interfaces to specific pins, the portmux allows reassigning them to available pins. This is done by having two or three alternate choices for the Usart, SPI, I2C and Timer output pins. Actually, it’s not possible to make use of ALL of the interface options, as there are fewer available pins than pin functions. It’s the portmux feature that allows you to decide which functions you will be using. Those who have designed systems using any of the ARM micro controllers will be familiar with the portmux feature. Note that the A/D and D/A devices ARE hard wired to specific pins on the part, and are NOT routed via the portmux. The pins used by the analog subsystems can still be used for digital I/O, provided that the analog inputs attached to them are not selected (just as with the older AVR parts).

Right now there are two Arduino boards using the ATmega4809 parts, the Nano Every, and the new Uno Wifi. There is a third party Arduino board package that supports all of the “bare metal” ATmega480x parts (MegacoreX), and a new package for the AVRxxxDA parts has just been released as well (DxCore). Both are still in beta version, functional, but probably with some bugs. Both will support a boot loader, but the use of an external programmer is recommended instead. At the moment, the Arduino IDE supports 3 different programmers (via AVRDude), the Microchip mEDBG which is the embedded UPDI programmer supplied with various Microchip/Atmel dev boards AND the Arduino Nano Every. It also supports the jtag2UPDI, which is a modified Arduino that emulates the UPDI programmer protocol, and the Atmel-ICE in UPDI mode.

For programming these parts using ‘bare metal’ C/C++, you will need the latest version of AVR-GCC with support for the parts. The best way to get this set up on your PC would be to install either Atmel Studio, or MPLAB-X IDE. Atmel Studio only runs on Windows, while MPLAB-X IDE is available for Windows, Mac, and Linux. Both support several Microchip programmers, the SPARK, PicKit4, and the Atmel ICE.

I’ve mentioned the available programmers briefly in my last post.

The Microchip SPARK is a bare board programmer module. It doesn’t come with the required USB cable, or the target cable, you will have to buy the first, and make up the second. Still, the SPARK cost’s only $25, and MicroChip does offer a $10 off coupon for it from time to time. You can download an STL file to 3D print an enclosure for the SPARK from Thingiverse.

The PicKit4 is Microchips’s latest programmer. It will support almost every device that they make, and this includes the PIC, dsPIC, AVR, and SAM families of micro controllers. It costs about $60, and comes with a USB cable.

The Atmel ICE also supports just about every device made by Atmel. It has separate connectors for SAM and AVR devices. Recent firmware updates allow the Atmel ICE to also program and debug PIC parts too. The bare board (no cables) costs about $60. A 3D printable enclosure designs can be downloaded from thingiverse. The basic kit comes in an enclosure, and includes the USB cable, and a suitable target cable for AVR devices. This costs about $100. The full kit includes an additional cable and adapter set for programming SAM devices, this costs $140. If you want to go with the Atmel ICE, I’d recommend buying the bare board, and 3D print your own enclosure for it. It uses a standard micro USB cable, which you probably already own. You can make a target cable by getting a SWD debugger ribbon cable, a 6 pin ISP ribbon cable, and breakout boards for the SWD and ISP connectors. All available from Adafruit.

I have both the Pickit4 and the Atmel ICE, if I was just starting out with these devices and didn’t have a programmer, I’d probably get the SPARK.

Writing bare metal code from scratch can be a bit daunting, at least getting started. Atmel has an online tool called AtmelStart, that will generate a project framework that will get you started. You can import the generated project into either Atmel Studio, or MPLAB-X. You can also just use the provided makefile to build the code using either the GNU tools, or the IAR professional tools.

AtmelStart has you select the development board, or microcontroller chip that you are using, and then pick which interface drivers you wish for it to create. In most cases you are given a choice of interrupt driven, or polling drivers. The Usart serial drivers can be configured to interface with the GCC printf() I/O streams. I’d recommend selecting at least the USART and TWI (I2C) drivers if you intend to use those functions. You can also have AtmelStart build the clock configuration code, this will remove some additional head scratching the first time you try using one of these new parts. I’d probably not bother with configuring the port initialization with AtmelStart. The code it generated required some modification for my use, and I think I did a better job setting this part up from scratch than the framework did.

You should also search the Microchip website for project code examples. I found some very good examples for I2C, and RTC code there.

I’ll be showing some of my example code in a later post. All of my project code will be put up on Github when ready. Right now, I’m experimenting with getting a GLCD driver working, along with a rotary encoder driven menu system, and an Si5351 synthesizer.

New AVR Micro Controllers (part 1)

It seems that many amateur radio projects these days include at least one micro controller in the mix of parts. One of these chips plus some software can eliminate a lot of discrete logic as well as simplify the hardware design of a rig’s front panel by eliminating lots of switches and knobs (replacing them with menu items in the software).

Micro controllers are basically a single chip micro computer containing a microprocessor, read only program memory, random access data memory, and peripheral interfaces (such as timers, A/D converters, serial interfaces such as SPI, I2C, and Usart). Years ago, it would have taken several separate parts to perform the same function. About 40 years ago, I built a micro controller for a ham radio repeater controller and CW ID’er. It used five IC’s including an 8085 microprocessor, 8155 RAM-Timer-I/O, 2716 eprom, plus a 74373 latch, and a 7404 inverter (for the CS logic on the 8155). I could have replaced that 7404 with two resistors and a transistor (but at about the same cost).

One of the first single chip micro controllers was the Intel 8048, followed a few years later by the 8051. Both of these used the Harvard class architecture (as most current micro controllers do), where the program address space is separate from the data-I/O space. These early processors had masked ROM for the program storage, which had to be programmed at the factory during the manufacture of the chips. Intel did sell an EPROM version of the part for software development, but it was quite expensive and required a VERY expensive programming tool (Dataio eprom “burner”). These chips could be used with an external EPROM to hold the program code, but this took 12 of the available I/O port pins away, and required two extra IC’s. Even so, there were 12 available I/O lines left, and you could add an external 8255 I/O expander if you needed more.  At least you could program your own EPROMs with a home brew programmer (à la Byte magazine, Steve Ciarcia).

Another early micro controller was the PIC. This was introduced by Microchip after they had purchased part of General Instrument Semiconductor. The original PIC design was for an intelligent I/O processor for the GI CP1600 16 bit microprocessor series. The original PIC used a highly simplified RISC architecture, and wasn’t very suitable for supporting high level languages such as ‘C’. Some of the current 8 bit PIC controllers (especially the PIC18 series), work well with such compilers, but the PIC12 and PIC16 series, which are closer to the original, are still best programmed in assembler.

A later introduction was the AVR micro controller series by Atmel. The original AVR micro controller was pin compatible with the 8051, including the external bus. The AVR is also a Harvard class RISC architecture, like the 8051. Atmel however worked closely with IAR and GNU to craft an instruction set that would work well with a high level language compiler, so most of the AVR’s can be programmed in ‘C’ or ‘C++’ with little loss in code efficiency. There is even a port of the GNU GCC compiler and binary tools that support the AVR. The AVR micro controller was also chosen by both the Wiring and Arduino line of DIY controller boards that are popular with Makers. The RepRap project based the controller for the early DIY 3D printers on the Arduino.

For the past few years, there has been a bit of a debate among Hams and Makers as to which micro controllers were ‘best’, the PICs or the AVR’s. Their lower cost and simple instruction set are points in the favor or PICs, making them suitable for building them into projects. Atmel’s AVR was somewhat better supported with ‘free’ open sourced assemblers and compilers. Atmel also provided low cost JTAG debugging tools that worked with the GNU software.  You can still get clones of these early JTAG devices on ebay that will work with some of the older (but still available) atmega series AVRs.

Recently, Atmel and Microchip joined forces by introducing support for each other’s micro controllers in their development tools. Microchip eventually purchased Atmel, and today support for the two lines of micro controllers has become even more connected. Originally the development IDE’s offered by both companies were only supported under the Windows operating system on PC’s, however Microchip’s new MPLAB X IDE is available for Windows, Mac, and Linux.

Which brings me to the topic of this post, the latest version of the Microchip line of AVR micro controllers. I hope the rest of this post doesn’t sound like a sales pitch for Microchip, as that certainly isn’t my intention!

Even though both former rivals had introduced 32 bit controllers (PIC32, AVR32, and SAM 32 bit ARM), there hasn’t been a falloff of interest in the older 8 bit controllers. While the ‘bang per buck’ is much greater for the new ARM based devices, the development cost is somewhat higher as is the learning curve. Unless you really need the greater ‘horsepower’, using an ARM processor is somewhat overkill, though it does provide some ‘future proofing’ for your project. Also the ARM Cortex M4 and M7 series even have DSP instructions, making them suitable for software defined radio projects.

What Microchip has done with the new AVR’s is to borrow some of the advanced features that Atmel attempted to introduce with their Xmega AVRs (sadly, the Xmega line has been mostly unsuccessful in the market place). They’ve kept the 5 volt power ability with this new line while allowing them to run at reduced voltage. In fact, the AVR-Dx series can run on anything from 1.8 – 5 volts AT FULL clock speeds!

The new AVR processor families are the ‘megaTiny0’, ‘megaTiny1’, ‘Mega0’, and ‘AVR-Dx’ series. All have the expanded port register set from the Xmega family, as well as many of the peripherals introduced with them. The AVR-Dx series has the bandwidth of the A/D converter increased from 10 to 12 bits, and if two channels are run in ‘differential’ mode the precision can be software enhanced to an effective 13-14 bits.
The new Tiny series are available with up to 16kb of program space in 8,14,20 and 24 pin packages. These will be of interest to those running out of room in their CW keyer projects based on the older attiny85 part.
The atmega0 series are available in 28,32,40, and 48 pin packages, with up to 48kb of program space. The new Arduino Nano Every is based on the atmega4809. This part is even available in a 40 pin DIP package, perfect for bread boarding! These parts run at up to 20mhz clock speeds.
The AVR-Dx series is available in 28, 32, 48, and 64 pin packages, and up to 128kb of program space, at up to 24mhz clock speeds.  It’s available in a 28 pin DIP package (same size as the atmega328). Wow!, a 128kb replacement for the Arduino Uno!

Microchip has some low cost development boards available for these parts. The ones most hams will be interested in are the ‘Curiosity Nano’ boards for the atmega4809, and the AVR128DA48 parts. Both of these fit in regular breadboards, and have a built in hardware programmer / debugger. They are priced at about $15 each (plus shipping), available direct from Microchip, Mouser, or Digikey.
They can be used with a free download of MPLAB X IDE and the MC8 compiler from Microchip. The MC8 compiler can be upgraded (license purchase) to generate more optimized code, but the free version, based on GNU GCC is still quite good. You can also use the GNU avr-gcc tool by downloading the new header files that support these parts from Microchip.
Another useful tool is the ‘Atmel Start’ web page ( This is an online code generator that will construct a project skeleton for you that can be imported into the MPLABX IDE. It will create several header and source files based on the processor chip or development board you select, as well as code for the peripherals you pick to use.

If you want to make your own bread board development setup with a bare chip (28 pin DIP AVR128DA28, or 40 pin DIP atmega4809), you will need a programmer. Here you have a choice of three from Microchip. The least expensive is their ‘SNAP’ programmer (About $25, but sometimes put on sale by Microchip for $15), the Pickit 4 (about $60), or the Atmel ICE ( $60 – $140 depending on options). All three of these will support programming and debugging on PIC, AVR, and SAM (ARM) devices. The SNAP doesn’t support some older versions of Microchips portfolio, but it will support the newest parts (a firmware upgrade via MPLAB X might be required).

I’ve started working with the AVR128DA48 Curiosity Nano. I hope to get it working with a 192×64 graphical LCD, and an Si5351 frequency synthesizer. I’ll post details on this as soon as I get some code written and debugged (which will be posted in github).

The 52 year old project (Part 2)

In a previous post I described the QRP transceiver project found in an old QST magazine.  I had bought that issue at a radio store while I was studying for my Novice license, and still had it stashed away in my library even after moving five times.

The prototype as described by W6DMK (sadly, now a SK) was built in a rather unique project box (no longer available) which allowed the top, bottom and side panels to be removed for access to the internal chassis or circuit board.  The front and rear panels attached to the internal chassis.  In a previous post, I described how to build a similar type of enclosure from printed circuit board material using an old one gallon paint thinner can as the outside.  However, I found a ‘used’ 7″x5″x3″ Bud or LMB minibox in the junk box, the same size as the enclosure used in the article.

This mini box is of the type made from pieces of sheet metal, each bent into a U shape such that the two nest into and around each other to form the enclosure.  The larger ‘outer’ part would become the bottom chassis part, and the smaller ‘inner’ part the upper ‘lid’ part of the enclosure.  Both of these parts had a few holes already drilled into them from its previous use.  The bottom had three holes in what would be the back panel.  Two of these were drilled out larger to accept a 1/4″ phone jack (for the key), and an SO-239 coax connector for the antenna.  The third hole was just the right size for a Phono jack that would be used for the +12 volt power input.

The top of the box had quite a few holes of various sizes.  These were filled in with JB Weld metallic epoxy.  I first cover the inside of the holes with a piece of metal foil (I used copper foil, but aluminum ‘duct tape’, or heavy duty baking aluminum foil attached with epoxy will also work.  The foil is pressed down with a burnishing tool to remove any bubbles.  The epoxy is then mixed up and applied to the outside.  A putty knife or an old credit card is used to apply a thin layer over the holes, attempting to keep any voids forming in the surface.  It takes the JB weld about 24 hours to harden enough to be sanded.  This is done using medium grade sandpaper wrapped around a small chunk of 2×4.  The surface is sanded down until only the epoxy filling the hole remains.  If there are any voids in the epoxy fill, a second layer is applied, and again sanded, this time with a finer grade of sandpaper.  If necessary (usually only for very large holes) a third application of JB weld is applied.

After the holes had been filled in, I drilled any additional holes required for my use.  Then it was time to paint.  The surfaces of the box were rubbed with extra fine grade steel wool, and then wiped clean with vinegar (a mild acid which helps the paint to stick).  If the box is to be painted a dark color,  I would first spray on a light primer coat.  I used white paint for this on the inside top part which was later painted a flat black.  The bottom chassis was painted white, two coats were used.

Here is how the chassis box came out (I actually did this several months ago):

The labels are made with a Brother P-touch label printer.


I mentioned in my last post that I was entering the schematics into Kicad.  I have made some changes to the original circuit, mostly to use parts I already have, instead of parts that are no longer available.  The VFO and BFO circuits were the first to be built and tested.  While the QST prototype was constructed on a single large circuit board (the author didn’t provide a PC artwork, but pointed out that his first prototype was built on a vector board), I prefer to divide up the circuitry into smaller modules which can be tested on the workbench and then built into the finished rig.  This is how Charley Morris ZL2CTM builds the rigs he features on his YouTube channel.  He builds small modules onto strip type vector board, and then solders these modules onto a larger un-etched piece of PC board material.  This is what I intend to do.


VFO-BFO  (pdf download)

The VFO and BFO circuit schematics are shown above.

P1030039Here is the VFO.  The two transistor circuit is built onto a small piece of vector board which is soldered to the rest of the parts attached to the back of the VFO tuning capacitor.  This 365pf TRF type variable is mounted to the front panel by two threaded spacers.  The VFO is quite stable, it only drifted a few tens of Hertz during an hour of being powered up.


The BFO is built on another small bit of vector board.  Wiring and parts are on both sides of the board.  You can see the small wire ‘feet’ that will be used to solder the board to the main PC ‘chassis’.  The wire feet hold the board above the PC ground plane so it won’t short out to it.  Sockets were used for the HC-49U crystal and transistor.  This will allow me to try several crystals to find one that will match the two in the receiver IF filter.


keyer (pdf download)

The transmitter keyer circuit is shown here.  The original used a Germanium PNP transistor to key the +12 volt power to the transmitter.  I’ve converted that to use 2N2905 Si transistors, and I’ve added a switch for the RX +12v as well.  I intend to use a diode signal switch between the antenna and the receiver front end to provide for QSK.  I tried to use the transmitter power switch as a logic inverter for the receiver power switch, but there was too much collector to base feed though from the RX switch that appeared on the TX power line, it would not go below 2 volts on key up!  I therefore added a third transistor to the circuit.


Here you can see the construction of the keyer switch.  This time I used a pad cutter to create ‘islands’ of copper on a small piece of circuit board.  The cutter was purchased from Harbor Freight.  It is sold as a spot welder cutter.  By overlapping cuts, I can create islands smaller than the size of the cutter.


AF-Amp_Sidetone (pdf download)

Finally, here is the receiver final audio stage, and transmitter sidetone.  The original QST version used an unijunction transistor oscillator for the sidetone generator.  These devices are now as rare as hen’s teeth, so I substituted a two transistor multi-vibrator circuit.  The transistors are old Germanium devices salvaged long ago from some surplus computer circuit boards (maybe from old IBM 360’s, who knows!).  I added a volume control to the sidetone, something that was missing from the original.


Again the pad cutter method was used, this time with a home made cutter made from a hex cap head bolt.  To make this cutter I drilled out the cap head of the bolt to make the walls thinner, and then cut 4 ‘teeth’ into it with a Dremel cutoff wheel.  While this type of pad cutter worked, it doesn’t stay sharp long, and soon starts to rip the copper leaving just large holes  instead of islands (you can see two of these failures in the photo).   The HF tool works better, but makes larger islands.

The Keyer switch and the audio board will both be mounted with double sticky tape to the rear and front panels respectively.

Next, I’ll get to work on the receiver circuity.  With the receiver working, this project will really come to life!



Something old is new again

recently dug out the April 1968 issue of QST from my bookshelf.   Hard to believe I’ve had that issue for over 52 years.  The cover story was on building an electronic keyer using what was then ‘state of the art’ RTL logic circuits.  The article included a printed circuit board layout for those wishing to etch their own.  I’m sure the circuit would perform well today (though it’s missing all of the modern features such as message memories, adjustable weighting, etc), but I don’t know if the IC’s used can still be found.  I suppose one could convert the logic to use available 74 series TTL or CMOS circuits if one really wanted to build the thing (would have to re-layout the PC though).

The first article in the issue was for a QRP CW transceiver for 40 meters.  It was all solid state using discrete transistors and diodes.  Most of the parts are still available (mostly 2N3904 and 2N3906 silicon transistors), though the few germanium PNP and the one unijunction transistor will be unobtainum today.  Still it looked like an interesting build, and I knew I had the older hard to get parts in the junkbox (365pf TRF capacitor and slug tuned coils).

The crystals called for in the BFO and IF filter are available in HC49/u microprocessor clock frequencies, and I have some in the junk box.  I will substitute modern ceramic trimmer caps for the old style compression mica units called for a half century ago.  There are better RF power transistors available today then the ones used in the article, and I’ll re-design that part of the circuit to eliminate the compression trimmer tuned Pi network tank circuit, and use toroid ferrite transformers along with a two or three section LPF instead.  I’m leaning towards an IRF-510 MOSFET in the final, a single transistor will put out more power than the 2N2195 the author used.  I’ll also replace the germanium PNP transistor used in the T/R switch (keying) circuit with a P-ch MOSFET.  The uni-junction audio sidetone oscillator will also go by the wayside, here I’ll probably use an 555 IC, which is almost as long in the tooth as the UJT.

The original rig didn’t have any switching logic for transmit / receive, the antenna connected to both the receiver input and transmitter output.  This worked since the receiver was lightly coupled to the transmitter tank at a high impedance point via a small (10pf) capacitor, and at the 1 watt power level there wasn’t enough RF fed back to blow out the receiver RF transistor.  I will add some diode switching in the signal path, and will switch the receiver power off during transmit.  It should be possible to obtain very good QSK.

It quickly occurred to me that this little rig would also work fine on 30 meters, which might actually be the better band.  If I replace the 5 mhz crystals with 8 mhz ones the circuit will cover the 30 meter band without changing the VFO.  The 5th harmonic of the 2.0-2.3 mhz VFO does fall into the 10mhz band, but it shouldn’t cause any birdies as the actual mixer products seem to just miss the band “by that much”.   I’ll have to use T38-6 cores instead of the T38-2’s to modify the rig for 10.1 mhz.  If I build everything but the VFO, audio amp, sidetone oscillator, and T/R switching logic  on one circuit board, I could try out both versions with the same setup.

I’m working on the new schematics now, and I’m teaching myself how to use KiCad in the process.  I’ll post the schematics here in a later post, and will also provide a link to my Github where I’ll have the KiCad files.   If anyone wants to duplicate my folly, they will find that except for the J.W. Miller slug tuned ceramic coil form,  TRF 365pf tuning cap, and vernier dial in the VFO all of the parts will be ones you can actually buy today.  I am keeping the PNP germanium transistor in the AF output stage to drive a pair of ancient magnetic headphones, but I’ll show how to use an LM386 instead to drive your iPod or cell phone earbuds.  You’ll have to deal with ebay for the VFO parts.

Crystal Control

got my novice class license back in February 1970.  Back then novice class hams were limited to CW operation on portions of the 80, 40, and 15 meter bands.  By this time voice privileges in the 2 meter band had been withdrawn.  The purpose of the novice class license, created in 1951, was to allow the applicant to increase his (or her) CW skills via on the air practice with the goal of upgrading to a general class ticket.  The novice license was granted for a one year period, and was not renewable.

I upgraded to an Advanced class license within six months of getting my novice license.  The FCC had announced that license fees for the amateur service would be going up for the first time in several decades, from $4 to $9.  With that incentive, I studied the written test questions for both the general and advanced class exams, and managed to copy CW at a solid 15 WPM, a sizable safety margin.  I made the trip down to the NYC FCC office in lower Manhattan on the last day that the $4 license fee would be in force, and I managed to pass the 13 WPM code element, and both the general and advanced class written elements.

Since then, both the novice and advanced class licenses have been eliminated (though anyone holding such  tickets could renew them forever).  The privileges allocated to both of these license classes still apply, how strange that the only way a general class licensee can now gain privileges in the advanced class band segments would now be to obtain an extra class ticket!  I was in a special league here.

Even more recently, the CW requirements for all ham licenses have been removed (thought the CW band segments remain, now shared with new ‘digital’ modes that don’t require CW knowledge).  Since I’d never increased my abilities in CW beyond the 15 WPM plateau (and have probably gotten more than a bit rusty as well), the extra class license had remained an elusive goal.  However with the CW requirement now history, it was within reach.  The written test for the extra was a cinch for me, having a BS degree in electrical engineering.

Nostalgia is a strange beast.  The recent resurgence of home brewing has resulted in many hams building simple QRP rigs.  What is QRP?  Back in the early days of CW when power tubes were scarce and expensive, anything over 100 watts was considered QRO (high power).  If you operated with less than 100 watts, that was QRP.  With the onset of SSB, building a legal limit station became easy.  You no longer needed a heavy, expensive modulator (which was actually a very high powered audio amplifier, about 500 watts worth).  The same tubes that were in the old modulator, plus an additional copy in the final amplifier (2+2 = 4) would run the legal limit, no modulation transformer required.  But it was also discovered just how well SSB cut through the QRM and QRN compared to AM.  You really DIDN’T need the full gallon (most of the time).  The 100 watt output of the average transceiver was more than enough (except for the contest nuts or DXCC hunters).   Today, a new term has come up, QRPP.  If QRP means a 100 watt station, then QRPP would be < 10 watts.

I’ve collected quite a lot of parts over the years.  Even though I’ve pruned my junk box of a lot of the old tube related stuff, I still have a good assortment, including some old NOS octal tubes.  Why not build something that would be a throwback to the novice days?  That would probably mean a crystal controlled transmitter.  There is a problem though, have you checked to see what those old FT-243 crystals cost these days?  Even back in the 1970’s, with quite a few crystal houses still turning out such crystals for the novice class, the supply was mostly made from re-processed WWII surplus.  Needless to say, that supply has dwindled down to a trickle, especially since the demand slackened off following the removal of the crystal control requirement for the novice licensees back in the 1980’s.  As a result, FT-243 crystals on Ebay often fetch upwards of $20 each, especially for those in the heart of the amateur QRP CW band segments.

Looking in my junk box, I see that I have quite an assortment of these old crystals, few of which are cut for amateur frequencies.  I do have some crystals that could end up in an amateur band if used on their second or higher order harmonics (especially for the ‘newer’ WARC bands).  I also have quite a few more that could be made to work by grinding or etching them higher in frequency.  THAT will be my next project.  If I succeed doing this, I will then consider building a simple tube transmitter and receiver (more on that in a future post).

I’ll go into the process of re-working those old crystals in a future post, for now I need a way to test all those old crystals.  I need to separate the good ones from the dead ones.  (Actually the first two ‘dead’ crystals I discovered were only dead because one of the two pins had become electrically ‘open’.  Moving the actual crystal into another case brought it back to life.  I can repair the broken crystal holder).

A search on the web found a project by W5USJ on for a crystal checker.  This gizmo includes a test oscillator, a crystal activity indicator, and a frequency counter.  I didn’t need the frequency counter, I already own an old Leader 250 mhz counter.  I did need the test oscillator however.  The circuit of this tester, as I built it, plus some pictures of its construction are shown below:



The circuit contains an oscillator (Q1), an activity indicator (Q2, two small signal diodes and an LED indicator), and a buffer amplifier (Q3) to drive an external frequency counter.  I added a 5 volt regulator (7805) so I could power the tester from a 9v ‘wall wart’ or a 9v battery.  I built mine on a small copper chassis I made from a scrap of copper plate (from a hobby shop).  The transistors are mounted in sockets (salvaged from old TV set PC boards).  While PN2222 and 2N3904 transistors are specified, really ANY common small signal silicon NPN transistors with an FT of 150 mhz or more can be used.  I have metal cased 2N2222’s in the oscillator and indicator positions, but the 2N3904 would work there as well.

Operation is simple, connect power (the red LED should light), and plug a crystal into the socket.  If the crystal is oscillating, the two diodes will rectify the signal and develop a turn on bias for Q2, which will the conduct lighting the green LED.  Transistor Q3 along with the diode from its base to ground will square up the signal to provide a clean waveform to drive a frequency counter.  The circuit as designed by W5USJ included a PIC microcontroller programmed as a frequency counter good for up to (at least) 10 mhz.  He didn’t provide the source code, but I’ve seen other examples of PIC frequency counters on the WEB if you need one.  (   I just use my Leader LDC-823S I bought used many years ago.

Note that 6740 khz crystal in the socket.  I intend to try and move that (and a few others like it) into the 40 meter CW band.  Many years ago as a novice, I did mange to move one surplus crystal a few hundred khz higher in frequency.  Several others were ‘bricked’ in the attempt.  I’ve later read about using an etching solution to chemically thin down crystals, a process that should offer a higher rate of success.  We’ll see.  I have some etching solution on order.  I’ll report on how this all works out in a part two.  Stay tuned.


The Art of Soldering (PL259 to RG8/U)

The other day I finally installed the 2 meter J-Pole I’d bought late last year.  I made use of a run of coax that had been used for a dipole antenna, and I had cut the run shorter to use the minimum amount of cable between the shack and the antenna.  So, I had to solder a new connector to the feedline in the shack.

Technically, it’s not RG8/u, but rather RG/213U, which is the modern part number.  Still, old time hams have been calling the cable RG/8U for decades, and as both part numbers look the same from a few feet away,  a rose by any other name ….. to quote the Bard.

Attaching the common PL259 UHF connector to this 1/2″ cable looks simple, until you actually try to do it.  The cable is thick, and not very flexible, and difficult to handle.  The operation of striping the insulation and tinning the copper braid is a messy operation with the thick cable fighting you all the way.  Over the years, I’ve figured out a method of taming the beast, and produce a good strong and perfect electrical and mechanical connection between the ancient connector and the coax.

I really don’t know why new amateur (and CB) gear continue to use this relic from WWII, but the PL259 (and it SO-239 mate) just refuse to die.  You’d think that the superior N type connector would have supplanted it by now, but alas no.  Not that the N connector is any easier to attach to coax, but it is simpler to solder to, and has a lower SWR bump, especially above 30 Mhz.

Anyway, the first thing I do is to strip about 1.5″ of the outer insulation off of the cable to expose the copper braid.  Normally, you’d then cut the braid back to size (about 1/2″) and the tin it, however that will leave rough loose ends of braid about, ready to end up inside of the completed assembly to short it out.

So what  do is to tin about an inch of the braid from the outer insulation towards the end of the cable.  First smear a good amount of rosin flux on the braid and then melt a thin layer of solder on it.  Use a Weller soldering gun, NOT a wimpy pencil or iron.  A 140 watt or higher gun is ideal, though I have been able to get good results with my old 100 watt Weller Junior gun.

After tinning the braid, I file off the excess solder to leave a smooth evenly tinned braid with no solder lumps.  Now we will cut the braid back to 1/2″ in length.  The ideal tool to use here would be a tubing cutter.  I’ve used  a pipe cutter for this with good results, but you have to be careful to only cut through the braid, and not all the way though the insulation to the center conductor.  I’ve also got good results with a hack saw, or a jewelers saw.

Next peel away the rest of the braid to leave the center insulation and conductor.  About 1/16″ from the end of the tinned braid cut away the center insulator to expose the inner conductor.  Twist this some and then tin the end and cut it just long enough to stick out of the connector.  Use the connector as a size guide.  Now slip the connector clamping ring over the cable (with the open end towards the end of the cable!), and screw the connector on to the cable.  You should see the tinned braid through the four holes though which you will solder, and the center conductor should be sticking out the front by at least 1/8″.

File or sandpaper the connector where you will be adding solder to remove any corrosion that would result in a bad solder joint, and then wipe on some rosin paste flux.  Use a small vise to hold the cable while you solder the connector to the cable at the four body holes, and the center connector.  Trim the excess center connector off, and touch up the soldering here.  Now screw on the clamping ring (You DID remember to slip it on on the cable the right way didn’t you?), and the job is done.  A thing of beauty forever.


Computer Build part 2

So my parts arrived and I’ve done the initial POST test.  Hurrah, it all works.  I’ve downloaded the current Alpha build of the future Kubuntu 20.04 LTS (the final release will be sometime in April, as the release version name indicates).  That seems to work too.  I’m still not too sure about the video card though.

I bought two different cards, the first was a 2GB Radeon R7-250, and the second was a EVGA GeForce 8400 GS.  Both are older, single slot cards that while no longer recommended for gaming, will handle the usual office applications and Youtube videos just fine.  They both also have enough resolution for CAD work, so I’m covered here.  I wasn’t interested in building a gaming rig.

The Radeon card came from Ebay, as a Dell overstock item.  It has two outputs, one DVI and one Displayport.  In theory, it should drive both outputs, but so far I haven’t been able to get anything out of the DP  I’ve read online that the card defaults to the DVI output until a driver is loaded, and at least in my case the MB bios does not display anything out the DP, even when its the only one connected.

I haven’t yet tested the GeForce 8400 yet in this regard.  Obtained from a B stock sale on EVGA’s website (for only $10 and free shipping), it has three outputs, one HDMI, one DVI, and one VGA.  With monitors connected to the DVI and VGA  ports I only get output under the BIOS setup from the DVI, but I didn’t try that with ONLY the VGA connected.  I do get dual head operation under Kubuntu, so even the open source drivers can handle this.  I don’t yet know if I can drive both digital outputs (DVI and HDMI) at the same time in dual head mode, I’m still waiting for another HDMI cable in the mail to try that.  I did get an HDMI to DVI adapter, but it won’t plug into the card along side the DVI cable as the sockets are too close together.  I can always use the DVI and VGA outputs, as my monitors will handle that, but I’d rather not use the VGA inputs as they probably lose a little bit in signal quality over the Digital inputs in full HD resolution.

I also have the older Nividia dual head card that’s in my current computer.  It only has 512gb of ram, but does drive dual DVI outputs to full HD.  It’s good enough, but I was hoping to get a cheap, more modern GPU running on the new machine.

Now to answer the question of why I chose the other stuff that I did.

1: CPU:  Short and simple, I’ve always liked AMD for being a bit better in the bang for the buck, and for being a smaller target for the malware writers.  Their new Ryzen Zen processors are currently the best price vs performance available, sorry Intel.  The Zen 2, Ryzen 5 3600 is actually at the bottom of the current heap (except for the Ryzen 3 3200G, and the Ryzen 5 3400G APUs).  I drew a $250 line in the sand, and the CPU I picked clocked in at $180.  The next one up was the slightly faster Ryzen 5 3600X, offering a bit higher base and boost clock rates, but not worth the extra $50 IMHO.  The Ryzen 7 CPUs which have 8 cores and 16 threads (vs the 5’s 6/12) start at about $310.  If I ever need more power later on I can upgrade to this point, and then there are the Ryzen 9 processors that go up to 12 or 16 cores!

2: Motherboard:  My price line in the sand was about $100.  This pretty much limited me to a B450 chipset, and a uATX format, but I’d already settled on the smaller sized board because I wanted to use the case that I’d salvaged from an old Lenovo machine.  There are plenty to chose from with these parameters from MSI, Gigibyte, ASRock, and ASUS.  Most of these will have one M.2 PCIex4 SSD slot (usually with this chipset if there is a second M.2 SSD slot it will be SATA3 based).  I chose the MSI board mentioned as it fit my price range, and also included board headers for both a COM port, and a PARALLEL port.  Both of these are useful for driving micro-controller development tools.

3: Memory:  As I wasn’t going to sink extra money into a high end video card, or a more powerful processor, I decided to get the most/best memory I could afford.  I budgeted about $150 for the ram.  I did run over that by $10, but spent only $80 on the MB, so we’re not over budget.  Crucial recently (just a week before I placed my order) announced a new line of their Ballistix gaming memory in 2667, 3000, 3200, and 3600 mhz speeds, with and without RGB LEDs (WTF?).  AMD recommended 3200 mhz speed ram as the sweet spot for the Zen 2 processors, so I decided to go with that.  I ordered a 32gb kit (two 16gb modules) which is probably overkill by double what I REALLY need.  However, I do intend to run Windows 10 in a VM under Linux, and having the cores and ram to throw at it I’ll be able to run any micro controller development tool that isn’t available for Linux in a large enough sandbox.  Atmel Studio, that means YOU (you G-D resource hog!).



Building Computers

First of all, I’m sorry for being off the blog for an extended period of time.  I’ve been recovering from mitral valve repair heart surgery (in November)

Since 1995 or so, my ham shack personal computer has been one I’ve built from purchased parts, rather than an off the shelf machine.  During this time I’ve mostly used AMD processors, though a few machines did use Intel CPUs.  My current computer is a factory reconditioned Dell purchased from Ebay (Intel Core-i7), although it’s been upgraded with a new video card, power supply larger hard disk, and an SSD boot drive.  (Running Kubuntu Linux, it has the net-name of “ThePenguinInTheDell“)

The first PC I ever built was an upgrade to a PC-XT clone.  On that one I changed out the mother board for one with an 80386SX processor (I later moved everything into a larger case).  I then progressed to an AMD K6-233 in an AT Tower case, later upgraded to an Intel Pentium III-500 (mother board swap).   My next build was an Intel Pentium-III 833mhz this time in an ATX format ( later upgrading the processor to a 1 Ghz version). The next few builds were AMD Athlon and Athlon-64 based, with the final in this series using the Phenom-II 4 core processor.

Building your own computer might sound like rocket science, but it’s not.  The only tools you will need will be a #1 Philips screwdriver, and maybe a suitable sized nut driver.  An anti static wrist strap (which might be easier to use on your ankle) is also a good idea.  The hard part is in selecting compatible parts that will actually work together.  Obviously you must use a motherboard that has the socket and chip set that is compatible with the processor you intend to use.  The on board BIOS version must support the version of the processor, or you will need a way to update the BIOS.  You must also select suitable memory.  Any motherboard purchased today will be using DDR4 memory (unless you are building a ‘retro’ machine with an older processor and motherboard).  Getting the right memory process isn’t enough, the speed, voltage, and timing parameters must match the processor and chipset being used.  Sometimes memory that works on an Intel board won’t play with an AMD one (and visa versa).  If you buy your memory from Crucial, their website can help select the correct modules for the motherboard/process you are using.

Recently I decided that it was time to look at moving on to newer tech in the computer department.  AMD now has their Zen Ryzen processors in the third generation, with the fourth gen parts due out this summer.  The Ryzen 5 3600 processor I selected is a 6 core, 12 thread CPU with clock speeds starting at 3600 Mhz, and capable of being burst mode, and overclocked past 4 Ghz.  I selected Crucial’s new Ballistix memory at 3200mhz speed, getting 32 gigabytes (two modules).  Ebay provided a nearly unused M.2 256gb SSD for the boot disk, and I’ll probably transplant the 2gb SCSI III hard drive from my current computer to the new one (which contains all my user data files).

I selected an MSI B450M pro-vdh-max mother board, and I had a suitable mATX mini tower case salvaged from an old Lenovo Think-Center computer.  I know that Chineseium computer cases can be had for cheap, and the new case designs do offer improvements in air flow, and cable management, but the old Lenovo case is a ‘looker’, and it sports two 5.25” drive bays suitable for an optical drive, and a built in SD card reader / USB hub.  I had both of these items salvaged from previous computer upgrades.

The final item needed was a new video card.  I could use the current 256mb dual DVI PCIe card in my current computer, but I found an EVGA “B” stock Gforce 8400 GS on sale (on EVGA’s website) for only $10, with free shipping.  This card sports 1GB of memory, and DVI / HDMI outputs.  It will take an adapter thing-a-ma-gig to connect the HDMI output to my monitor’s available DVI or DP input, but otherwise it should work fine.

Kubuntu will release their 20-4 LTS version sometime in April, and that will be the OS I’ll install on the new PC.  In the meanwhile, I’ll be testing everything to make sure it all works.   I’ve already managed to do the initial power up and POST tests.  It all worked, except for the AMD R7-250 video card that I had originally planed to upgrade my current machine with (to fix a driver problem with the Nivida card).  It seems that this AMD card defaults to the DVI output, and won’t drive the DP output without the proper driver setup.  The motherboard BIOS doesn’t know how to talk to the DP output.  I could probably get this to play eventually, but I now have the option of using a Nivida card that should work.