The New Firmware

Illustration

With all the changes in the AuxPower1U project, it was inevitable that firmware will change too. However, some changes were in order.

First was in regards to my PhotoMOS setup. While 6A AQZ202G PhotoMOS supports all I need, I only had 2 of them handy (actually, I started with 3, but we won’t discuss my testing procedures). So, I filled rest of channels with 4A CPC1706Y PhotoMOS. Why am I mentioning hardware in the firmware part? Well, part of my firmware is handling safety cutoffs. And those are not the same between all channels now. Yes, these are still hard-coded because I am too lazy to create GUI. But they are separated into a function so changing them shouldn’t be a chore. The first three channels have 4A safety limit while the last two have full 6A.

Another change was turning off display after a period of inactivity. While having it always visible was handy, it did cause degradation in cheap displays. After months of having it on with the previous display, burn-in was becoming a problem. Since I rarely check that display, it seemed like a good idea to simply turn it off until button press is detected. Cheap firmware solution for a hardware problem.

And lastly, I changed how output pins are handled. Originally, I handled them via I2C expansion which works like a charm. But, that introduces an extra device in what you might call a critical path. Since, due to other changes, I did have 5 pins available, in the new revision output is controlled directly from microcontroller without going to the expander board. As to preserve compatibility with the previous board, code sets both I2C and pins directly. That way both revisions can work on the same firware.

With all this, my AuxPower1U revision C was ready for “production”.

The New Controller

Illustration

With the new case sorted out, I decided onto a new power supply controller. Since I recently ended in the possesion of a few PhotoMOS device, I figured to check them out. While my own high-voltage MOSFET switching does work, there is no real isolation between my control circuit and the output voltage. PhotoMOS brings that additional safety.

Changing to AQZ202G PhotoMOS required a major PCB redesign. Fortunately, controlling PhotoMOS was trivial and thus most of time was just figuring how to lay things out without changing PCB size. After hours of “playtime” in KiCad, I sent the new PCB toward PCBWay to manufacture.

Once I got my boards back, I decided to first test it with a cheaper CPC1706Y PhotoMOS. I though yhe only difference between Littelfuse and Panasonic ones was the maximum current. Panasonic supported 6A (which I needed for my 65W PC connectivity) while Littelfuse PhotoMOS supported 4A. Since my fist three power channels were low wattage, I opted to use CPC1706Y for them, reserving AQZ202G for the channel 4 and 5.

And all channels worked flawlessly. Heck, channels CPC1706Y worked even when they were supposed to be off. At first I though it was due to firmware changes I did. But, an embarassing amount of troubleshooting later, I noticed that there is one more difference between Panasonic and Littelfuse. Panasonic uses bidirectional MOSFET switch. Littelfuse does not.

That means that Panasonic doesn’t really care which connection is more positive. And, since I used Panasonic to create KiCAD footprint, I opted for easier routing. But Littelfuse cared which connection is more positive and I selected wrong. Well, after another hour or two of moving traces around I was ready for another go.

Illustration

Since PCBWay has an action going on where you could get a purple PCB for no extra change, I decided to try it out. And, while coloring PCB is a gimmick without impact to electrical design, over time I grown to appreciate it. With PCBWay offering multiple colors, I always alternate them between orders allowing for easier distinguishing between revisions. It’s way easier to tell whether PCB is purple or yellow at a glance, than if revision is C2531 or C2536.

Combinination of purple PCB and white silkscreen is a really a classical one in a hobbyist circles and PCBWay doesn’t disappoint here. While it is slightly lighter shade of purple than OSHPark, solder mask is of equally same high quality. It handled my clumsy soldering like a champ. :)

All in all I am mostly happy with the new PhotoMOS solution. As compared to my MOSFET switching it offers way better isolation from the rest of my circuit. Heat is about the same which is not surprising. However, when it comes to cost, there is really no competition. Darn PhotoMOS devices are EXPENSIVE. If price is a major consideration, it’s a no-brainer to roll-your-own.

For my AuxPower1U controller, I think I am going to stick with PhotoMOS. They do offer isolation and they are much easier to control. And, since this project is not cheap due to quite expensive power supplies, increase in cost is bearable.

New case for AuxPower1U

My AuxPower1U project was over and all was great. But, one thing always annoyed me - the plastic enclosure. Don’t get me wrong, it is a nice enough enclosure when mounted. But, since power supplies do weight a lot, chasis flexes if unsupported. Not a big issue but not something I like. So, when I ran into a Cheval PF19AL1UD1, I immediately started eyeing an upgrade.

Illustration

It is a 1U case, a slightly longer than Bud PRM-14460 - 200 vs 240mm. It has ventilated sides in addition to vented top and bottom plate. And it features internal box design with rack mounting being a separate element. While this might be excellent for some projects, I had a few issues with it.

The first issue was it’s box construction with rack mounting being a separate element. Since I needed to drill the front, this was annoyance. Thus I decided to simply omit front extrusion when mounting it. That way I only needed to drill one set of the front holes. As this change made top and bottom flimsy, I had to redesign aluminium plate mounting to stiffen it a bit. Once buttons are mounted, there should be no play.

