8 Battery Lead Acid Slave Board

Threads relating to the BMS system begun by Peter Perkins

Moderators: GregsGarage, retepsnikrep

User avatar
dillond666
Posts: 139
Joined: Mon May 26, 2008 7:52 pm
Location: Central Scotland

Re: 8 Battery Lead Acid Slave Board

Postby dillond666 » Mon Mar 21, 2011 12:41 pm

SERIAL COMMS:

Had a lot of trouble over the weekend getting my master and slave boards to communicate.
Seems the main trouble is that the built in pull-up resistor on the Avago fibre receiver is too strong (1K) for the wimpy parallel opto to overcome so I've had to do a little stanley knife PCB adjustment and bung in a couple of wire links. It's a wee bit annoying having to modify my brand new PCBs but not the end of the world.
I wish I had made the thermal breaks round the pads on the ground plane a little more generous too as it is really hard to solder/desolder components that attach to the ground plane. I suppose it's all a learning curve :wink: I still like Gregs surface mount idea, that's a definite for the future.

Got most of the display routine functional now. I decided to draw most of the screen at the start of the program and just use the main display routine to change numbers on the screen, this means less serial comms and more speed.

Derek

User avatar
dillond666
Posts: 139
Joined: Mon May 26, 2008 7:52 pm
Location: Central Scotland

Re: 8 Battery Lead Acid Slave Board

Postby dillond666 » Tue Apr 05, 2011 9:55 am

HARDWARE:

All the serial comms are working now 8) I have bypassed the transistor on the masterbus output on both boards as I couldn't get it to work properly. The fall time of the square wave looked a little slow but I just don't know enough to fix it, I must have been driving it incorrectly but these are the little annoyances that crop up when you are trying to teach yourself electronics as you go. The theory behind the transistor was that it would allow me to drive the Avago transmitter hard without overloading the opto outputs. I should have read the datasheet properly though as the optos are capable enough of driving the Avago :oops:

SOFTWARE:

After much debugging I have uncovered an error in the Axepad IDE that I have been using. The 18m2 compiler messes up when you try to peek and poke word variables. I think this issue is now resolved in the windows only "Program Editor" but not on the multi platform "Axepad" :cry: boo hiss. The workaround is not elegant but it works,
job in progress software is here http://www.dillond1.pwp.blueyonder.co.u ... master.bas

Next job is to rig up the hall sensor on the propshaft for the speedo and to remove the voltage pot on my Zivan charger and modify it (any advice?) Ifigured an opto possibly switching a parallel resistor depending on where the pot is set at normal charging voltage.

Derek

GregsGarage
Posts: 870
Joined: Tue Apr 01, 2008 5:27 pm
Location: Galashiels, Scottish Borders
Contact:

Re: 8 Battery Lead Acid Slave Board

Postby GregsGarage » Tue Apr 05, 2011 11:21 am

dillond666 wrote:Next job is to ... remove the voltage pot on my Zivan charger and modify it (any advice?) Ifigured an opto possibly switching a parallel resistor depending on where the pot is set at normal charging voltage.

Derek


I don't think you actually want or need to remove the voltage pot from the Zivan. Leave it in place and carefully solder 2 wires to the appropriate pins. With the wires open the Zivan functions as normal. The original idea was to connect these 2 wires to an opto and pwm them to cutback the charger if required. I think Peter found that simply shorting the wires with the opto provided the control he needed, but you are using lead acid so I don't know how well that will work for you, it might need some sort of variable resistance across the wires.

The original idea for modifying the Zivan is Cedric Lynch's and can be found here. Also on the page is a circuit for controlling the charger without modifying it. Basically to slow the charge rate down we need to fool the charger into thinking pack voltage is higher that it actually is. So modifying the trim pot is one way or adding a resistance in series is another way.
Greg Fordyce

Daewoo Matiz
http://www.evalbum.com/4191

User avatar
dillond666
Posts: 139
Joined: Mon May 26, 2008 7:52 pm
Location: Central Scotland

