DIYBMS v4 Shunt Design and discussion

I agree that daughter boards may be more expensive but there are benefits to exposing the I2C bus so allow secondary boards (like an INA breakout board) to be added. Similarly exposing the CAN/RS485/Display components as simply a pin header would be doable as there are breakout boards for most of these pieces available today, and most of these require extra components to be usable.

1 Like

Right, I’m not disagreeing with that.

I’m saying put the INA on the controller board. If there’s just one controller board, then it should have 2x INA226, and 4x TLC222A for 8 relays. I’m saying do not relegate the INAs to a daughter.

It makes no difference that the INAs and relays are not wanted by some. Those extra unused chips will not bother anyone.

Regarding Stuart’s new controller, the LCD is the thing that I would NOT put on the controller. I have no problem with some header that one can connect a ribbon cable to an external LCD, but for those that don’t want an LCD, that LCD would be hard to ignore. The INA chips are easy to ignore.

Sorry, I don’t understand your numbers. With the 560ohmR, aren’t I getting 5.89mA? 3.3v right?
Also, the total watts if all 6 relays are on will be 116mW and the PCF8574 says it can drain 400mW, so I seem OK there too.

1 Like

I am not suggesting a nS that is any different than n modules, just that they are on one board and thus are already daisy chained.

I don’t see why this would be any extra support. I am not suggesting you @stuart should make these variants.

The key to minimizing support question is obvious documentation. I am NOT saying “more documentation”. For example, the folder names and arrangement on git is poor. The existing 2 different module variants should not be separate branches, they should be separate folders. They should be under the folder named “Modules”, named “hand assembled” and “jlcpcb assembled”. The current name “circuit” is confusing. With that improvement, a folder named “8x Modules (single board jlcpcb)” would be pretty obvious in my opinion.

From my point of view exposed I2C connectors is a perfect solution. You need INAs, someone else need other functionality. There is a bus available - connect to it whatever you like - flexibility is always good. You have personally written that when it is about a couple of dollars price, then it is not a question for you, then why a daughter board suddenly is such an issue - a couple of dollars for a PCB boar + the same price for INAs?

1 Like

I agree they are confusing, however as there is not documentation and videos on the subject I’m not radically going to change that. Perhaps on the next major release/update.

As I mentioned, its just a header, not mandatory.

What are people needing 8 relays for? What is driven through these?

The INA chips are fine, but again there are multiple variants of those depending on voltage measurement needed - do we install 48V or 36V etc. a daughter card would be useful in this scenario.

Likewise, should a change in measuring tech be needed in the future, the daughter card can be swapped out/upgraded without replacing the whole controller module/pcb.

You’ve still not mentioned how you are keeping the high voltage isolated from the 3.3v circuits.

Once you move into the “resell to others” it becomes a commercial decision, and currently that is prohibited by the terms of the licence applied to DIYBMS. Even if it’s not for profit.

https://creativecommons.org/licenses/by-nc-sa/2.0/uk/

Because the additional board is a lot more cost than the few bucks for the 2x INA. If you make the board by hand, that’s a ton of work. If you order it assembled from jlcpcb, it’s a minimum of $40ish, and if you do the “right thing” and resell them, that’s yet more work (find 4x buyers, find 4x boxes, get a stamp, etc).

Again, if the goal is more “sales”, the costs: soldering, wiring, mounting, programming, and extra boards from jlcpcb must come down. This is why I asked Stuart what is goals are. Maybe he does not judge his success by whether there are a lot of users, but if he does then there is no excuse to make a version without 2x INA and 4x TLP222A. Seriously, just imagine the support questions when someone finds out that they ordered the stuff and it does not do the most obvious functionality, providing state of charge?! The INA chips will measure state of charge on any system voltage when they are low side shunts.

If the goal is a lot of sales. Make a version that has 8x modules and 1x controller with relays and INAs all on one board, and allow someone to build and resell these. This will work for 12v and 24v systems. Every RV that puts solar and lithium will be a custom upgrade and thus this solution is ideal.

If you want to supply a 48v, then beg jlcpcb to stock the ina229, and make a 16x single board version.

Some additional thoughts:

  • starting external charger/generator
  • making a several stages of excess energy usage
  • for applications with multiple charge controllers switching off most of them during top balancing to reduce the charging current during balancing

In my application I would personally use 4 or 5 relays, depending on how much would be available, and it would always be nice to have at least 1 spare channel, just in case.

I completely support a daughter card, it is much more flexible solution. Modular system is usually better for further extensions, especially in DIY and hobby projects.

I thought @yar_leo listed the reasons on a posting. The TLP222A are just sockets (2 relays per package). They are THT chips. I only want 4, but put 6 on mine.

