Jump to content
IGNORED

Any C or C++ programmers out there?


GG54172

Recommended Posts

I am working on my master's thesis. Basically I am designing a fuel injection system for my Suzuki Dr650. It does not have to be super sophisticated, but I would like to program a microcontroller well enough to actually build the system. However, I am a powertrain/mechanical engineer by education, so programming is a black voodoo cult art to me. I know it's not hard, but I just don't have the key piece of information to be able to do it yet.

 

So, I have an HC6811 microcontroller and I would like to program this thing to accept a couple of inputs (wide band O2, mass air, temp, crank, cam, and throttle position), manipulate those inputs (calculate rpm, change in O2, MAF, Throttle postion), and provide an output (Injector PWM). I will also need proportional, integral, and derivative control (PID).

 

So, my question is: Do I program this thing in assembly, C, or C++? Can any of you recommend some books for learning any of these languages?

 

My ultimate goal is to actually fuel inject my dirtbike, and then move on to multi cylinder engines.

Thanks.

Edited by Gregory Gill
Link to comment
Share on other sites

well, I'm a VB / VBA programmer specializing in medium sized database applications and MS Office or other VB compatible apps integration development, what you're talking is as much jibberish to me as english is to a newborn!

 

Good luck!

Link to comment
Share on other sites

I would not call myself a "programmer" per se. However, I spent this last academic year studying electronics and took two courses on microcontrollers. We used the 68HC11. I would personally recommend that you take the time to learn how to program in assembler (as11 in this case). The tools are usually free, and the code is MUCH smaller than C code when compiled. This is a major issue if your program is large and your memory space small. Assember is actually simple enough to learn, the only thing is you'll have to learn a lot about the hardware along the way. This is an excellent approach if you intend to use microcontrollers often. It pays to understand the hardware at that level.

 

The book I used in college was quite good and I liked it.:

 

MC68HC11: An Introduction

Software and Hardware Interfacing

2nd edition

Huang

ISBN 07668-1600-1

 

You would do well to have an evaluation board to learn with, if you don't already have one. There are a great many resources online and you can find them if you simply Google the MC68HC11. If you have time, take a course. It is invaluable to have a person tutoring you. The learning takes place much faster.

 

Also look into the PIC micro's (http://www.microchip.com) as they are tremendously popular, have over 2000 different versions, and enjoy perhaps the greatest support online of all MCU's.

 

I don't think I'll have the time to actually help you. I'm sorry. I've been laid-off and I am now studying Energy Systems Engineering full-time at college. I don't have time to breathe between the homework, the exams, and my family. I would, however, like to hear how you are doing as time goes by. I have a strong interest in injecting hydrogen into internal combustion engines and I will be designing my own hardware to do this someday. I simply have to concentrate on my studies for now.

 

I hope this has been of some help.

 

Good luck, and feel free to stay in touch.

 

Jeff

Link to comment
Share on other sites

Greg, i'm not deep into programming in the Languages you ask for either. But i can tell you, the only real Deal on this Issue is Assembler. It will work for an single Cylinder Engine with the other Languages, but on a multi Cylinder Bike you will experience Timing Issues with all the Input Sensor you outlined.

 

I didn't understand what's your final Goal, making the EFI work on the Bike or working out the System in a engineered, but not necessarily functioning Mode for a Degree.

 

If you want to have a working System on the Bike, take a Look at Microsquirt EFI and work with this System. Bowland an Grippo have done a Lot of inventive Work and they have all you need and a Lot more. On the other Hand i'm quite sure you know the System already. I've worked on several free programmable EFI Systems and even if the Program is Windows based, there is a Lot of programming to do, without working on the Basic Functions themselves.

Link to comment
Share on other sites

Greg, i'm not deep into programming in the Languages you ask for either. But i can tell you, the only real Deal on this Issue is Assembler. It will work for an single Cylinder Engine with the other Languages, but on a multi Cylinder Bike you will experience Timing Issues with all the Input Sensor you outlined.

 

I didn't understand what's your final Goal, making the EFI work on the Bike or working out the System in a engineered, but not necessarily functioning Mode for a Degree.

 

If you want to have a working System on the Bike, take a Look at Microsquirt EFI and work with this System. Bowland an Grippo have done a Lot of inventive Work and they have all you need and a Lot more. On the other Hand i'm quite sure you know the System already. I've worked on several free programmable EFI Systems and even if the Program is Windows based, there is a Lot of programming to do, without working on the Basic Functions themselves.

 

 

Well, my primary goal is to graduate. A secondary goal would be to build and sell EFI systems for off road applications: from single cylinder dirtbikes to High power drag cars.

 

Also, I forgot to add crank position sensor and cam position sensor on my list of sensors up there.

 

A tertierary gaol would be to figure out how to build a dynamometer for my garage. Among other things.

Link to comment
Share on other sites

I'm Not Progremer either, but is it easier to buy one of those power commander and modify data to your needs. I Guess bike is already pre set with all those sensors you are talking about? It's easier to modify something than build from strech up. Maybe is some forum with C++ Geeks on the web, who are willing to share brain power with you. Google baby.

 

Anyway Good Luck. :fingers-crossed-emo

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...