stardance has been extended another month! the new deadline is october 31 :)

You are browsing as a guest. Sign up (or log in) to start making projects!

marksdude

@marksdude

Joined June 27th, 2026

  • 25Devlogs
  • 1Projects
  • 0Ships
  • 0Votes
Open comments for this post

6h 35m 44s logged

I have finished version 0.1 of the firmware. It currently only has a simple menu to check some battery information. It relies on the ArduinoSMBus library for communicating with the BMS and the Adafruit SSD1306 and Adafruit GFX libraries for drawing on the OLED.
I also made some wiring diagrams.

0
0
10
Open comments for this post

2h 9m 25s logged

Started work on the main firmware file.
I will implement the more important stuff first, like the stuff needed for the power bank to function and most of the status displaying. Then, I will start work on the less important features, like more advanced safety (in case one of the BMS’s MOSFETs fail) and communication between the power bank and modules.
I have currently made functions for reading the USB output current and for reading the battery charger’s status.

0
0
29
Open comments for this post

3h 2m 38s logged

I learned how to send data over UART to ESPHome. I will use this to send battery info from the power bank to the LED controller module, so it could be displayed in Home Assistant.


How will it work?

First the ATmega328P in the power bank will put all the values that will be sent into a single string. The string will look like this:
bat:xx|current:xx|voltage:xx|usb_current:xx
Then when the module receives it, ESPHome will run a lambda that splits the received string into separate strings for each value. They will then be converted into floats and sent to the corresponding sensor component.


For testing, I used a XIAO ESP32-C3 to send dummy data to a revision 1 LED controller PCB.
Next, I will work on module detection or the OLED interface for the power bank.

0
0
8
Open comments for this post

33m logged

Took some pictures

First I’m going to talk about funding. I’m currently waiting for funding. Hopefully I get it before Stardance ends. I requested funding for the power bank and the LED controller module, no flashlight module because I’m prioritizing getting the power bank working. It was also the most expensive module and would have required me to write even more firmware. Firmware development isn’t my strong suit.

In the meantime I thought it would be a good idea to ask for permission to use my school’s 3D printers. Got the permission, printed the enclosure and took some pictures. Currently, it is basically just an empty enclosure, I put in the screws, OLED, pogo connector and the first revision non-working PCB to test how the parts would fit and so it would look better on the pictures.

That’s all for now, thank you.

I will be working on the firmware from now on.

0
0
10
Open comments for this post

8h 57m 47s logged

Been working on the BOM. It has been pretty boring.
Every PCB has its own BOM and I have put the final price of every one of them into one main BOM so it will be easier to read.
I also changed the inductor on the main power bank PCB to a one that fits the enclosure. I found one that has the needed current rating and is small enough so I didn’t have to change anything other than the inductor on the PCB.

0
0
6
Open comments for this post

1h 8m 51s logged

Not enough space yay!!!

With a higher current inductor comes a bigger package which doesn’t fit. I have a few options now:

  1. Change the case
  2. Find a smaller connector that can handle the current
  3. use a different inductor that isn’t that tall

Probably going to try to find a shorter inductor. I may be able to make the 5v regulator inductor smaller because I don’t think it needs a current rating that high and then maybe use the regained space for a wider and shorter inductor.

0
0
5
Open comments for this post

2h 50m 1s logged

Found an issue on the BMS board

I found that I had connected the cell sense pins in the wrong order. I had connected them like this: B- to VC0, B+ to VC1 and cell 1 to VC2, but it should have been connected like this: B- to VC0, cell 1 to VC1 and B+ to VC2. I almost didn’t notice it because I didn’t check that part of it. I thought that I wouldn’t have made a mistake like that. This wasn’t the only issue with the sense connections the other was that I didn’t use kelvin connections for them. Without kelvin connections you will get less accurate readings because of voltage drop in the copper.

I also improved it a little. I added cutouts for the current sensing resistor so I have separate pads for the sensing traces and the high current path. This should improve the current sensing accuracy which means I get a more accurate battery charge estimate. Then I added buttons for waking the IC up for programming and for shutting the output down so the battery can safely be removed. I moved the connector for the thermistors and the balance lead to the other side so the wires won’t have to run near a high current switching inductor which is on the main PCB.

Thank you for reading!

0
0
7
Open comments for this post

4h 54m 19s logged

Discovered some issues with the main PCB’s schematic when I was checking it before making the BOM

  • First issue was that the inductor I chose for the battery charge IC (BQ25792) that also makes the 9, 12, 15 and 20V for USB PD had a current rating too little (guess that’s what happens if you design a PCB like this very inexperienced like I was 8 months ago) which would have limited it to around 30W output max, so this time I calculated the required rating myself (previously got the inductor from a reference design). Found that it should have been almost double the previous 7A for the 45W I initially aimed for, but if the IC can handle 60W then why not choose an inductor for 60W? So that’s what I did, the new inductor that has a rating of 15.8A should be able handle 60W.

  • Second was that for some reason I tied the SDRV pin of the battery charge IC to the battery when instead it should have been tied to GND through a 1nf capacitor if not in use. I don’t know why I did it because the datasheet clearly says “Connect a 0402 / 50V / 1nF ceramic capacitor from SDRV to GND when the ship FET is not used.” This may have been the cause why the PCB didn’t work correctly when I made the first prototype of it around 2 months ago. I thought it was because of bad soldering, so I tried to resolder everything with a hot plate and burned bunch of my capacitors and probably some other components too.

There were some other minor issues like me choosing footprints too small for some capacitors and not using the output current monitoring of the efuse. The efuse current monitoring isn’t really an issue but it is nice to see the exact output current on the display. I probably skipped it because I couldn’t understand how it worked back then.

Thank you for reading!

0
0
39
Open comments for this post

