A portable phone sleeve to keep your device charged all day long.
Gerber files, generated in Altium CircuitMaker
x-zip-compressed - 43.38 kB - 08/07/2018 at 19:12
Drill files, generated in Altium CircuitMaker
x-zip-compressed - 2.06 kB - 08/07/2018 at 19:12
Got it up and running! After a good day's work fixing my soldering, writing some test software, debugging, scoping, etc. I have a working circuit board and very basic firmware.
And...it looks like this now:
So... the inductor. Obviously this isn't what I had in mind. I guess I was too excited to get a board ordered to actually calculate the inductance I needed in the buck converter. My original was a 1 uH inductor. This is what was called out for the boost module, so I figured the buck had similar needs and could use the same inductor.
Which is obviously wrong. The boost module has a switching frequency in the megahertz, where the highest I can get the microcontroller to do is 320 kHz (160 kHz if I need 100 steps of PWM).
So I scrounged and found the big through-hole inductor shown, and got that to work.
In other news, turns out I misinterpreted the rules for the one-square-inch challenge (or they changed the rules all the sudden?). They want the entire board to fit, including the components. This doesn't fare well for my big USB-A connector hanging off the edge of the board.
The USB connector needs to be there; it'd be stupid to not have it, given the board's intent is to be a USB charger. I could move it off the board, but that's not a clean solution. I have enough flying leads already.
So how to fit the connector within my square inch? My first thought was a vertical connector, but that makes the positioning awkward. So I think the solution is to switch to a surface-mount connector and put it on the back of the board. This makes the board thicker, but I think it'll work if I keep all the big parts on the bottom.
I'm a little upset that I have to redo much of the layout to make this work, but I guess they call it a "challenge" for a reason. And I have to redo a good chunk of it to fix my footprints and get a bigger inductor on there. Maybe I'll even have space for some more input capacitance.
Anyway, I should have enough time for a respin. Next step is finishing up the firmware, doing some testing, then I can respin and get a nice final product.
And speaking of firmware:
80% data memory usage already? (tugs collar nervously) I can safely say I've never pushed a microcontroller this close to its limits.
I quickly found the first issue with my PCB. I have to admit, this was a pretty stupid mistake.
Note the numbering order. It's clockwise, but should be counter-clockwise. This means pins 1 and 3 are swapped, as are pins 4 and 6. What I was thinking when I thought the numbering should be clockwise is beyond me. I assume I was looking at a drawing of the underside of the part when I was doing the pin order.
At first I thought that was it. There's no way I could fix a layout that tiny, I'd have to reorder the board. But, with some really careful cut and rewire, I managed to do the pin swapping and verify that all the new connections were good. Felt like a freaking superhero when I finished, too.
See part is in the bottom-center. It's certainly not ideal, but besides the excess flux the repair is barely visible and should hold up. Hopefully the tiny wires I had to use won't add too much resistance.
Hopefully the rest of the assembly goes more smoothly.
While I wait for my boards to be delivered, I spent some time working on the mechanicals. I've been 3-D printing for a couple years now, but this project made me want to try something new: Flexible Filament. I ordered some green TPU from a brand called Priline.
I designed this as sort of a phone pocket, with extra width so that the front would fit the solar panel. Some space is cut out of the sides for the battery and charger circuit.
I designed this in Fusion 360. Here's a link to the design: https://a360.co/2MyXXA5
Here it is after a couple revisions:
One problem that I came to a neat solution on: sealing in the battery and charger. Eventually I got the idea of using the solar panel itself to close up the "box" that the other parts go in. This saves material (weight) and makes everything a lot simpler.
I printed out an early revision to test the fitting. Most of it is encouraging, but I found a lot of things to change. Printing with flexy filament went pretty well once I dialed in the heat settings (reducing the print bed temperature did wonders). But, as expected, the stuff doesn't bridge well, so a part like this takes a quality hit.
Here are my parts layed out...
My PCBs just arrived from OSH Park. They look like they might be a little tricky to solder, but I'm up for a challenge. These are the first revision boards that have a length just a hair over one inch, though I already designed a revision that fits in a one inch square. Next up: build and test this thing.
The miniSolar is designed to take in power from a 2-3 watt solar panel, charge a small lithium battery, and charge a device. Since USB devices tend to draw a constant current, the battery buffer is required to supplement the solar power when it's insufficient to charge the device by itself. This has the additional benefit of allowing the solar panel operate at full efficiency to charge the battery when the load is low.
A microcontroller is used to run the converter with Maximum Power Point Tracking (MPPT). It also contains logic that can enable or disable the USB output, preserving the battery and allowing intermittent operation when the solar input is lower than the demanded load.
The intended mechanical configuration is to build a "pocket", with the solar panel as one side, the electronics at the bottom, and space inside for a phone or other device. This way the miniSolar doubles as a phone protector.
At 21 components, this is definitely one of my simpler designs.
This circuit contains:
I designed the circuit and PCB in Altium CircuitMaker, my hobby tool of choice. I hold Altium as the gold standard of user interface, and once you've gotten used to it it's hard to use anything else.
The first prototype is just slightly over the One Square Inch requirements at 1.1 inch, which helps the USB port have more mechanical support. I cut it down a touch to fit the rules of the competition, and now the dimensions are 1.000 by 0.665 inches.
This is a two layer board with all the components on one side (except the button, which is on the back so that it's reachable). This circuit has a job to do, so no frills or fancy art, yet CircuitMaker renders it beautifully.
This CircuitMaker project can be accessed at https://workspace.circuitmaker.com/Projects/Details/Peter-Thompson-3/Simple-Solar-Charger
OSH Park just notified me that the boards are back from the fab! In a few days, I'll be able to build this up and test it out. I have a bit of code to write and an enclosure to draw up as well.