Re: 8 Battery Lead Acid Slave Board

Postby dillond666 » Sat Apr 09, 2011 4:10 pm

MODIFIED ZIVAN:


After a little playing around I now have a more controllable Zivan. The way things are with the Zivan is quite fortuitous, it means my charger will normally run "throttled" down and the BMS will be required to tell the charger to go to full throttle (useful failsafe). I am using an optoisolator and series resistor parallel to the ground half of the voltage potentiometer on the Zivan. I used a variable resistor whilst experimenting and then put in the appropriate values of fixed resistors for reliability reasons (I only had single turn pots to hand). The charger is set to switch on at 180.7 volts (13.9v per batt) and will go up to 183.3 volts (14.1v per batt) at the command of the BMS. I,m not sure if this will be enough throttling but it's easy enough to change. The optimum solution is probably a digital pot as Peter toyed with a while back, but quick and dirty will do for now :wink:

PICS of Modification:

http://www.dillond1.pwp.blueyonder.co.uk/zivanmod.JPG
http://www.dillond1.pwp.blueyonder.co.uk/zivanmod2.JPG

Derek

User avatar
dillond666
Posts: 139
Joined: Mon May 26, 2008 7:52 pm
Location: Central Scotland

Re: 8 Battery Lead Acid Slave Board

Postby dillond666 » Fri May 20, 2011 12:03 pm

The car's on the road!!
I am legal and mobile. Cheap insurance and free road tax, I'm a happy grinning EV pilot. The car is much noisier inside than it is outside. British leylands crappy gearbox, sounds like a Landrover! A bit of sound deadening and hole sealing should do the job though.

