PDA

View Full Version : Design an ECU project



mk e
08-27-2009, 05:02 AM
Guys/Gals,
I was part of the Union college team some year ago and continue to play cars for fun.

One thing we had trouble was finding an ECU that did what we wanted and we could afford and I'm guessing that is still an issue, although there are some better options now.

Any way I recently got involved with a project to create open design, open source code, DIY ecu. We are working on 2 versions:

FreeEMS (FreeEMS.org) is the basic version and the one farthest along. It has 6 primary sequential injects, 6 staged injectors, 12 ignition and can be built for about $200…it’s basically a MS2 but with additional power and is a true open design. It’s getting close to working.

FreeEMS+ just kicked off and is the big bother to FreeEMS. This ECU will have 12 primary injectors, 12 stage injector all sequential, 12 ignition, traction control, launch control, lots of optional inputs to do whatever you want. Right now it looks like this ECU will cost about $750 to build.

There is still lots to do on both projects and my thought was that this might be the right place to find people with an interest in helping create a pair of open design ecu for your team of your own use. We can use a couple more hardware guys, the user interface software is working but will need upgrades to work with FreeEMS+ and we NEED people who can help with the firmware.

This would make a great Sr. design or Masters project for someone with interest and e need your help. This is your chance to help SAVE THE WORLD from over priced and under performing ECUs

If anyone is interested you can join the forum at DIYEFI.org (it’s a little slow getting out the registrations) or email me directly at markeberhardt@comcast.net

mk e
08-28-2009, 04:28 PM
The FreeEMS+ is going to use a freescale MPC5554 processor but I'm having trouble finding a compiler for the eTPU code.

Has anybody got a line on a free compiler that will do bre fore I start doing it by hand?

mk e
08-28-2009, 06:38 PM
Never mind the compiler request, I spoke too soon.
I got use of a proper professional compiler. We're rolling again....but we still need help http://fsae.com/groupee_common/emoticons/icon_smile.gif

mk e
09-01-2009, 06:14 PM
Today I learned that the second I selected the 5554 processor I had all the primary system function working....becasue crank position, fuel and spark are on the list of precompiled eTPU function you can download from the freescale site along with the c code to call them in the main program.

There are lots of other very useful function too like reading al hall sensor incase you want wheel speeds to do traction control

It doesn't get much easier

MoveX
09-03-2009, 06:16 PM
Hi,
I was in similar situation when I looked for an high end open source ECU. Ok, 16bit processors work, but you nearly have no computing power left for knock control etc. I posted on FreeEMS a while ago but there wasn't anyone interested in such a high end DIY 32bit ECU.

I'm using a MPC5567 daughtercard prototype with 2MB external RAM for software development, most parts of the application are finished and tested on HIL simulators. The card directly plugs into the ECU pcb with it's analog and mosfet parts.

Currently I'm working on knock control, mainly implementing bandpass filter with the SPE instruction set which has unfortunately some limitations.
In the process of evaluation is also the new MPC5634M which has a hardware filter for e.g. knock detection. That device comes in QFP package and single power supply which makes the pcb much much cheaper against BGA.

Pic of the prototype:
http://www.movex.de/down/MPC5567_ecu.jpg

mk e
09-07-2009, 11:19 AM
Nice!

Come on over to the diyefi forum and lets see if we can reconcile the 2 projects. We are still in the planning phase and have not have not started writing code or bought hardware. IT sounds like we are trying to build similar things and you are ahead of us.

Here’s a link to our wiki

http://wiki.freeems.org/doku.php?id=5554

mk e
09-07-2009, 04:08 PM
Let's see if 4 is a charm. Can you email me or check in on the diyEFI site?

mk e
09-07-2009, 04:55 PM
#4 work...i was typing something that kicke dthe posts into review.

Great project!

It looks like you are using a phytec board just like we are planning only with a 5567 instead of the 5554.

We should be working together or at least sharing info. I've got 6-8 solid people signed up now and were just finishing up decideing what all we think it should do and planned to start ordering stuff next week.....but I'll hold that up until I hear for you.

Mark

mk e
09-07-2009, 06:14 PM
One more...pop over to the DIyEFI site and click on active topics. We are discussing knock sensing now and think we have a good solution.

There is a knock window function in the canned eTPU function set that can be combined with a simple circiut on the I/O board to get it done...we think.

