oldswamm
100 W
I intended to order boards for this, as well as for the rest of my bike system, the first week of Oct, (but am not going to make it), and would appreciate any advice or criticism. Anybody have experience with dirtypcbs.com?
I will put a variety of drawings, gerbers, renders, eventually schematics, etc., in a zip file, at the end of this post. As I add or change drawings I will update it. No schematics for the motor controller part of the project yet (mostly just followed Lebowski’s), but I intend to draw a full set of schematics, with mods and options, well before I have the boards made.
I’d been working on a plan to build a processor board to control 2 motor controllers, mostly to control the current distribution to the 2 motors, but also for voltage controlled brakes (thank you for doing it for me Dude) and (eventually) anti spin. I then decided to revive the idea of a system for simplified wiring that I posted back in 2011, which would use 3 wires (12v+, 12v-, and a Serial I/O (or LAN)), then a month ago (or so, I’ve lost track of time), it occurred to me that I should see if Lebowski was still selling chips, and came across his controller thread.
But, it’s big for my bike as drawn, even if I found the ideal housing. So I got to looking around for enclosures I might design a board(s) for, and realized I have several 9 FET Infineon style cases, so started an effort to fit a controller using his motor control chip and electronics into that tiny case. Also, I wanted to try and use TO247 transistors.
I split his circuit into 4 parts. The power supply mounts sideways, with the caps, inductors, and other tall parts, sticking out over the low side FETs. The drivers are on their own board (6 FET only), as are the current sensors (with one extra to measure batt current for my processor). I added a second processor to the mix, primarily to interface the motor controllers to my bikes serial interface.
(The top view is more outdated than the other 2. Also, there are more, higher res pix, gerbers, etc, in the zip.)
I followed Lebowski’s design to the best of my ability, and even where I customized it, it should be able to function exactly as he designed it. Also I used surface mount for the resistors and most of the caps. I drew it as having a soldered together heat sink, but will machine it from one piece of aluminum.
I asked him, and Lebowski thought my capacitor arrangement on the sides of the bus bars should work, although I’ve changed it slightly since. (I went from one .88” cap to two .63” caps. 7.5mm lead spacing instead of 10, and higher total ripple current. I would use ESR rated caps with 5mm lead spacing, but they are too long to fit in this case.) I admit it’s beyond me to gauge the effects of my changes. The necessarily large holes in the + and - buss bars will cause the inductance to change, like a trace that gets wider and narrower. The possible effect of connecting the caps to them at different places (because of the lead spacing) is completely beyond me. Comments on the output cap arrangement would be welcome.
The TO247 are insulated around the edge, (and through the hole) allowing me to put them almost against each other, so the output stage is only a little over ¼” longer with them, than TO220. I’m still going to try and squeeze the processor board by another 1/10” (the others are easy). Actually, unless I could figure a way to shrink the PS, going to TO220 wouldn’t gain me any space at all.
The angles in the corners of the case, and its narrowness, keep me from using an esr rated cap. (See the end view.)
The power supply board is pretty much to Lebowski’s design. I left off the LEDs, but put resistors (marked ‘pd’ for pull down) to each supply in case they’re needed. For my modified system I intend to supply ‘15v temp’ from my bikes 12v, and the power to the 12F617 from one of ‘my’ processors pins, ‘PS on’. This will allow me to control power to the motor controller, and eliminates the zener current during power down. The zeners and associated parts are include on the board, so it can be built ‘true Lebowski’. This board has the high voltage stage clearance at .025” min.
(Can somebody tell me how to change a black and white ‘silk screen’ image to a yellow and transparent layer in photoshop?)
The Current measurement board is simple, and includes the HV part of the phase feedback circuits. I also included a B+ current ic, which if I can figure out how to extrapolate accurate battery current from The Dude’s RS232 info, may only appear on the 1st prototype. Oh, I used holes for the wires and slots for the current sensor legs, but still intend to solder the wires solid to the current sensor as well as the hole. I added an electrolytic that isn’t in this pic.
The driver board is very close to the original except for substituting surface mount components, and eliminating the drive for the second set of fets (questionable whether there would be enough drive for 2 of most TO247s anyway). The electrolytics can be either surface mount or through hole(.315/.197). A few days ago I got the bright idea of moving everything, except the ICs and bootstrap diodes, on the top, to the bottom, and vice versa. This puts the smt electrolytic caps on the bottom of the board where they nest among the processor board’s caps, and allows me more room below the processor board for wires. About the only thing I added to this board was an optional mlcc at the anode of each bootstrap diode. The HV portion is clearanced at .045” (probably for no good reason, unless you can find a pin compatible IC with the drive voltage rating for IGBTs). Moving the caps to the bottom allowed this board to move higher, so now I need to narrow it, to clear those angled corners…. Added resistors to all 6 outputs. If I power the board down but leave the main supply up, the gates could float, which would negate any power saved by shutting down, not to mention frying the FETs. LOL
The processor board follows Lebowski’s schematic, except I added a second processor, primarily to interface to the serial input/output line I intend to use on my bike. (I’ll start another thread on that in a week or so, and post a link back here (lots of drawing and redrawing to do). ‘My’ processor uses its own 5v supply from the bikes 12v system.
I don’t have a schematic drawn for this board yet (the schematic most needed for this part of the project)(Nor do I have the resistors all specified yet.), but the following is a description of the added processor’s pinout.
Pin 1, as well as 27 and 28 are only connected to the programming header.
2, 9, and 10, NC
3 is an op amp output internally connected to a DAC, and is connected to throttle input 1.
4 is an analogue input, shared and connected to the B+ voltage tap (which resides on the PS board)
5 is the Serial out to the bikes S I/O.
6 is the Serial input from the bikes S I/O
7 is the input from the B+ current sensor.
11, 12, and 13 are connected to the hall sensor inputs. If hall sensors are connected to the motor controller, this gives my processor an alternate timing (wheel speed) input. On the other hand if the hall signals are only available on my bikes SIO, then these lines would allow me to drive the hall inputs on Lebowski’s chip (I have no expectation of using the hall sensors for anything other than, possibly, wheel speed data (for anti spin), but the connections are there if I or someone else does need it).
14 is the PS on signal, and will actually be used as Vdd to the 12F617.
15, 16, 17, and 18 are connected to the LED outputs on Lebowski’s processor, and their status will be posted on the bikes LAN, so both motor controller’s status can be displayed on the handlebar display.
21 is connected to ‘reverse’. Since I started this design a few months ago, I’ve come to realize that I often get into situations where reverse would be nice. I was in a bog that was over the front axle and motor this spring that would have been easier to back out of than it was to push on through.
22 is an op amp output internally connected to a DAC, and is connected to throttle input 2.
23 is connected to the other processors RS232 out.
24 is connected to power good from the power supply (also connected to ‘enable’ on Lebowski’s chip). I can put a signal on the LAN that the 5 and 15v supplies came up, or an error message if they don’t.
25 is connected to the other processors RS232 in.
26 is connected to setup, so that, with the RS232 connections, I can change motor setup parameters from the handlebars.
I don’t expect the programming on this IC to be very extensive, but would like to be able to specify a current or RPM from the LAN, and have it maintain it unsupervised (I don’t mean unsupervised to the extent it wouldn’t be fail safe). I would also like to be able to tell it to return to the RPM of n mS ago, as part of my anti spin scheme.
Assuming I can get the info I’m currently using input pins for, from the RS232, this part could be replaced with an 18 pin IC, but until I see it, I want to have something I know will work. I could be convinced otherwise. The throttle info could be put in through the CAN interface, but would only save me one pin, and it’s doubtful if response time would be any better.
I should note before I continue, that I can’t even current test the controller I’m building, as my motors are 10 and 12 turn, 28mm, 9C (I’ve thought about tying 3 giant coils to the rear rack and paralleling them with one of the motors LOL). IF I could find out whether the Clyte3540 has an even number of strands, so I could separate and series it to a 3520, I MIGHT be looking for one, IF I could get it cheap enough….
I think these boards would be useful for a multi output stage setup. This drawing is for a 36 fet, using 2 power supply boards and a separate driver for each ‘stage’ (the box is drawn 6-1/2”X7-3/4”, without the needed heat sinks).View attachment 2
What do you think of my bus bars for joining the 6 10ga wires to the 2 or 4ga input/output wires? All the 10ga wires would be the same length, and attached to the bus bars about the same distance from where the heavy wire connects. The plus and minus bars could be bolted together, with kapton between, for minimum inductance, and the phase bars would be stacked below them with standoffs between. Lebowski is a very conservative engineer, and I suspect (without getting extreme and running calculations) that his power supply would supply the 5v and 15v to 3 driver boards, but I’m almost sure it would do 3 driver boards (say as the second PS in a 30 FET setup) as long as you left the 5 volt parts off that board (would require minor reprogramming). You could use the power good from the 5/15 board, to power the 12F617 on the 15 only board(s), and then use its power good for ‘enable’. I actually added extra connections to both my processor board and the driver board so 2 driver boards could be connected to the former, or the later could be daisy chained easily. A 24 fet could probably be built 4-1/2 or 5”, by 2-1/2”, by 10” or so, WITH the heat sink (that would fit on a bicycle easy enough). It just occurred to me that if the driver boards were turned 90 degrees CCW, and mounted to the bottom of the heat sinks below the FETs, the gate leads could be kept to 15mm or so (would probably require resorting to using actual connectors where I just drew them in as convenient pad arrays).
The rest of my bikes system will include, (all interconnected by the afore mentioned 3 wire harness, and each connection uniquely serial numbered), BMS(s) , charger(s), motor controller(s), in motor unit(s) (hall data, temperatures, and fan or relay control), hall sensor unit(s) (for suspension position, pas, steering angle), lights and turn signals (I’m going to narrow them down some from the current 6-1/2”), the handlebar unit (display, inputs for buttons and switches (cruise, lights, turn, limits override, 3way, etc.), throttles, analog brakes, ?). Since its pretty open, anything could be added to the system (GPS, compass, anemometer, camera control, bluetooth, even motion alarm and audio). I would like to be able to change anything, from the current/speed limits, to the song playing, without taking either hand from the handlebars.
For the rest of the system: https://endless-sphere.com/forums/viewtopic.php?f=2&t=73053
Thanks for reading.
Bob
View attachment Lewbowsik in 9 FET.zip
I will put a variety of drawings, gerbers, renders, eventually schematics, etc., in a zip file, at the end of this post. As I add or change drawings I will update it. No schematics for the motor controller part of the project yet (mostly just followed Lebowski’s), but I intend to draw a full set of schematics, with mods and options, well before I have the boards made.
I’d been working on a plan to build a processor board to control 2 motor controllers, mostly to control the current distribution to the 2 motors, but also for voltage controlled brakes (thank you for doing it for me Dude) and (eventually) anti spin. I then decided to revive the idea of a system for simplified wiring that I posted back in 2011, which would use 3 wires (12v+, 12v-, and a Serial I/O (or LAN)), then a month ago (or so, I’ve lost track of time), it occurred to me that I should see if Lebowski was still selling chips, and came across his controller thread.
But, it’s big for my bike as drawn, even if I found the ideal housing. So I got to looking around for enclosures I might design a board(s) for, and realized I have several 9 FET Infineon style cases, so started an effort to fit a controller using his motor control chip and electronics into that tiny case. Also, I wanted to try and use TO247 transistors.
I split his circuit into 4 parts. The power supply mounts sideways, with the caps, inductors, and other tall parts, sticking out over the low side FETs. The drivers are on their own board (6 FET only), as are the current sensors (with one extra to measure batt current for my processor). I added a second processor to the mix, primarily to interface the motor controllers to my bikes serial interface.
(The top view is more outdated than the other 2. Also, there are more, higher res pix, gerbers, etc, in the zip.)
I followed Lebowski’s design to the best of my ability, and even where I customized it, it should be able to function exactly as he designed it. Also I used surface mount for the resistors and most of the caps. I drew it as having a soldered together heat sink, but will machine it from one piece of aluminum.
I asked him, and Lebowski thought my capacitor arrangement on the sides of the bus bars should work, although I’ve changed it slightly since. (I went from one .88” cap to two .63” caps. 7.5mm lead spacing instead of 10, and higher total ripple current. I would use ESR rated caps with 5mm lead spacing, but they are too long to fit in this case.) I admit it’s beyond me to gauge the effects of my changes. The necessarily large holes in the + and - buss bars will cause the inductance to change, like a trace that gets wider and narrower. The possible effect of connecting the caps to them at different places (because of the lead spacing) is completely beyond me. Comments on the output cap arrangement would be welcome.
The TO247 are insulated around the edge, (and through the hole) allowing me to put them almost against each other, so the output stage is only a little over ¼” longer with them, than TO220. I’m still going to try and squeeze the processor board by another 1/10” (the others are easy). Actually, unless I could figure a way to shrink the PS, going to TO220 wouldn’t gain me any space at all.
The angles in the corners of the case, and its narrowness, keep me from using an esr rated cap. (See the end view.)
The power supply board is pretty much to Lebowski’s design. I left off the LEDs, but put resistors (marked ‘pd’ for pull down) to each supply in case they’re needed. For my modified system I intend to supply ‘15v temp’ from my bikes 12v, and the power to the 12F617 from one of ‘my’ processors pins, ‘PS on’. This will allow me to control power to the motor controller, and eliminates the zener current during power down. The zeners and associated parts are include on the board, so it can be built ‘true Lebowski’. This board has the high voltage stage clearance at .025” min.
(Can somebody tell me how to change a black and white ‘silk screen’ image to a yellow and transparent layer in photoshop?)
The Current measurement board is simple, and includes the HV part of the phase feedback circuits. I also included a B+ current ic, which if I can figure out how to extrapolate accurate battery current from The Dude’s RS232 info, may only appear on the 1st prototype. Oh, I used holes for the wires and slots for the current sensor legs, but still intend to solder the wires solid to the current sensor as well as the hole. I added an electrolytic that isn’t in this pic.
The driver board is very close to the original except for substituting surface mount components, and eliminating the drive for the second set of fets (questionable whether there would be enough drive for 2 of most TO247s anyway). The electrolytics can be either surface mount or through hole(.315/.197). A few days ago I got the bright idea of moving everything, except the ICs and bootstrap diodes, on the top, to the bottom, and vice versa. This puts the smt electrolytic caps on the bottom of the board where they nest among the processor board’s caps, and allows me more room below the processor board for wires. About the only thing I added to this board was an optional mlcc at the anode of each bootstrap diode. The HV portion is clearanced at .045” (probably for no good reason, unless you can find a pin compatible IC with the drive voltage rating for IGBTs). Moving the caps to the bottom allowed this board to move higher, so now I need to narrow it, to clear those angled corners…. Added resistors to all 6 outputs. If I power the board down but leave the main supply up, the gates could float, which would negate any power saved by shutting down, not to mention frying the FETs. LOL
The processor board follows Lebowski’s schematic, except I added a second processor, primarily to interface to the serial input/output line I intend to use on my bike. (I’ll start another thread on that in a week or so, and post a link back here (lots of drawing and redrawing to do). ‘My’ processor uses its own 5v supply from the bikes 12v system.
I don’t have a schematic drawn for this board yet (the schematic most needed for this part of the project)(Nor do I have the resistors all specified yet.), but the following is a description of the added processor’s pinout.
Pin 1, as well as 27 and 28 are only connected to the programming header.
2, 9, and 10, NC
3 is an op amp output internally connected to a DAC, and is connected to throttle input 1.
4 is an analogue input, shared and connected to the B+ voltage tap (which resides on the PS board)
5 is the Serial out to the bikes S I/O.
6 is the Serial input from the bikes S I/O
7 is the input from the B+ current sensor.
11, 12, and 13 are connected to the hall sensor inputs. If hall sensors are connected to the motor controller, this gives my processor an alternate timing (wheel speed) input. On the other hand if the hall signals are only available on my bikes SIO, then these lines would allow me to drive the hall inputs on Lebowski’s chip (I have no expectation of using the hall sensors for anything other than, possibly, wheel speed data (for anti spin), but the connections are there if I or someone else does need it).
14 is the PS on signal, and will actually be used as Vdd to the 12F617.
15, 16, 17, and 18 are connected to the LED outputs on Lebowski’s processor, and their status will be posted on the bikes LAN, so both motor controller’s status can be displayed on the handlebar display.
21 is connected to ‘reverse’. Since I started this design a few months ago, I’ve come to realize that I often get into situations where reverse would be nice. I was in a bog that was over the front axle and motor this spring that would have been easier to back out of than it was to push on through.
22 is an op amp output internally connected to a DAC, and is connected to throttle input 2.
23 is connected to the other processors RS232 out.
24 is connected to power good from the power supply (also connected to ‘enable’ on Lebowski’s chip). I can put a signal on the LAN that the 5 and 15v supplies came up, or an error message if they don’t.
25 is connected to the other processors RS232 in.
26 is connected to setup, so that, with the RS232 connections, I can change motor setup parameters from the handlebars.
I don’t expect the programming on this IC to be very extensive, but would like to be able to specify a current or RPM from the LAN, and have it maintain it unsupervised (I don’t mean unsupervised to the extent it wouldn’t be fail safe). I would also like to be able to tell it to return to the RPM of n mS ago, as part of my anti spin scheme.
Assuming I can get the info I’m currently using input pins for, from the RS232, this part could be replaced with an 18 pin IC, but until I see it, I want to have something I know will work. I could be convinced otherwise. The throttle info could be put in through the CAN interface, but would only save me one pin, and it’s doubtful if response time would be any better.
I should note before I continue, that I can’t even current test the controller I’m building, as my motors are 10 and 12 turn, 28mm, 9C (I’ve thought about tying 3 giant coils to the rear rack and paralleling them with one of the motors LOL). IF I could find out whether the Clyte3540 has an even number of strands, so I could separate and series it to a 3520, I MIGHT be looking for one, IF I could get it cheap enough….
I think these boards would be useful for a multi output stage setup. This drawing is for a 36 fet, using 2 power supply boards and a separate driver for each ‘stage’ (the box is drawn 6-1/2”X7-3/4”, without the needed heat sinks).View attachment 2
What do you think of my bus bars for joining the 6 10ga wires to the 2 or 4ga input/output wires? All the 10ga wires would be the same length, and attached to the bus bars about the same distance from where the heavy wire connects. The plus and minus bars could be bolted together, with kapton between, for minimum inductance, and the phase bars would be stacked below them with standoffs between. Lebowski is a very conservative engineer, and I suspect (without getting extreme and running calculations) that his power supply would supply the 5v and 15v to 3 driver boards, but I’m almost sure it would do 3 driver boards (say as the second PS in a 30 FET setup) as long as you left the 5 volt parts off that board (would require minor reprogramming). You could use the power good from the 5/15 board, to power the 12F617 on the 15 only board(s), and then use its power good for ‘enable’. I actually added extra connections to both my processor board and the driver board so 2 driver boards could be connected to the former, or the later could be daisy chained easily. A 24 fet could probably be built 4-1/2 or 5”, by 2-1/2”, by 10” or so, WITH the heat sink (that would fit on a bicycle easy enough). It just occurred to me that if the driver boards were turned 90 degrees CCW, and mounted to the bottom of the heat sinks below the FETs, the gate leads could be kept to 15mm or so (would probably require resorting to using actual connectors where I just drew them in as convenient pad arrays).
The rest of my bikes system will include, (all interconnected by the afore mentioned 3 wire harness, and each connection uniquely serial numbered), BMS(s) , charger(s), motor controller(s), in motor unit(s) (hall data, temperatures, and fan or relay control), hall sensor unit(s) (for suspension position, pas, steering angle), lights and turn signals (I’m going to narrow them down some from the current 6-1/2”), the handlebar unit (display, inputs for buttons and switches (cruise, lights, turn, limits override, 3way, etc.), throttles, analog brakes, ?). Since its pretty open, anything could be added to the system (GPS, compass, anemometer, camera control, bluetooth, even motion alarm and audio). I would like to be able to change anything, from the current/speed limits, to the song playing, without taking either hand from the handlebars.
For the rest of the system: https://endless-sphere.com/forums/viewtopic.php?f=2&t=73053
Thanks for reading.
Bob
View attachment Lewbowsik in 9 FET.zip