bosch 60-2 decoding

Go To Last Post
5 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hi There,

Has anyone got an AVR to sync up with a 60-2 bosch crank angle sensor?

I'm currently writing some code at the moment to do this, and just wondered if anyone else had done it?

I will be wanting to fire injectors for a specific time, at a certain time, with information from the crank angle sensor giving me revs + crank angle obviously.

Should be doing ignition timing aswell, but injectors first...

I have t/Counter 0 setup to count from an external trigger. This is tied to the crank angle output (it has been schmitt triggered, etc.)

This keeps track of teeth. I have input capture enabled in timer/counter1, which is free running at 2MHz, so ICR always holds the count of the last teeth.

A few other things for syncing with the missing teeth, but nothing major, so most of the work is done by the timers, rather than any code.

Trouble is, I now only have one timer left (T2) I will have to use this as a free running, called every uS or so timer that deals with all the engine events (inj + ign)

wish there were more timers on the AVR! :(

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Couple of places you might find more information. Check out the Megasquirt project :

http://autos.groups.yahoo.com/gr...

There are links there to the main website and so on.

Dean.

Dean 94TT
"Life is just one damn thing after another" Elbert Hubbard (1856 - 1915)

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I too have been thinking about crank angle sensor problems for a while. I think I'll program a tiny12 to give six pulses every crank tooth and feed that to a timer input on a bigger AVR. This will give me 1 degree accuracy and relieve the other AVR of the calculation.
The tiny12 would behave like an intelligent PLL and send a reset to an INT pin every 720 degrees based on the missing teeth and the cam phase.

Too bad the AVR doesn't come with interrupt priority levels, that slightly messes up the scenario.

Igor

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

"Too bad the AVR doesn't come with interrupt priority levels, that slightly messes up the scenario."

Actually it does... But they are hardcoded. The interrupt vector table is organized by priority, with the highest priority vector first, and the lowest priority vector last. So you can have proper priority if you choose your interrupts carefully. The only thing that can't be sone is have a higher, and only a higher, level interrupt interrupt a lower level handler. You can re-enable interrupt s from within your handler, but then any priority level interupt can interrupt it.

These are the hardware limitations, you can of course add a software element to this to allow for full priority handling. Look at some of the RTOS's for AVR out there (AVRX specifically)

Writing code is like having sex.... make one little mistake, and you're supporting it for life.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

This group will be a forum for people who modify any Bosch EFI system. This includes reverse engineering the chip software and add-on modules. Hot-wire MAF conversion, boost timing retards, and other external devices as well. This forum will cover all Bosch EFI systems.

http://autos.groups.yahoo.com/group/BoschDME



alt="Click here to join BoschDME">

Click to join BoschDME