Another issue I had was with vented top and bottom. While usually a great feature, they were killing my air flow setup. At the end, I just covered them from the inside with a wide duct tape so that air is forced over power supplies.

As luck would have it, all mounting solutions I did for the previous case would not fit this one. Aluminium plate couldn’t rely on central bosses because there were none. Also mounting controller and fans had to change too because there is now no real place to screw it. Mind you, mounting options are probably even better now - there are enough M3 holes available.

In the end, it took a few hours of reacquainting oneself with FreeCAD to get everything in place. And I believe it was worth it. Metal case just feels much better than the plastic one it does offer way more space because there are no protrusions in the middle the plastic case needs.

That said, it is more compliated to work with than the plastic. First of all, drilling is much more work. And, since there will be live AC power in it, grounding case properly is a concern. With powder coated case this means a lot of scraping to expose metal. Nothing too difficult but important not to forget.

But drilling and grounding is a problem for the future me.

Enabling Kubuntu Fingerprint Support

After installing Kubuntu on my Framework laptop, I found all hardware was fully supported. It took me a while to notice that my fingerprint scanner was missing. Mind you, hardware was supported but KDE simply didn’t show interface to use it. Well, we cannot have that.

Illustration

Fortunately, enabling fingering is as simple as running two commands.

sudo apt install -y fprintd libpam-fprintd
sudo pam-auth-update

The first command installs software support, while the second command allows usage of the fingerprint for authentication. However, on Kubuntu you will notice that this sometime works, sometime not. The way the default files are written (/etc/pam.d/common-auth), the first failure will result module being ignored until password is entered. If you want a bit more permissive fingerprint handling, you can adjust max_tries a bit.

sudo sed -i 's/pam_fprintd.so max-tries=1/pam_fprintd.so max-tries=3/g' /etc/pam.d/common-auth

And now you have it, a fingerprint support that allows for some leeway.

AuxFanControler, a New Revision

As part of my AuxPower1U project, I already build a stand-alone 4-channel fan controller. And it works perfectly even now. But I did notice some issues when trying to use it as part of other projects.

The first issue was it belonging to AuxPower1U Git repository. There was nothing wrong with that but, since I used it for other projects too, it seemed right for it to get own repo. And its own repo it got. While I will keep it compatible with AuxPower1U, each can change separately.

The second issue was its dimensions. Even though I would argue you cannot get 4-channel fan controller with those connectors in much less space, reality was that vertical mounting was impossible in 1U chassis. Not only that its sideway power entry made wire routing particularly bad in vertical scenarios but it also meant that total height was cutting it close for even 2U case. Reducing the PCB height was an obvious choice and while trying to figure out the layout, I decided to drop one fan connector. This allowed me to reduce size from 69x15mm to more reasonable 42x15mm. Just barely fitting 1U if we ignore sideway cable entry. And ignore it we can because I also adjusted connector to allow for mounting either vertical or horizontal connector. Yes, you will have one footprint unpopulated but that’s a small price to pay.

A third, minor issue was that board was hard to mount. For this I intentionally left back front side empty and with a bit wider side margins. This allows one to create slot in plastic and thus keep the board embedded with friction alone or, if needed, with just a touch of plastic. How that mounting looks like you can see on example of the new AuxPower1U board (that I’ll cover a bit later due to scheduling carfufle). Board sits between 2 fans and goes nowhere once slotted in.

Illustration

I got PCBs from PCBWay and it arrived quite quickly. More importantly, its edges arrived cleanly cut. This is not something one notices unless they deal with some other PCB providers. I love OSHPark but them leaving tabs in place drives me crazy. Every time I get their boards, I have to spend minute or so per board filing those tabs down and it’s never fully straight edge. With PCBWay at least that task is of my back.

Also, compared to OSHPark they have way wider color selection. You can chose green, red, yellow, blue, white, or black for the same price. This allows you to distinguish boards at a glance. For this order I opted for the yellow soldermask which is not my favorite when it comes to reading slikscreen but it is rather nice otherwise. If silkscreen legibility is at premium, either red or blue are better choice. But that is the beauty of choice. You can find what works for you in any particular scenario.

Premium colors like purple, matte black, and matte green do come at a greate cost. However, they do ocassionally get a discount so its worth checking them out from time to time. For example, purple is going to be available at standard $5 price in September so you might want to check it out. Speaking of discounts, 3D printed TPU will be heavily discounted in September too so you might want to check it out. As somebody who printed TPU, I can only recommend you get somebody else to do it. :)

Illustration

Soldering this PCB was a bit more difficult as compared to the revision A because components were a bit more pushed together. But that’s just relatively speaking - I am still using rather generous pad size so it should be easily doable.

Profile is similar to before but with a bit more agressive curve between 60-70 °C. This is something I plan to make configurable eventually but I don’t really have reason to do so right now.

Startup sequence is still powering fan at a time with a quick spin-up to 100% before settling down. Firmware itself still behaves as if it has 4 channels which makes firmware the same between revision A and B.

It’s just a small update but form factor change alone will allow me to use it in way more places that require stand-alone fan control.