MoveX
09-08-2009, 02:53 AM
I've already posted on the 5554 thread @ DIYEFI forum.

For MPC55xx family, the eTPU knock window function should be enhanced to combine time and angle domain. That lowers eQADC and DMA load tremendously.

Will continue further discussion there....

mk e
09-17-2009, 05:28 PM
Just a quick update.

The fancy version (5554) has moved to
www.openecu.info (http://www.openecu.info)

It turns out the team working on the inexpensive version and the team working on the top-shelf version just don’t agree on anything…..who would have thought.

mk e
01-06-2012, 11:41 AM
A little update. I got distracted with other projects and the ECU was delayed, but its pretty far along now.

The project moved again with the source code and such here
http://code.google.com/p/open5xxxecu/

the forum here
http://forum.open5xxxecu.org/index.php

The code is being written to work on a 5554 or a 5634. The 5634 might be of particular interest to FSAE teams because it's cheaper (like $15) and can be hand soldered and still really powerful. Also FreeScale now has a 5634 demo board for $99 that can be an ECU if you can build a driver board to go with it. FreeScale will also be releasing an ECU Demo unit soon that uses the 5634 and our code should run on that board.

The designs for our HW are also posted on the google code site. The 1st spin is being assembled now and so far seems to be working.

For a tuner we have TunerStudio working which is a nice program and is a free download for the basic version.

All our code and designs are on the MIT license, so free to use, copy, share, sell, whatever.

The phase 1 (should run an engine properly but has no traction control or other such planned features)firmware code is being tested and debugged now.....so if anybody has any interest in helping with the debugging and testing let me know.

mk e
01-10-2012, 09:56 AM
Breaking News:

The o5e code now runs!

It reads crank and other sensors and outputs spark and fuel, talks to the tuning SW, works.

Now....there is the small issue of making sure the fuel and spark outputs are the INTENDED fuel and spark out puts but 1 step at a time http://fsae.com/groupee_common/emoticons/icon_smile.gif

wagemd
01-10-2012, 12:36 PM
What HIL are you using? General impressions?

mk e
01-10-2012, 12:59 PM
Originally posted by wagemd:
What HIL are you using? General impressions?

excel http://fsae.com/groupee_common/emoticons/icon_wink.gif

There just doesn't seem to be any reason to simulate when real hardware is available and doesn't require all the added validation or model steps a simulation approach would.

wagemd
01-10-2012, 01:12 PM
There just doesn't seem to be any reason to simulate when real hardware is available and doesn't require all the added validation or model steps a simulation approach would.

I agree, however, the ECO car team on campus just received a dSpace HIL and I'm tempted to see what it can do... I cant resist messing with a machine that expensive http://fsae.com/groupee_common/emoticons/icon_smile.gif

mk e
01-10-2012, 03:03 PM
Originally posted by wagemd:


I agree, however, the ECO car team on campus just received a dSpace HIL and I'm tempted to see what it can do... I cant resist messing with a machine that expensive http://fsae.com/groupee_common/emoticons/icon_smile.gif

Well sure if it's just sitting there waiting for someone to use it.http://fsae.com/groupee_common/emoticons/icon_smile.gif


I think the next project is to find a cheap hardware for code to run on.

I'm pretty sure the GM and Chrysler ECUs up through about 2010 use a 5554 processor.....I need to figure out exactly which ones and get 1 opened up to see what's attached where. These things are like $100 on ebay which is a pretty cheap ECU.

The woodward ECM 5554-112 is also a candidate...but again I need to know what connector pins end up at what processor pins

mk e
01-13-2012, 04:49 AM
In the quest for CHEAP hardware.....how's $150 sound for 8 fuel/8 spark full sequential ECU?

I just bought this:
http://www.ebay.com/itm/2011-S...9977b#ht_2612wt_1237 (http://www.ebay.com/itm/2011-SILVERADO-SIERRA-6-0L-CRUZE-1-4L-ECM-ENGINE-CONTROL-MODULE-12642100-/330660681595?pt=Motors_Car_Truck_Parts_Accessories&fits=Model%3ACruze%7CYear%3A2011&vxp=mtr&hash=item4cfce9977b#ht_2612wt_1237)

It's a GM E78 ECU (E39 is good too and there are direct injection versions) brand new and delivered to my door for $150. It has 8 spark and 8 Fuel channels and a lot of other stuff (I'll find out exactly what once I get it open) and most importantly uses a 132 MHz MPC5566 processor so it can run the o5e software once I figure-out which processor pins are connected to what.

