I currently have a project where I’m using an Atmega328PB in a TQFP package to act as a customized i2c port expander for the main microcontroller. Since the firmware on this is pretty simple and shouldn’t ever need to change I figured I shouldn’t need to put a programming port on the PCB. Of course, that meant I would need to program them before soldering, so I searched around and found this thing. I put together the programming circuit on some perf board, and now I can just pop the chips in, program them all, and have them ready for soldering. I hadn’t seen a socket like this for a TQFP package before, so I thought I’d share.

I don’t quite understand the reasoning for the stacked PCBs; the resulting layout is super awkward to use with a breadboard, and there are 8 extra pins that aren’t connected to anything. I might put together a more logical PCB layout for it in the future, but for now it is functional despite its quirks.

1 Like


oh man. Socket selection can make or break you in my job.

Check out loringers website when you are bored http://www.loranger.com/loranger_edc2/html/index.php

There is a socket that fits every common part… but if there isnt then companies like goldtech will make one for you.

For a price.

Is that the only job for that Atmega? If so, why this and not a purpose-built I2C port expander IC?

Valid question. It’s reading an array of switches, so it has to loop through writing to the rows while reading the columns. I could have done it with a standard port expander, but with the Atmega I was able to offload the logic for reading the array and just send back which switch number was pressed. Familiarity also factored in, as well as the fact that the Atmega is interestingly cheaper than any of the port expanders with 20+ pins that I found.

1 Like