FlexiBMS Lite - New approach to get past Vaporware stage

@SimosMCmuffin and had an idea that maybe more people find useful

Is possible to have a pin supply 5v when the board is charging? I would use it to power my arduino without actually powering the board on and use my battery charge leds indicate that the board is indeed being charged, something similar how boosted does

1 Like

Unfortunately, no 5V is readily available off the board. 3V3 is available from the USART/I2C connector, which arduino can be run from, but can’t say if your other devices with the arduino will be able to run from it.

Do note, that the max current from the 5V buck is 300 mA absolute maximum (datasheet), minus what is already being used by the BMS components.

If you reaally need 5V, then probably the easiest place to get it from would be the either to solder a jump wire to the capacitor next to the CAN transreceiver and a dab of hot glue to give the wire some mechanical support.

Or straight onto the 5V buck controllers inductor output side, or output capacitor.

I’ll see if I can add an open pad somewhere for the 5V, so users can more easily get the 5V out of the BMS.


Progress on the board assembly and testing

I’ve been busy testing the voltage regulation and current consumption on the board from the 5V buck and through the LTC6803’s linear regulator. MCU is alive and I’ve been doing some low power mode testing. I want to test and confirm the current consumption for the MCU, so I haven’t assembled the rest of the board yet, meaning I can isolate all the power draw to the 5V buck or the MCU.

Started from around 3.3 mA on the basic settings with USB turned on with a couple of the internal oscillators going. Disabled the USB and it’s oscillator and turned the main oscillator from 16MHz down to 100kHz. Went into lower internal voltage regulator mode and then went into low-power-run mode.

After this my multimeter showed around 150 µA, but I don’t know how accurate it is at very low currents. I also noticed that the 3V3 linear regulator for the MCU has a quiescent current of 150 µA at zero output current, sooo the current consumption mighty be largely, because of that at the moment (Graph from it’s datasheet below). I have already found a drop-in replacement regulator, with 5µA spec’d quiescent current.

I’m gonna do more current measurements tomorrow at work with better equipment.

So in that line I have already found a couple HW related things I want to change around, but nothing major so far.

8 Likes

Thanks, or alternatively, pads to drive some leds directly would also work, I have and SOC “algorithm” that I use on the Arduíno that could merge with the firmware if you have interest, i don’t know if you have pins remaining on the micro controller

Is there a reason you couldn’t interface via USART or I2C?


Here’s a pic me (or my hands at least) testing the current consumption in my workplace’s lab. Current hovered around 145 µA and the lab multimeter used was Keysight 34461A. I’m quite surprised how close my 20 dollar chinese multimeter (an8008, approved by Dave from eevblog) showed to this amount. I’ll see if I can add the better suited linear reg to our HW team digi-key order list, I don’t personally see any big enough orders in the near days to make the order myself (free shipping after 50€ items). So far the current consumption seems pretty promising, but I’ll say for certain after I get to test the new linear reg.

IMAG0190

5 Likes

It’s possible, I don’t even need any the data of the BMS, just a way to power the board or just the logic part when the charger is plugged

Thanks

Started assembling and testing the sense and balance circuitry on the weekend.

Discovered some weird behavior on the cell voltage measurements on Sunday. Otherwise cell voltages were okay, but the top most cell was always 40-70 mV under actual amount and was fluctuating slightly, where as all the other cell voltages were rock-solid and on point. I tested with 3, 4, 5, and 6S batteries and it was always the top cell measurement that exhibited this behavior. Due to the problem always persisting with the top cell and all lower cells showing correct numbers, this lead me to believe the sense circuitry itself was okay, but there is something weird going on the supply side on the LTC6803.

Tried isolating the MCU’s 3V3 supply, which seemed to fix the problem. Meaning there is something funky going on with the 6803’s 5VREG output while USB is connected. Problem seemed to get fixed by placing a diode on the 5VREG line between the MCU 3V3 linear regulator. USB comms showed correct and steady results for the top most cell measurement after that. Board now officially has it’s first hot bodge component placement as pictured below (had to scrape off soldermask and cut a trace and then solder the diode inline onto the naked trace :wink:)

I still want to check the measurement results without the USB connected by passing the cell measurement results through an Arduino via USART.

Once I have results from that, then I’ll start testing the actual balancing. Mainly interested in the thermal behavior, currently current bleed resistors are 33 Ohm, as can be seen on the lower picture. At 4.15V this should give ~125 mA balance current.

Note

I believe I’ll be able to get the standby current use below 100µA, but I still don’t have the better suited linear regulator on hand yet, so I can’t affirm it 100%. In theory this should give for example a 1 Ah (very small) battery a storage life of ~400 days, or 2.4 mAh daily.

IMAG0192

IMAG0193


Off-topic