6h 5m 41s logged

Added logos to everything, fixed some alignment issues and added little holes for the module to go into to take stress away from the USB-C plug when dropped or twisted.

0
0
60
Open comments for this post

7h 56m 26s logged

Finished the flashlight module case!

It will be CNCed out of aluminum, so it could act as a heatsink only the frame that holds the acrylic lens is 3D printed. I tried to fill up as much free space as possible with aluminum so the LEDs could run at max brightness for as long as possible. And… about the LiPo charger module I probably won’t make it I don’t think I have enough time since getting a grant and shipping of the PCBs will take a few weeks, so I may not have enough time to make firmware for everything so I’m skipping it for now.

0
0
9
Open comments for this post

3h 11m 1s logged

Started designing the case for the flashlight module. I had to move some stuff around on the driver PCB to make a cutout for the pogo connector. Also changed the connector for the LEDs from JST VH to JST XH for a smaller footprint.

0
0
13
Open comments for this post

4h 41m 1s logged

Finished the LED controller shell and made a logo

I solved the pogo connector mounting problem by having the front of the upper part open and having the wall on the bottom part.

0
0
10
Open comments for this post

5h 20m 2s logged

I’ve been designing the shell for the LED controller module. I Currently have a problem with mounting the pogo connector. The issue is that the design I had in mind won’t work because I have no way of putting brass inserts into the screw holes so I have to find another way. Maybe I could have the top in 2 parts then I could put the brass inserts in.

0
0
9
Open comments for this post

3h 55m 59s logged

Finished the LED PCB for the flashlight module

I couldn’t fit 40 LEDs like I said I would so there are 30 LEDs. It should still have close to 9000 lm max brightness (It will probably run only for a few seconds at max brightness before it will overheat). I’m just going to drive the LEDs little harder.
I first wanted to have connectors for power and the thermistor but I found that JLCPCB only offers 1 layer aluminum core PCBs so I was limited to a 1 layer PCB and I couldn’t use THT connectors so instead I’m going to solder the wires straight to the board.

0
0
12
Open comments for this post

4h 1m 16s logged

Finished the LED driver board of the flashlight module!

So that’s one of the PCBs done for the flashlight module will do the one that holds the LEDs next. I will be using about 40 of these LEDs so the max brightness will be around 9600 lm. I probably won’t be able to run it at max brightness for very long because it will (probably) hit thermal limits since the only cooling for it is the aluminum core PCB and maybe a CNC aluminum body.

0
0
6
Open comments for this post

3h 9m 1s logged

Started designing the flashlight module PCB!

I finished the schematic for the driver board yesterday. It’s going to have 2 different PCBs one that does all the communication and driving of the LEDs and the other that is going to have all the LEDs on it. I think thermal management will be easier this way since the LEDs will get pretty hot.

I also thought of a name for the project I’m going to name it Pikne which means lightning in estonian.

0
0
22
Open comments for this post

6h 38m 30s logged

Finished routing the PCB

Now I just got to run it through drc and fix silkscreen. Then the LiPo charger module PCB should be finished.

0
0
7
Open comments for this post

4h 54m 56s logged

Finished the LiPo charger module schematic!

I had some problems making the battery balancing circuitry because I didn’t know how to switch the balancing mosfets without frying the microcontroller. The problem was that the ground reference for the microcontroller and mosfets were different that basically means that for example the mosfet connected for balancing cell 3 of the battery will have its reference from cell 3 of the pack but the microcontroller will have its reference from the negative of the pack (cell 1) so for the mosfet its source will be at 0V (gnd), but for the microcontroller the mosfet’s source will be around 10.8V. That will mean if I try to turn on the mosfet with 3.3V from the microcontroller Vgs would equal -7.5V (3.3V - 10.8V) which means the mosfet will not turn on since for an N-channel mosfet Vgs has to be positive (atleast 2V for the one I used). First I wanted to use a P-channel mosfet to connect the positive side of the cell to the gate of the N-channel mosfet that would turn on the N-channel mosfet since Vgs would be around 3.6V (3.6V - 0V)
but when the balancing mosfet will be off the P-channel mosfet’s gate will be pulled up to the cell voltage so for the mosfets its around 3.6V but for the microcontroller around 10.8v for cell 3 that will fry the microcontroller.
Instead I used a octocoupler to connect the positive side of the cell to the N-channel mosfet. Like this I can turn the balancing mosfet on without having the high voltage on the pin of the microcontroller.

That probably wasn’t a very good explanation. I’m not very good at explaining.

Expected features of the module:

  • Supports charging 1-4S LiPo and Li-Ion batteries
  • Max charge current: 5-6A (1S), 4-4.5A (2S), 3A (3S), 2A (4S)

If you actually read through all of this, thank you!

0
0
8
Open comments for this post

2h 43m 2s logged

Finished the shell!

This should mean that the hardware of the power bank is mostly finished I still have to test it and then also make firmware for it. Now I think I’m gonna start working more on the modules.

I currently have these planned:

  • A Led controller module that will integrate with Home Assistant and allow you to control led strips and stuff (I already have a PCB made for this one).

  • A LiPo charger module that will allow you to charge up to 3s LiPos maybe even 4s

  • A flashlight module (I don’t think I have to explain this)

If you have any ideas on more modules I should make please comment them.

0
0
21
Open comments for this post

8h 22m 56s logged

Got done with the redesign of the front

It took longer than I thought it would. Most of the time I spent fixing the stuff that broke after changing the shell size, but after 8h it’s done! Now I just gotta figure out the button placement again because the old place won’t work with the new design and do some finishing touches and then the shell should be ready. Also I didn’t need to redesign the BMS because the current design fit the new design no problem.

0
0
6
Loading more…

Followers

Loading…