Another option I've been looking at one this thread:
http://fsae.com/eve/forums/a/t...607348/m/90820502151 (http://fsae.com/eve/forums/a/tpc/f/125607348/m/90820502151)

The woodward ECM- 0554-112-0904-F
http://www.neweagle.net/suppor...12pin/36350_0904.pdf (http://www.neweagle.net/support/wiki/docs/Datasheets/112pin/36350_0904.pdf)

Is very capable and also 8 fuel, 8 spark but for sure had 14 optional drivers and 33 inputs available. It runs a 80MHz 5554 processor so can run the o5e software. This is a tad slower processor than the GM unit, but still PLENTY capable (something like 4 times the speed for the processor in the MoTec M400/600/800 family). FSEA teams can get these for $250 I'm told, but retail is $500.

The New Eagle guys are telling me the woodward uses proprietary boot loader and won't work for me....but to me that sounds like "Mark, you're going to need to open the case to flash in the new software". But, they also say they are getting in a couple other 55xx base controllers soon that might work and will see about getting one to me for testing.


Once the o5e software is loaded into the ECU it becomes fully user configurable using the o5e TunerStudio interface and will have all the o5e features that there hardware has drivers to support.

I'm really liking the $150 GM option so that is going to the top of the ToDo list.

A couple people have also expressed interest in the woodward option so that will be next if I find the GM option doesn't offer all the capability that the woodward.

mk e
01-13-2012, 05:21 AM
o5e control logic.

I thought it might be worth not only telling you that it looks like we have a $150 hardware option to go with the free software, but also what the software does.

This software works differently for other ECU software because it's designed from the ground up to work with your engine simulation software. at it's heart is what we call the "Engine Model" which is basically the predicted torque curve from your simulation work. If you're model is good, the engine will run nicely once you've enter the model information (and or course the basic set-up stuff like how many cylinder, how many crank teeth, etc).

If you don't want to use the model, you can just enter 100% in all the cells and tun using a normal fuel table, but when you do use the model the base fuel table will be all zeros and should get you within about 5% or perfect. How easy is that? http://fsae.com/groupee_common/emoticons/icon_smile.gif

o5e also allows stuff that other ECUs do not like each injector can have it's own dead time and eahc cylinder it's owe fuel map. This means that you could put in 4 completely different injectors and completely bugger the the cylinder to cylinder air flow in you intake/exhaust and still get the engine tuned perfectly. Or if you've done everything right it means you can dynamically match the injector set you have without needing to spend $1000 for a custom matched set.
here's why you should care about dynamic matching:
http://www.injectordynamics.com/dynamicmatch.html

Same for ignition timing, each cylinder's timing can be individually mapped if you choose. this is helpful if you are seeing a little more heat of boost at some of the cylinders and don't want to have to just pull back the timing or all the cylinders and give up a few hp in the process.

o5e also handle things like prime, warm-up, acceleration enrichment and deceleration derichment in a much more elegant and controllable way than most other ECUs. This should allow you to get near perfect operation right from the time you hit the start button though completely heat soaked and every where in between just like a factory engine (we have THE most powerful processors out there)....but just like the engine model all the features are designed to be easy to disable

I've started writing a user manual
http://code.google.com/p/open5...n5xxxECU_User_Manual (http://code.google.com/p/open5xxxecu/wiki/Open5xxxECU_User_Manual)

I still have a ways to go, but it's getting there.

There is also a sample project that you can look at here:
http://code.google.com/p/open5...allTheTuningSoftware (http://code.google.com/p/open5xxxecu/wiki/InstallTheTuningSoftware)

If you want to have a look at how it works. Right now it's just the basics, but more features are coming all the time.

mk e
01-20-2012, 08:31 AM
Code testing continues and it's got some bugs..no real surprise there I guess but we're getting them fixed as we find them.

I bought a couple things to play with. One is the GM E78 ecu it's got like 120 pins and what looks like gobs of driver s and input circuits......it's also a serious pain in the butt to get a part so I can map it all out. Once I get it mapped I think the only practical way to use it is to get our CAN com stuff working so the processor can be programmed without needing to open the ecu. I still think this is a great solution, it's going to take some time.