Assembled this thing also on the weekend (battery not yet soldered in). Kudos to @MasterCho for Thingiverse files and @Smorto (https://www.electric-skateboard.builders/t/gt2b-mastercho-chozen-mod-full-length-tutorial-how-to/16005?u=simosmcmuffin) and @Mikenopolis (https://www.electric-skateboard.builders/t/gt2b-mod-video-tutorial-chozen-remote-case/37668?u=simosmcmuffin) IMAG0194


EDIT:

Also, experimented with the super low-power modes on the MCU and did a beginner’s error. Put the MCU in stop mode 2, which stops the CPU clock.

Have a guess, if I could get my ST-LINK to connect to it after that? No. Problem really was that I don’t have RESET broken out to a test pad, because normally you can call software system reset with just the SWCLK and SWDIO, but guess if that still works when the CPU is internally stopped in a low-power stop mode? Nah. So every time the MCU booted up it directly ran itself to stop mode in couple milliseconds. Not really enough time to start debugging run from the ST-LINK and flash a new firmware to it :smile::sweat_smile: .

Fun. Times.

In the end I solved the problem by soldering a sneaky hook-up wire directly onto the QFN package’s RESET pin pad (which doesn’t extend out anywhere from below the package). Well got it done. Got reset working so I could get the debugging session started and flash a new firmware. Didn’t even have RTC running the auto wake-up in the background, so it really was a sleeping beauty at that point. Even considered desoldering the whole MCU and just plonking down a new one.

Well, you learn best from these kinds of mistakes…

12 Likes

Good progress

I think your best bet with cell balancing is to limit how many cells should be allowed to balance simultaneously with a temp sensor near the resistors should it get too hot in a extreme situation

It was interesting to read about developments :nerd_face: Thanks for documenting!

3 Likes

I always try and breakout these sorts of pins to a test pad even if you dont think you will need them just for situations like this.

Otherwise the boards look great. Did you solder them by hand or did you reflow them? they look very tidy.

To be honest if adding 1 diode is the only change you need to make then that’s pretty good going. Cant wait to see further progress with this. Also Im surprised by just how small the board looks in your photos. Cant wait to have one of these in my board :smile:

1 Like

Here is a FLIR video of the first balancing action. Charging a 6S battery with all the lower 5 cells crossing over balancing voltage, which in this case was 4,160 V. It’s running too hot for my taste, especially under continuous balancing, which is compounded if the cells that need balancing are all next to each other. I can use the internal temperature measurements of the LTC6803 and MCU to determine the board temperature on a rough scale.

Recorded on a FLIR ONE (first gen, not available anymore) a very worth it purchase for debugging and troubleshooting electronics and anything thermal related.

4 Likes

As long as the board is not thicker than a 18650 battery it wouldn’t affect any one is it possible to add a heat sink or drop it in to a mettle case as a upgrade so it would never become a limiting factor? Having a case mounted heatsink is some thing I do check if any things not feeling right just put my hand on it and it gives a piece of mined I’m not frying my foxbox on a long hill.

Again, I love your R&D approach. Nothing’s left random.

I second that ! Nice job !

Hand soldering. Hot air reflow station and soldering iron if needed.

Gotta test to know.

It’s a possibility, but IMO a pain in the ass (had a heatsink on the first one). I’ll rather just go for lower balancing current, which lowers the heat generated and allows more time for the heat to spread and conduct away. Seems like a bit of an unnecessary complication, considering it would only be cooling the balancing resistors. Much more likely for the heatsink to happen with the version that has discharge path control also.

Got the charging cut-off and the battery voltage sense circuit assembled.

image

I didn’t get to test the actual charging through this circuit yet, as I started figuring out why I was getting a little too low reading from the battery voltage sense circuit.Connected my ~12,50 V battery, analog pin voltage was around 491 mV, hmmm, checked with a calculator what the ideal voltage should be, 512 mV… These would translate to 11,90 V and 12,49 V respectively. That’s actually quite a lot lower. Why though :thinking:?

Even weirder was that the lower N-fet seemed to be conducting with a gate voltage at 0V. What? Well after some multimeter voltage measuring and checking schematic and fet datasheets turns out I had accidentally put the fets in the schematic the wrong way around, part model wise. P-fet was on the high-side and N-fet on the low side, this is correct in the schematic, but I had somehow mixed up the actual 2N7002 and BSS84PW fet types. 2N7002 is the N-channel that should be on the low side and BSS84PW is the P-channel that should be on the high-side and as you can see from the schematic capture below, I have them wrong way around.

image

Well I was able to find substitute fets from my parts bin and got the circuit working as intended (correct fet types, pin outs and voltage capability). Got the measured and AD-converted result within a couple of LSB too, nice. This mix-up is easy to fix for the next iteration.

Next mistake I found when I started writing the software configurations for the ADC. More specifically when I started to map the analog read pins to the correct channels for the ADC. Anybody notice in the picture below any problems with using the PB2 (CHARGER_SENSE) pin as an analog input?

image

Well… It’s not mappable as an analog channel for ADC… Guess I’m not testing that then. At least the fix will be easy to make for the next iteration. Otherwise the circuit is identical to the battery voltage sense one, so I don’t see why it wouldn’t give as accurate readings. PB1 and PB2 will be easy to flip around and get that CHARGER_SENSE to a ADC input channel. Easy-Peasy re-trace as shown below.

image

I’ll start testing the charging circuit today and then move onto the current sense once that works. Some new board pictures below with a standard XT60 for size comparison (sorry, no standard banana this time).

IMAG0196

IMAG0197

10 Likes

Charging current tests done and I’ve got results.

I used a simple test setup shown below. I’m supplying current from the BMS’ charger side with my bench top configurable power supply and on the battery side of the BMS is a configurable DC load. I don’t need to use an actual battery in the test setup like this. Voltage is not a critical variable in this test as I’m interested only in the thermal performance in relation to the current.

IMAG0198 IMAG0199

The tested currents were: 2, 3, 4, 5, 6 and 7 Amps. For each current test the BMS was left to run for couple of minutes, allowing the thermals to stabilize after which a FLIR image was taken with FLIR ONE. a FLIR image was taken from the bottom side of BMS on currents 5 and 7 Amp.

I also measured the voltage from the following points (shown below) to measure and calculate the losses happening specifically in the MOSFETs for each test current and after letting thermals stabilize.

IMAG0203

Test current: 2 A
Voltage drop: 53 mV
Resistance: 26,5 mOhm
Power loss: 106 mW

Screenshot_20190322-162206

Test current: 3 A
Voltage drop: 82 mV
Resistance: 27,3 mOhm
Power loss: 246 mW

Screenshot_20190322-162619

Test current: 4 A
Voltage drop: 115 mV
Resistance: 28,8 mOhm
Power loss: 460 mW

Screenshot_20190322-163014

Test current: 5 A
Voltage drop: 151 mV
Resistance: 30,2 mOhm
Power loss: 755 mW

Screenshot_20190322-163519 Screenshot_20190322-163541

Test current: 6 A
Voltage drop: 196 mV
Resistance: 32,7 mOhm
Power loss: 1176 mW

Screenshot_20190322-163902

Test current: 7 A
Voltage drop: 260 mV
Resistance: 37,1 mOhm
Power loss: 1820 mW

Screenshot_20190322-164345 Screenshot_20190322-164413

Here are the results of all the current tests collected to a google sheet and a couple of charts drawn from them.

image


From the charts can be seen the effects of the increasing temperature alongside increasing current. Voltage vs. Current and Resistance vs. Current should technically be linear, but as the mosfets heat up their Rds(on) resistance increases, therefore producing more voltage loss as the current increases. This is then magnified even more in the Power Loss vs. Current, as it already rises in the square of the current.

Conclusion:

With these MOSFETs, I wouldn’t personally go above 5 Amps for the charging current, as things start to get real toasty above 5 Amps. Far cry from the 10 Amps I envisioned in the beginning. So what’s the game plan? I’ll throw a poll at the end of this post to get some feedback on what the forum members think is high enough as the supported charging current.

To achieve higher charging current the MOSFETs should be optimized for as low as possible Rds(on) resistance, to minimize conduction losses -> minimize heat generation. Switching speeds are not critical as the MOSFETs are not run with PWM, but are rather just closed or opened for extended periods. Other 2 important attributes then are package size and cost.

Once I get some votes on the poll below and see what people would want, I can then start to check possible options for the mosfets and then discuss about the cost with them. One consideration though is how high of a charge current should the Lite version support, if it’s meant to be the lighter, smaller and cheaper option.


How many amps do you think the BMS should support as a maximum charge current? (Lite version)

  • 5 A is enough
  • 6 A
  • 7 A
  • 8 A
  • 9 A
  • 10 A

0 voters

1 Like

The mostly common used charger is 4 amps, 6 and 8 is a bit more expensive but our batteries are ready to handle 8 charging amps just fine. Other point with 5+ amps is the connector, the most common is power jack 2,1x5,5mm this doesn’t handle a lot more than 4 amps. Actually I have 8 amps charger and I keep charging to 5 because I didn’t find a nice and small connector up to 8. I think most of the beginner builders they will no go above 5 amps easily. I rather prefer 8 amps but seems logic for a lite version up to 5.

Edit: I want to vote 5 by mistake I did 6 and can’t change it :smile:

1 Like

Looking great

Just a suggestion for the MOSFET

https://www.digikey.com/product-detail/en/toshiba-semiconductor-and-storage/TPW1R306PLL1Q/TPW1R306PLL1QCT-ND/6188444

It was the best I could find for a reasonable price for my antispark switch

I am charging my board at this moment with 8A and want to go to 10 or 12A :see_no_evil:

Voted 6a because. Most common battry q30. spec sheet standard charge 1.5a. Most common battry config 10s4p. 4 Q30 in parallel standard charge 6a.

What’s your pack configuration and what cells?

Might be a overkill and a bit pricy (@ volume 1,4 € ea.) compared to the 20 cents (@ volume) per piece for the current 5 Amp continuous ones.

This is a bit more reasonable. Should be able to do the 10 Amps or very close at least.

Yea, the common 2.1x5.5 / 2.5x5.5 mm DC connector will become the limiting factor after 4 or 5 Amps.

Anybody have any good charger connector ideas/recommendations capable up to 10 Amps?

Thanks for the feedback.

2 Likes