BMS is getting interference though :( It is always battery 6 comms error, which is at least consistent, unlike the old BMS. The fibre cable has eliminated problems with the data busses so I am confident that the problem is EMI related. The way I have the batteries distributed and cabled means there is a large loop of high current cable with the rear BMS board sitting slap bang in the middle :shock: I am going to try shielding the enclosure and grounding the enclosure to the traction pack ground whilst keeping it insulated from the chassis ground. Hopefully this will work, but I'll be looking to reroute the traction cables to keep them close together instead of forming the 1metre diameter antenna that it is just now. I had originally routed the cable this way to keep the cable runs as short as possible but an extra metre or so of cable wouldn't be too high a price to pay for less interference.

Now begins the process of bug squashing and general refinement, Perhaps I'll use my 40 pints of homebrew beer (yummy) to inspire and lubricate the process :D

Derek

User avatar
retepsnikrep
Posts: 1387
Joined: Sat May 26, 2007 4:50 pm
Location: North Yorkshire England
Contact:

Re: 8 Battery Lead Acid Slave Board

Postby retepsnikrep » Fri May 20, 2011 1:33 pm

Good effort well done have a pint for me.
Regards Peter

Two MK1 Honda Insight's. One running 20ah A123 Lithium pack. One 8ah BetterBattery Nimh pack.
One HCH1 Civic Hybrid running 60ah A123 Lithium pack.

GregsGarage
Posts: 870
Joined: Tue Apr 01, 2008 5:27 pm
Location: Galashiels, Scottish Borders
Contact:

Re: 8 Battery Lead Acid Slave Board

Postby GregsGarage » Fri May 20, 2011 5:26 pm

Congratulations as well.

Greg
Greg Fordyce

Daewoo Matiz
http://www.evalbum.com/4191

User avatar
dillond666
Posts: 139
Joined: Mon May 26, 2008 7:52 pm
Location: Central Scotland

Re: 8 Battery Lead Acid Slave Board

Postby dillond666 » Fri May 27, 2011 4:16 pm

Oh well, after the excitement of zooming about in my electric car it's groundhog day again. Interference of the BMS is the problem.
The master portion of the system is picking up garbage through the power leads and the slaves are having comms problems sometimes, but I'd wager that's due to power line garbage too.
A dc-dc converter would fix the master I suppose but I can't help thinking the answer lies in the use of chokes and capacitors all round. How hard can it be to make an uber low pass filter thingy? Perhaps I should isolate the 12v chassis ground from the chassis? The drive cabling must be coupling to the chassis ground.
I'd kill for a shot of a spectrum analyser, that'd help to paint a better picture of my emi/rfi hassle. I'll have a sniff around with the oscilloscope and see what I can find. I'm not sure whether to try and armour plate the BMS or modify the charger and controller to halt the problem at source ..........you can hear the charger on an AM radio! Much trial and error ahead :roll: Any EMI experts out there?

Derek

User avatar
retepsnikrep
Posts: 1387
Joined: Sat May 26, 2007 4:50 pm
Location: North Yorkshire England
Contact:

Re: 8 Battery Lead Acid Slave Board

Postby retepsnikrep » Fri May 27, 2011 5:16 pm

Do the dc-dc converter trick first if noise is comming in on the master 12v power input or as you say add some chokes and caps etc etc. Get the master stable then sort comms between master and slaves.
Regards Peter

Two MK1 Honda Insight's. One running 20ah A123 Lithium pack. One 8ah BetterBattery Nimh pack.
One HCH1 Civic Hybrid running 60ah A123 Lithium pack.

GregsGarage
Posts: 870
Joined: Tue Apr 01, 2008 5:27 pm
Location: Galashiels, Scottish Borders
Contact:

Re: 8 Battery Lead Acid Slave Board

Postby GregsGarage » Sat May 28, 2011 9:08 am

Maybe its something to do with the weather in Scotland as my car gave me some EMI grief yesterday as well. :roll: Here's what happened. I had removed the controller to fit a bigger heat sink, well actually to fit a heat sink. :shock: This involved removing the Zivan charger to get to the controller. After putting it all back together and a round trip home and back to work the next day, I put it on charge. In the afternoon, went to drive the car and discovered it hadn't charged. So put it back on charge and started getting serial comms errors which caused the bms to switch off the charger, as it should. A bit of investigation and I tracked the problem down to the control wires from the solid state charger relay being to close to the mains lead, the errors where happening while the car was plugged in, even with the relay and charger switched off. :evil: Moving the wires further away helped, but I had also modified the master board when I was trying out the current loop idea, basically it was still connected to the master with Peter's isolated DC-DC trick as well. The current loop was getting it's supply from the same 12 volt supply as the charger relay circuit, so the noise must have been feeding back through this. I have now removed the current loop circuit from the master and it charges fine. Will give the car a run later, as I had to leave it at work last night, and check it's all o.k.

I don't know if any of that helps, but try changing one thing at a time while looking at the noise on the scope. Shielding seems to be a bit of a black art, I have found my comms better without the shielding on my data cable earthed than with one end of them earthed. :? I am investigating a different idea to improve serial comms between the slaves, its called the EVILbus. It was originally implemented at 1200 baud, but I have been corresponding with Lee Hart, one of the designers about changes to improve the speed to 9600 baud and reduce some of the component count. I need to breadboard it to see if it works and will post results when I do.

This would also require a new master as well and this project has caught my eye. The Maximite is a Pic32 chip with a basic interpreter programmed in. Output is composite video (or VGA) and input is a ps2 keyboard or usb. It also has a SD card slot for loading programs and storing data. What he has done is recreate something like the old TRS80 computer on a Pic32, including a BASIC interpreter that has line numbers :!: , how retro can you get, but with the added benefit of 20 I/O pins from the pic being available. Yes the interpreted basic won't run as fast as a complied program, but this is a 32 bit 80mhz processor. And being able to program your master software in a free version of basic is nice, but with this you don't even need a computer to do the editing, just plug in a keyboard and away you go. At the moment though it has one glaring omission, no serial comms. :( But he has said this will be added in a firmware update, so I will keep an eye on this project.
Greg Fordyce

Daewoo Matiz
http://www.evalbum.com/4191


Return to “BMS thread”

Who is online

Users browsing this forum: No registered users and 27 guests