Purchase #2 was one of the freescale $99 5634 demo boards. This is a nice board and I've been doing all my debug & testing with it. It plugs straight into a USB port on the PC for programming and power so you don't need any other stuff to make it work. Nice. I like it so much that I've been talking to Jean at:

http://jbperf.com/

about the possibility of him offering a universal ECU I/O board that can can be plugged together with the 5634 board (or any processor board) to create an functioning ECU and I think he's he's going to do it. The plan is looking like something aimed at 4 cyl with a 48 pin connector It would have a connector to allow any ECU board to be wired to it, or he's talking about dong a couple processor boards (probably a 5634 and an S12(MS or freeems code runs on these) )that could be plugged on directly so the assembly will fit neatly inside a case. I'm not sure on the timing or pricing but we were talking in the $100 to maybe $200 range for the assembled board making the full ecu under $300.

Stay tuned.

wagemd
01-24-2012, 09:15 AM
mk e, what compiler did you end up using? I just happened to buy a 5634 last week as well (wanted my own, cooler version of the Freescale dev board we are using in my embedded class). It includes the CodeWarrior editor/compiler/everything software, but it looks like that expires in 30 days http://fsae.com/groupee_common/emoticons/icon_frown.gif

mk e
01-24-2012, 04:03 PM
Originally posted by wagemd:
mk e, what compiler did you end up using? I just happened to buy a 5634 last week as well (wanted my own, cooler version of the Freescale dev board we are using in my embedded class). It includes the CodeWarrior editor/compiler/everything software, but it looks like that expires in 30 days http://fsae.com/groupee_common/emoticons/icon_frown.gif

We're using a free demo version of CodeWarrior. It's fully functional but limited to 128k which seems ok, but it also has a 5000 source line limit which we are running into...I was at 4998 this afternoon and already commented out a couple small things. Paul, aka "the minimalism" is working now to reduce our line count and we might be able to put some of the tested and good stuff into libraries....I think we'll stay within the limits.

wagemd
01-24-2012, 04:48 PM
Originally posted by mk e:
<BLOCKQUOTE class="ip-ubbcode-quote"><div class="ip-ubbcode-quote-title">quote:</div><div class="ip-ubbcode-quote-content">Originally posted by wagemd:
mk e, what compiler did you end up using? I just happened to buy a 5634 last week as well (wanted my own, cooler version of the Freescale dev board we are using in my embedded class). It includes the CodeWarrior editor/compiler/everything software, but it looks like that expires in 30 days http://fsae.com/groupee_common/emoticons/icon_frown.gif

We're using a free demo version of CodeWarrior. It's fully functional but limited to 128k which seems ok, but it also has a 5000 source line limit which we are running into...I was at 4998 this afternoon and already commented out a couple small things. Paul, aka "the minimalism" is working now to reduce our line count and we might be able to put some of the tested and good stuff into libraries....I think we'll stay within the limits. </div></BLOCKQUOTE>

Interesting. It looks like I misread the size of the eTPU headers they offer and was convinced I wouldn't be able to do anything with the eval limits. I'm a little less annoyed now... Do the libraries not count against the size/line limits?

mk e
01-24-2012, 05:31 PM
Originally posted by wagemd:

Interesting. It looks like I misread the size of the eTPU headers they offer and was convinced I wouldn't be able to do anything with the eval limits. I'm a little less annoyed now... Do the libraries not count against the size/line limits?

Well, you don't want to load eTPU stuff that you don't need....but we have everything including an OS loaded under the limit.

Libraries code toward the size limit but I don't think against the line limit, not sure yet though.

The freeScale code that goes with the eTPU code is just awful.....lots of line/size/operations that just aren't needed. a divide is like 37 cycles and they do several per fuel channel update for no reason at all.

If you want a light show on your board, I just pushed a version of the o5e code that has:
LED2 - OS heart beat
LED3 - crank position status - full sync
LED5 - spark cyl 1
LED6 - fuel cyl 1 (not blinking at the moment)

on 2&3 a 1 sec blink = good, full on or fast blink = broken

edit - the eTPYU is generating a 60-2 crank wheel on eTPU30 and a cam signal on eTPU31, so to use them you have to jumper:
ETPU30 to eTPU0 (crank input)
eTPU31 to eTPU1(cam input)

