Posted on

Individual Cell Testing in Large Battery Packs

I have been very fortunate to be part of the Midnight Sun Solar Car Design Team at the University of Waterloo ( As the Battery Lead for our next solar car (MSXIV), I am responsible for designing, prototyping, testing, manufacturing, and integrating the battery.
This discussion/post/article/whatever you want to call it will go through some of the considerations when building a large battery pack for high performance applications including electric vehicles. This is not as critical for the performance of say a home-built powerwall from recycled cells, but from a safety perspective is probably more important in such an application as the cells may already be degraded (in invisible ways – pending internal shorts) from their first use.
Lets start off by posting a PDF of some research/literature review that I did a few months back to determine if individual cells should be tested for a solar car battery pack. The result of my evaluation is that basic individual cell testing should be conducted, but based on time frames, a full capacity measurement will not be done. If we had access to a highly parallel capacity testing rack (which I have had some ideas on building one – might come in the future) then capacity testing would be good to do.
Click the link below to download the PDF.
The testing was done with a Keysight B2902A SMU and a custom scale made with Phidgets hardware. Our goal was to be able to detect manufacturer defects that could cause cells to heat up or fail prematurely. To this end, we testing for DC and AC Internal Resistance, Self Discharge Current, and cell weight, and an estimate of capacity through differential capacity through the capacity ration.
A custom scrip tin Python was created to interface with both instruments and automatically collect the data into CSV files. The testing was completed in a short timeline (36 hours) and, we collected data for 1400 cells. The CSV files collected made up over 6GB of data.
To process the data, more python was used – if you can’t tell yet, I really like python, especially when tools like matplotlib and numpy make data processing super easy.
These will be following the guide I have outlined here:
Once we have processed the data, it will be used to identify outlier cells and match them in order to create and most balanced pack as outlined in the Individual Cell Testing Evaluation Guide linked previously.
With all of this data, we hope to create a battery pack that will power Midnight Sun XIV on its 3000km journey across the United States during the American Solar Challenge in the summer of 2020.
Written By: Micah Black
Project By: Micah Black
Posted on

Machining Acetal for 18650 Cell Holders

Please note that this is a quick writeup, and not intended to be an independent guide to machining or battery pack design.

I have been very fortunate to be part of the Midnight Sun Solar Car Design Team at the University of Waterloo ( As the Battery Lead for our next solar car (MSXIV), I am responsible for designing, prototyping, testing, manufacturing, and integrating the battery.

Our battery pack is made from 864 18650 style cells in a 24P 36S arrangement, for a nominal voltage of 131V and capacity of 10.8kWh. These 18650 cells are held in place at the top and bottom using acetal plates. In the image below, the acetal plates are the grey plates at the top and bottom of the cell supports.

The choice of acetal was made primarily because it is easy to machine, creating lots of chips and not melting too easily. After finishing the design in Solidworks, I imported it into MasterCAM 2020 where all of the toolpaths were created. This was my first real project in MasterCAM, but I am glad that I spent the time to learn the software as this opens up a whole new area of possibilities for manufacturing for future projects. Anyways, the part was designed so that no endmills smaller than 1/4″ were required, and could be milled using only 2.5D operations. The process was relatively straightforward, aside from getting used to all the different plane naming in MasterCAM. Because I had created this part to be machined, all the toolpaths were easy to pick out, though time optimizations could definitely be made. This round, I was only making 2 parts for the prototype module, but in a month or so that full production will be headed to the machine with much more optimized gcode.

The University of Waterloo has a Haas VF2 CNC Machine that students can use for design team projects, and is the machine that this part was created on. Again, it was a relatively simple process of setting tool offsets, setting the part zero, then loading the program.

After testing the sizes of the cell holes, we decided to go back over the holes and enlarge them to ensure a smooth fit into the slots and not destroy the PVC insulation while inserting or removing the cells.

From design to final product, this has been a huge learning experience for me, and I hope to continue to improve my machining skills in the future.

I’m looking forward to doing some lightweighting on this part for the final manufacturing run, but have learned a lot in the prototype process.

Written By: Micah Black

Project By: Micah Black

Posted on

DIY Laser Engraver Design, Build, and Control

For the last few years, I have had an idea in the back of my head that I want to build a laser engraver. Over a co-op term, I decided I would finally make that happen. I decided to take a different approach to this project than I have for other projects, I would make a complete design first, and hopefully remove all problems during the assembly by doing so. I was also not going to skimp on any safety features, namely a full enclosure, proper emergency stop switch, and ventilation + filters. Making the design first also made me want to add drag chains, a hinged magnetic lid, handles for transport, a removable laser head, and many other amazing features that I would not have implemented otherwise.

One of the reasons I decided to take this project now was that I recently learned about GRBL being ported to the ESP32 and some development boards available for purchase on Tindie. A Wi-Fi enabled laser engraver sounded like a great idea to me, so I bought some of the control boards, and some TMC2208 stepper drivers for silent motion that is backwards compatible with all other stepper boards. I had some NEMA17 steppers lying around from a previous purchase, and the laser is a 2.5W diode I had purchased from Aliexpress a few years ago in hopes of one day getting to use it.

Before printing all the parts for this, I upgraded my slicer to the newest Cura edition so I could take advantage of the Horizontal Expansion feature, which allows adding offsets for the amount of expansion that your printer has. It took a few test prints to get the correct values, but it was definitely worth it. The fan enclosures, electronics boxes, motor holders, and bearing holders all slide on the to aluminum t-slots very snugly, and will not be moving around unexpectedly.

The frame of the build is made with black anodized 2020 aluminum extrusion that I purchased from RobotShop, and held together with aluminum L plates and M5 bolts. This construction is way overkill for a laser engraver that does not have any horizontal forces on the moving head, but I decided to go for it anyways as it looks great and provides a great base for transport,  etc. The exterior dimensions of the frame are 500mm x 340mm x 140mm.

A slightly modified version of the traditional CoreXY belt system was used, keeping the 2 belts on separate planes instead of having them cross over at the end. This allowed to keep the belt paths clean and the overall size smaller. The rest of the motion system includes 8mm smooth rods, LM8LUU bearings, and GT2 timing belts and pulleys with integrated bearings.

The ventilation system is 2 low profile Noctua 92mm fans with a carbon filter in front of them. These fans fit perfectly between the upper and lower aluminum extrusions, and provide a decent amount of airflow even through the carbon filters – I would not have gone with cheaper fans, as they definitely don’t move as much air as these Noctuas.

Internal lighting was another feature that I felt necessary to include, so I used some waterproof LED light strips that I have from previous projects. This fits perfectly inside the t-slot aluminum extrusions, and provides great lighting on the inside.

The enclosure is made from transparent orange acrylic. I knew I wanted the engraver to be enclosed, but I also wanted to be able to see what the laser is doing without opening the lid. The laser has a blue / near-UV wavelength, and I have heard that orange acrylic tends to absorb light of this wavelength. While I never actually verified this, I can say that looking at the laser dot through the acrylic is definitely different that without. I had originally decided to go with some laser shielding sheet from JTechPhotonics but once I realized that would mean spending a couple hundred dollars for the amount of acrylic I had needed for the design, I decided to just use some normal transparent acrylic. That lead to another search for a reasonably priced supplier that brought me to, where I was able to get the acrylic and the glue that I needed for around $100, and shipping was only $25 which was also a steal. While I was designing it, I also added some black acrylic accents to make the build a little more appealing, which turned out great.

As for gluing the acrylic together, I did not want to take shortcuts here either. There is one universally recommended glue for acrylics, also known as acrylic cement, solvent glues, or plastic welding, the Weld-On 4 and Weld-On 16 glues, which melt the acrylic thanks to some methylene chloride, and chemically bond the sheets together. This essentially creates a single sheet of acrylic once it is cured.

On the electrical side, I implemented a number of key safety features. An emergency stop switch, a large rocker switch as the main power button, individual toggle switches for the lights, fans, and laser power, and of course a fuse. These are all contained in one box mounted on the aluminum extrusions and the other box includes the ESP32 GRBL controller and the laser driver board.

The laser bed can be dropped out from the bottom using thumbscrews. I made this using a 1/4″ plywood wasteboard, a thin aluminum sheet to prevent burning through the plywood, all enclosed with aluminum angles to protect the sharp edges of the sheet metal.

I’m super happy about how this build turned out, and how close it looks to the original model. I think that’s a testament to how much planning can help a project run smoothly.

The next steps on this project is to clean up the wiring a little bit, then start the final testing. I have already verified that the motion is smooth (and pretty much silent thanks to those TMC2208 drivers) and that the laser works. Now I have to put the two together, find an optimal federate, and then find some software that will allow me to engrave images!

The first tests on this machine were engraving squares and circle with G-Code I wrote myself. After a long process of focusing the laser, I got some amazing and consistent results. I wanted to use a vector graphics platform to control the laser, and found a laser tool for Inkscape from JTechPhotonics. It took a little while to get it properly set up and useable (partly because the X-axis on my machine is reversed and the GRBL invert axes settings don’t seem to be playing nice with the CoreXY system), but once that was complete, I had a fully functional laser engraver. The first image I engraved was my logo, of course, on the same test sheet I had been using for the squares and circles!

Project By: Micah Black

Written By: Micah Black

A bunch of pictures of the design and build process can be found below.

Posted on

Laser Cut Nerf Ball Shooting Lego EV3 Tank

For the final project of my 1A term in Mechatronics Engineering, we created a laser cut tank with the Lego EV3 kit (this was required) that shot Nerf balls, all to achieve a very special purpose: to remove the geese from the University of Waterloo campus.

There are lots of pictures of the tank below, and our design reports are attached as well, but I would like to highlight something here as well. Before going further, I would also like to give credit to my amazing groupmates Caleb Dueck and Lukas Wormald. This project was truly a group effort, and I could not have asked for better groupmates.

The treads are made out of laser cut 3mm MDF board. Using cutting a flexible pattern in to the wood, we were able to create a fully functioning tread. We attached both ends of the tread using 18AWG wire loops soldered through holes in the ends of the treads. The gears were made from This may not have been the best option for the treads, but it worked fairly well and was easy to do. The treads were not durable in the wet weather outside and one of them broke as it got wet and soggy.

The ball hopper mechanism was inspired by the design of paintball hoppers, and laser cut out of 3mm MDF. It worked very well at slow speeds, and was very repeatable. The top cover is attached with magnets and is removable in order to reload the hopper.

If we were given more time and resources, we would like to have made the balls fire faster and further using compressed air instead of a spring. However, the spring powered solution worked fairly well after some tuning, but would not fire as straight or as far as was originally planned for.

Using the Lego EV3 Robot kit was a requirement for this project, driven by the school, as these kits are easy to debug. If we were given more time and more freedom, we would have used an Arduino based platform instead, as this gives more expandability, power, and features.

The design report that we produced covering all the design decisions that were made is available here.

Videos of the robot in action can be found here.

Project By: Micah Black, Caleb Dueck, Lukas Wormald
Written By: Micah Black

Posted on

Touch Sensor Piano PCB Kits

Again, a long overdue project article, but I am slowly getting through them.
This project originally started when I made a mini piano on a 400 point breadboard with screws as the touch sensitive keys. I was looking for an easier way to make keys that are secure, but extremely easy to make and assemble. The ideal solution would have been a tool-less, solder-less version that costs almost nothing, but I have yet to find such a solution. So, I designed a PCB to the 3 components of the piano, and used very large, circular SMD pads as the touch sensitive inputs.
Making a PCB allowed for a much smaller footprint, as well as easier assembly although there is soldering involved now – for me it is easy, but for others possibly not.
I may get to the point where I offer this kit as a beginner’s electronics kit, or as soldering practice like many kits I have seen on eBay.
After a year or so of using it and watching other people use it, I would have made the touch pads bigger, and would love to figure out a way to play more than one tone at once to create a harmonic.

Project By: Micah Black
Wirtten By: Micah Black

Posted on

Backlit Display Boxes for Decoration

This article is long overdue – it is for a project that I completed while still in the early years of high school.
The same goes for many of the next articles and projects I will be posting.

One day, I decided it would be cool to mount the boxes of computer parts on the walls and backlight them with LED strips. The next weekend, that is exactly what I did.
I used some 1cm x 1cm wooden strips to create a square slightly smaller than the sizes of the boxes that I will be mounting. To those squares, I attached the LED strips which were different colors to match the main color of the boxes. Once mounted, this created an effect somewhat like a floating box, with the light coming from behind, and no visible shelving to hold the box up.
To mount all this to the wall I chose the non-permanent method of double sided tape in the form of 3M command strips. I did not want to damage the boxes either, in case I ever needed to return any of the parts that they originally contained, so I used adhesive backed velcro to them to the wooden frames.
Now for the power, these LED strips need 12V which is perfect, as I have a computer power supply that provides 12V for the overhead lighting as well. I stuck an extra connector and switch on the end of a pair of wires and connected that to the closest box. To attach the rest of the boxes, I soldered wires between the 12V and GND traces of the LED strips, at the closest points between the boxes.
Fast forward a few years to when I am now writing the article, I am somewhat surprised that these held up so long. The 3M command strips are just now starting to lose their stickiness. As for the lighting, it still works perfectly, but I did not use it as much as I had expected. The LEDs were too bright to wire in to the main light switch, so I left them on a separate switch and only really ever used them as a showpiece.
If I were to do this again, I would make the LEDs dimmer by driving them from 9 or 10V instead of 12, and wire them in to the main light switch so that they are not too bright.

Project By: Micah Black
Written By: Micah Black

Posted on

iPhone 4S Phone Battery Failure (Chinese Replacement) and some Project Thoughts

I have always been a fan of fixing my own stuff. So when my iPhone battery died, I bought a cheap Chinese replacement and a screwdriver kit from eBay to replace it myself following an iFixit guide. The process was super easy, and I had everything working again in less than 10 minutes. However, this did not come without its consequences.

A few days ago (months now), while charging my iPhone 4S – yes, its old but it works – , I heard a ‘pop’ and felt the phone expand.
I took the case off as quickly as I could, and saw that the back of the phone had popped open because the li-ion battery had swelled up – never a good sign.
Surprisingly, the phone was still on at this point, so I shut it off and tried to get the back panel off. I took out the 2 screws, but before continuing to remove the battery, decided to turn it back on and get the pictures off of it.
I wasn’t sure if the battery was going to continue expanding when I plugged it in to my computer to take this pictures off, as this would also continue charging it. In the few minutes that it would take me to get the pictures off, it would not transfer too much energy to the battery, so I decided to take the chance.
I was able to successfully remove all the important data, then unplugged the phone and removed the battery without further problems.
Let me be clear that this battery was NOT the original iPhone battery. I had replaced it about a year and a half ago, with a cheap replacement battery from eBay. I wasn’t expecting the replacement battery to last a long time, but it managed over 500 charge cycles, which is not bad for a cheap chinese battery. It is definitely much better than those ‘UltraFire’ 18650 cells out there.

I have been buying Chinese parts for years, and have never had any problems with them, when treated correctly. Batteries are one thing that I will avoid buying from China in the future.

This also speaks to a project philosophy that I have been thinking about and working on recently – If its worth doing, then its worth doing well. Chinese batteries are one of those shortcuts to completing a project, but not doing it well. Sometimes, it is worth the money to just get the right components. All the Arduinos that I use are Chinese clones of the original open source Arduino boards. They are cheaper, but they function just the same. None of the 50+ that I have personally used have ever caused any problems or dangerous situations to arise, so until the day comes when one dramatically fails (more than magic smoke), I feel completely safe using them as long as I treat them well according to the manufacturer’s specifications.

Posted on

3D Printer from old DVD Drives

Again, another project that I completed (I tried at least) long ago and never wrote an article for.
After seeing some projects on instructables and hackaday that used DVD stepper motors to make 3D printers and laser engravers, I decided that I would try my hand at making one.
I had lots of old DVD drives on hand from electronics recycling centers, and the electronics I purchased for under $50 from aliexpress.
I used a RAMPS 1.4 board, an Arduino Mega, and the A4988 stepper drivers for this, as they are extremely cheap, and I didn’t want to spend a fortune on this.
For the extruder, I bought one of the E3D clones, a PTFE tube for the bowden adapter, and the cheapest NEMA style stepper motor I could find – which turned out to be a bad idea, and there were no designs for filament feeders that fit this motor, and I didn’t want to spend the time to design one.
The frame was built out of MDF cut by hand, and 3D printed right angle brackets and M3 bolts and nuts. I was surprised how well the 3D printed bolts and nuts stood up, and the frame was very rigid.
As for the Y axis, I attached one DVD drive slider to the bottom of the frame. On top of the DVD reader sled, I attached a raised flat surface held up with springs and bolts (to allow for levelling). This surface was a 50x50mm piece of steel from one of the DVD drive casings. As a print bed, I think this would have worked fine, but I never got a chance to test it actually printing.
The X axis motion was again a DVD drive mounted to the vertical part of the frame. The DVD drive sled slides horizontally like a Prusa i3 would. To this drive sled, I attached the cover of a 2.5″ hard drive to give me more surface area to attach the Z-axis to.
Up and down motion for the Z-axis was achieved with another DVD drive mounted to the X-axis.
Connecting the stepper motors to the drivers required some prodding with a multimeter to figure out which pairs of wires were connected inside the 4 wire stepper from the DVD drives. Once the two pairs were figured out, they were attached to the RAMPS board, and were ready to test.
To the Z-axis, I attached the E3D clone extruder with a fan mounted on it. This choice of extruder (or maybe this would have happened with any extruder) proved to be the wrong one, as the DVD drive on the Z-axis was not powerful enough to raise the extruder.
The next part to mount was the endstops, and as I was mounting them, I realized I should have thought about this earlier. Some disassembly and custom 3D printed pieces were required to mount them, as well as a fair bit of hot glue, which I was trying to avoid.
Then the software – I opened up the Marlin configuration file and started modifying the values that I knew had to change. This was mainly the travel limits for all axes.
Once everything was mounted and wired up, the testing started. I connected the Mega to my computer, and opened up Pronterface to control the printer. Through this, I was able to determine the correct steps/mm values to plug in the Marlin. The other thing that this testing showed was that the stepper motor for the Y axis worked really well. However, the same cannot be said for the X and Z axes. The X-axis moved very slowly, and did not have smooth motion. The Z-axis, without help, did not move at all while the stepper was getting very hot. To try and fix this, I tried to add a counterweight (an 18650 cell) for the Z-axis, but that did not help at all.

One of the big mistakes I made while designing this was thinking of it in terms of separate items, and not worrying about attaching them until I got to that step. This caused some problems where parts would not attach together properly, and after a few hours of rigging something up, I had found a way to make it work but it was never elegant, repeatable, or sturdy enough.

Project By: Micah Black
Written By: Micah Black

Posted on

Simple Arduino Pong Game

Another one of those long overdue articles. I originally created this pong game 3 or 4 years ago, but it has gone through several great iterations since them.
This portable pong game has been a work in progress for many years. The components have stayed the same, but the enclosures and format have changed a fair bit.
The first version was created on a breadboard and was mostly just a proof of concept and a platform to figure out the code.
The second version was built inside a 3D printed enclosure and was a mess of wires inside.
Next version (number 3), I created on a 7x9cm perfboard and managed to keep the wiring a little bit neater, but it looked much better than previous versions with the added benefit of being more compact.
For the final version (number 4), I designed my own PCB to hold all of the components, with an easily replaceable battery holder.
As mentioned earlier, the circuit stayed the same throughout all versions (with the exception of a power LED on some). So let’s take a look at what that circuit consists of. I used an Arduino nano to control everything, a 1.8″ LCD display, 2 10K potentiometers, a switch, a TP4056 charge and protection module, an 18650 cell, and a 5V boost converter. These were wired up in logical fashion so that the 18650 cell was protected and the voltage would be stepped up to 5V for the system, and the Arduino communicated with the LCD over SPI while using the potentiometers as analog inputs to control the paddles.
For programming this, and part of the original inspiration for this project, I found an example on the Arduino website that showed 1-player pong, where the paddle could move anywhere as the ball would bounce off of it and the edges. I modified the code for this to make a 2-player version.

By far, the custom PCB version is the best because it is compact, neat, durable, and easy to wire everything up. If designing the PCB again, I would definitely use a different software than EasyEDA, as the one thing that was especially annoying was the UI. I could not figure out how to create rounded corners on the PCB, and their guides were not much help either. Since designing this board, I have figured out how to do that, but I still don’t enjoy the interface.
As for improvements on the code, there are plenty of things I would change – the main ones being a better menu, text facing the right way, and the ball not removing parts of a dividing line. When programming this, I just programmed it up to the point that it worked, and then stopped making improvements, which I somewhat regret now, but is not something I am going to go back and fix, as I have too many other projects that I am working on now.

Project By: Micah Black
Written By: Micah Black

Posted on

My Vision for A2D Electronics

After spending 4 months away from Ottawa (and my business) at university, I wanted to figure out where I want A2D Electronics to be in the future.
I have spent a fair bit of time figuring out how to make this less work for me and potential future employees, but I also need some direction on where this business will be going in the future.

A2D Electronics exists to provide electronics at a reasonable and affordable price so that anyone and everyone can start making things. It does not exist to make me money. When this started almost 3 years ago now, I realized that the Ottawa maker community had a need for quick access to parts, and I could do something to help that. It was an idea that filled a need and one that I thought could make me some money.
Don’t get me wrong it does make money, but only enough to cover the projects that I make and post and some extra to reinvest in inventory and pay a little towards university. The most valuable things that this company has given me are first and foremost the connections that I have made, but also a feel for how business works on a small scale.

So where is this going in the future?
I want A2D Electronics to continue serving the community. From here on out, that is the main goal.
Before we take a look at how that will happen – let’s take a look at the current situation first.
The most time consuming tasks are restocking and re-ordering inventory, packing orders, scheduling local pickups, and adding new products. The biggest problem here is that I don’t have much time – between working full time on co-op, managing my own projects, other project, involvements in makerspaces and the Midnight Sun student design team leaves me with very little time. If only I could make myself an army of robot minions…
To continue serving the community, my focus will have to shift from being an order-packing robot to a community servant.
Making those tasks easier, more efficient, and streamlined has been on the back of my mind for the last month or so, and I have come up with several solutions that will be implemented in the near future. However, these changes alone are not enough to better serve the community.
One idea that I would like to flush out is to have ‘vending machines’ for electronic components in Makerspaces around the city. These would be amazing, but how would you keep track of everything and accept payments? Those are the questions that I have been dealing with.

So how does A2D Electronics better serve the community of makers?
By making access to components easier, faster, and more affordable. Doing this will mean flexible pickup times, possibly multiple locations, more products, and increased efficiency.
For the next few months, those items will be my focus.

Written By: Micah Black