They can handle any voltage if the shunt is low side. Again, it makes no difference if the user does not want these chips, but a huge fraction of the real market does want them. If jlcpcb will stock the ina229, then you can run 48v into it without hand SMT. They are the same footprint (according to @atanisoft).

I keep running into the same argument. @yar_leo keeps making the simplistic comparison that some might want it and some might not. You are saying the same thing. Yes, maybe your current users are balanced between wanting it and not wanting it. This logic is absurd. You have absolutely no idea how many people have investigated DIYBMS and went elsewhere because they added up the headaches of soldering, buying a relay board, connecting god knows how many wires, and oh, wait! this thing does not measure state of charge?!?

If one thinks about it, the priorities are all backwards. A solar shed, off grid home, RV, will all work just fine without the cell balancing. If I top balance my cells once, they really won’t need any balancing for a long long time. I need 8x voltage measurements going into the controller and I must have state of charge, and I must have relays. The number of people that have looked at DIYBMS and gone elsewhere is probably huge compared to the number that stayed.

Again, putting the INA and relay sockets onto the board does not stop you from making it modular and expandable to support other shunts. It is trivial to ignore those chips.

Sorry should have given a bit more context to them. Using a 3.3v supply, 560Ohm R, LED Vf of 1.3 (max from TLP222 datasheet) it results in 3.57mA current through the LED using LED Resistor Calculator. From the TLP222 datasheet it lists 5mA as the minimum recommended current for the LED. To hit the 7.5mA typical/recommended target it would need to be ~266Ohm R. A 240Ohm R yields slightly higher at 8.33mA.

Normally Watts are tracked for thermal dissipation purposes, as an example the TLP222 devices can dissipate up to 400mW per detector and 50mW per LED (there are two LEDs and two detectors in the package I believe).

The PCF8574 can source or sink around 100mA of current with each pin sourcing or sinking 20-25mA max.

I don’t agree with this statement. IF you brought brand new cells then yes, but a lot of the community are using scrap cells and they definitely need balancing - hence the DIY nature of this project.

1 Like

Unfortunately the INA229 is an SPI device and not I2C. INA238 is I2C and supports up to 85V. I wouldn’t expect JLCPCB to stock this part though.

Agreed, which is why I’m looking to use the OEM shop as a reseller, that removes the pain of just ordering single boards/systems.

Just to check @Yar_Leo you are not running the full inverter or charger current through the DIYBMS relays are you?

What are you using to switch the higher power loads?

Oh no, I have no clue what that Vf means. I saw it but couldn’t make sense of it and decided ignoring it was my best option (yes, this is pathetic, but I am a novice and can’t absorb everything at once). How are they getting 1.3v across the LED? Am I being an idiot for assuming the diagram is showing me that there is just an LED between 1 and 2? Is there some sort of voltage divider? Untitled

Correct, I’ve no idea who went elsewhere - and neither do you.

What I do know, is that there are plenty of non-DIY solutions (Batrium et al.) which cater for that market.

If you are a “tinkerer” you are likely to look at DIY based solutions (usually to save money vs time/effort) and that market is also likely to be custom building battery packs from recycled scrap cells.

1 Like

Vf is the forward voltage - V for voltage, subscript f for forward. It’s the voltage that appears across the LED when it is passing a current, i.e. lit. On low voltage supplies like 3.3 V, you most definitely cannot ignore it, because it amounts to a sizeable proportion of the circuit voltage.

1 Like

How do you reconcile these two statements?

Yes, but this is a selection bias. That’s the comments you have attracted. My point is that you have not attracted many others. Any off grid solar home/shed/RV is a custom solution, and no, a huge number don’t want to fiddle with used cells. My point is that you are very close to a solution that would appeal to a hell of a lot more.

@stuart, I am only trying to help. I am happy as a clam with my solution (as long as this Vf thing does not mean my TLP222’s will fry). Your work was a huge help to me and I am very appreciative of not only the actual hardware, but a cool project that allowed me to design a circuit that works.

I have software that I can commit if you want it.

I have a solution for myself, so my comments are totally about how to reduce your work load while making DIYBMS appealing to a much larger audience. If my posting and arguments and questions are more hassle than they are worth, send me a PM telling me to shut up.

1 Like

Quite strong words there @John_Taves :slight_smile:

If you review the posts at no point have I made the suggestion that I won’t support the INA chips or the TLP relays.

What I have been doing is working out how these can be supported and even modifying my new controller circuit to reintroduce i2c. Likewise also finding out how people are using 8 relays.

What I haven’t heard, is how to make the INA “safe” on the controller board for all users