mk e
04-26-2012, 07:14 AM
A quick update.

as of yesterday TunerStudio is fully functional with the o5e code. This was a huge step.

The first real engine test should happen in the next 3-6 weeks.

I realized a couple days ago that in theory you could take a $99 5634 demo board and plug it into a $90 MS3xpander board and have a functioning ecu for under $200. I'm going to try to test this on an engine in the next few weeks and see if it actually works.

The reprogramming of a GM ecu is proceeding painfully slowly....its so much easier when pinout and chip info is available. It's progressing though.....3-6 months I'd say.

The FreeScale demo ECu board is now scheduled for limited release in June with a price point of $500. This board is a 5634 processor, 4 spark, 8 fuel, stepper driver and few more goodies so pretty much perfect for most FSAE applications. I'm guessing there will be a better FSAE price and I'll talk to them about that when I meet with the project engineer early June.

More to come.

hameeds01
04-26-2012, 10:45 PM
i designed my own ECU have a look at it guys

http://fsae.com/eve/forums/a/t...607348/m/17720845151 (http://fsae.com/eve/forums/a/tpc/f/125607348/m/17720845151)

mk e
04-27-2012, 04:42 AM
cool project.

I know someone (don't actually know, he posts on my ecu forum from time to time)messing with a PIC controller to run a tractor...his setup is much less capable than yours though.

mk e
05-02-2012, 06:23 AM
The o5e code is working pretty well on the bench at this point. Spark and fuel outputs look correct, all the tuning seems to work.

We're still going through and confirming EVERYTHING, adding some error checking in the SW, and there are still lots of optional features that need to be added.....but I think it about readsy for an engine http://fsae.com/groupee_common/emoticons/icon_smile.gif

hameeds01
05-18-2012, 07:23 PM
ECU using dsPIC

http://fsae.com/eve/forums/a/t...607348/m/17020206151 (http://fsae.com/eve/forums/a/tpc/f/125607348/m/17020206151)

mk e
05-21-2012, 09:43 AM
Very Cool.

Now we just need to get you over to the O5e project and working with a real processor http://fsae.com/groupee_common/emoticons/icon_smile.gif

hameeds01
05-21-2012, 10:52 AM
Sir u know what i am a JOBLESS fellow i need a JOB,

Mbirt
05-21-2012, 12:25 PM
hameeds,

mk e has a cool thing going here and doesn't deserve your spamming of his thread.

With that said, here are a plethora of engine controls jobs in India: http://www.simplyhired.co.in/a...er+-+engine+controls (http://www.simplyhired.co.in/a/jobs/list/q-engineer+-+engine+controls)

mk e
05-21-2012, 03:08 PM
Originally posted by hameeds01:
Sir u know what i am a JOBLESS fellow i need a JOB,

Well I don't have any jobs, but I can help you get up to speed with writing ECU code for an actual ECU processor and that might lead to a job. The 563x series processors are specifically aimed at the developing world auto makers....I'll bet it would help you resume and the O5e code is on a very open license so you are free to sell products based on the the code, but we do ask that you contribute something if you are going to take something...not required of course.

mk e
05-21-2012, 03:29 PM
Originally posted by Mbirt:
hameeds,

mk e has a cool thing going here and doesn't deserve your spamming of his thread.

Thanks and no worries on the other posts, he's got a couple cool projects going.

We just locked our master code repository and are now officially in real version control.


First engine test is scheduled got the first week of June. This will use the $200 HW - $99 trk5634 jumpered to a MS3x I/O board and a $10 USB to TTL cable. It doesn't get much cheaper and you might be able to get FreeScale to sponsor you the 5634 board.

FreeScale is also very close to release on the $500 demo ecu board. I'm supposed to have a prototype in my hands in 2 weeks....and while I'm talking to them I'll see what I can do about getting the wheels turning on FSAE sponsorship because this is an IDEAL product for an FSAE team. It's 4 spark, 8 fuel, and I think 8 optional out with gobs on inputs. We need to add SPI to get the drivers to work right, but I'd guess we'll have this running O5e and ready to go on an engine by September.

We continue to make progress in the GM E78 cranking but it's slow going, particularly with everyone working toward first engine test.

Another HW option is a Chrysler ECU. The new ones are 5566 like GM but the older ones that can be had for $75 - $100 are 5554 which is basically the same processor. 8 spark, 8 fuel, 8 optional outs I think. We just had a guy jump is whos been hard at work mapping out the older version for the past few years and is basically ready to to test load the O5e code into it, we just need to take his info and enter it into the o5e I/O setup. I suspect the is a watchdog timer in there and probably a fancy one that is expecting the processor to talk to it....but we don't know what it's expecting to hear from the processor or how often it wants to heard it so that could be a problem....I'm guessing even with the new info this option is still a year away.

mk e
05-23-2012, 10:38 AM
I'm making arrangements to get a 5634 board into hameeds01's capable hands so hopefully it won't be too long before we see a video of his engine running O5e and he can start helping us expand the code base.

mk e
05-27-2012, 07:23 PM
I did some testing on the franken-ecu tonight. The 8 fuel is working right, I made up an inline a voltage divider for Vbattery measurement and it seems to be working right (the processor wants to see 0-5V, "12v" is normally 13.7V so a voltage divider is needed (2 resistors in series to ground with the sensor wire at the junction). I'll test spark and the rest of the analog inputs (TPS, Coolant, InletAirTemp) tomorrow then it's ready for an engine.

In other news Jon now has his $100 Chrysler ecu firing the spark channels using the O5e code. Fuel is a little harder as it appears there is a watchdog of some kind acting as the gate keeper for the fuel channels that needs to be defeated or figured out.

mk e
06-08-2012, 12:12 PM
A semi-big day - the FrankenECU was finally working well enough on the bench that I decided it was time to send it to an engine. It should be on a car in a couple days and we'll see what happens.

Some of the delay was special request related. The car that I have lined up for testing the FrankenECU doesn't have a cam sensor....it was supposed to by now but it doesn't so Waste spark/semi-sequential had to be added to the code earlier than planned. "Oh, and the spark pulse is inverted, I'll need that too".

Then from a guy getting ready to test on a honda spada (odd fire V twin, no cam)"I don't want waste spark, and I don't have a cam....." so now there is code to it that MIGHT work....that's a hard one.

In other news I got myu hands on a prototype of the coming FreeScale Demo ECU and it's pretty nice, this afternoon I'll be adding it as a supported HW to O5e. Again these will sell around $500 and are 8 fuel, 4 spark (if looks like on-board coil drivers, I need to confirm) and a good number of I/O options. I spoke to them about FSAE sponsorship and they were quite willing to consider it so you may be able to get them cheaper than the $500 retail price.

I also got to see a new MegaSquirt prototype last week......and they have certainly come a long way from the MS 1 days. Its a 5634 processor, 8 fuel, 8 spark, 70 pin connector, nice and compact. Pretty good. It's supposed to sell In the $400-$500 range I think. Bruce said he'd get me a beta version in a month or 2 to test. Obviously it will have it's own code but I'll set up the (far superior http://fsae.com/groupee_common/emoticons/icon_smile.gif ) O5e to run on the HW too.

The Chrysler ECU needs CAN instead of serial so there is a slight delay while Jon gets that on line.....maybe the end of the month.

It looks like there should be several nice inexpensive HW options for O5e come fall and FSAE season.

mk e
06-13-2012, 06:06 PM
The FrankenECU is being wired to a ferrari 308
(no sense going small http://fsae.com/groupee_common/emoticons/icon_smile.gif ) ....hopefully tomorrow will be the big first run day!.....hopefully.....

Priyanka
11-05-2012, 11:01 PM
You can get perfect job of your choice. Its just you have to put your some efforts in the project as well as finding perfect Jobs in india (http://jobs.taaza.com) at right platform.
There are thousands of companies in India which are offering engine controls jobs.

mk e
03-12-2013, 09:18 AM
I got busy and let this sit for a while but it's rolling along again.

The first install that I know of is in-progress...so hopefully this week we'll get an engine to run. Fingers crossed.

I found a commercial HW place willing to make o5e ready ECUs. He's telling me about 6 week and a retail price about $500.

We're talking about a beta program where you buy one and if you have it installed and are testing within 30 days you get a 30% rebate.

I'll try to arrange some kind of FSAE discount program too.

I know this is way late for this years FSAE season, but plenty early for next season.