For anything you'd like to see added to Speeduino
By dazq
#34748
You can have 6cyl sequential ignition but you can only have banked or batched fuel. This is a timer limit in the mega 2560.
By ksanislo
#34773
FWIW, that timer limit seems fairly trivial to work around with interrupt sharing. Since they're all pre-scheduled with a known order in advance, it just needs to build a rolling list of upcoming events as they're scheduled, and have the ISR() do the lookup and jump to the requisite function as they come through. The doing an additional lookup against a list shouldn't take many cycles, and should still be faster than a single click of the timer at it's set multiplier, and can probably be directly wrapped around most of the existing code.
User avatar
By pazi88
#34774
ksanislo wrote: Wed May 15, 2019 8:09 pm FWIW, that timer limit seems fairly trivial to work around with interrupt sharing. Since they're all pre-scheduled with a known order in advance, it just needs to build a rolling list of upcoming events as they're scheduled, and have the ISR() do the lookup and jump to the requisite function as they come through. The doing an additional lookup against a list shouldn't take many cycles, and should still be faster than a single click of the timer at it's set multiplier, and can probably be directly wrapped around most of the existing code.
But how can you make a list of upcoming events, like injection times, if you don't have ability to forecast future and know how and when driver will use thorttle?
By ksanislo
#34775
pazi88 wrote:But how can you make a list of upcoming events, like injection times, if you don't have ability to forecast future and know how and when driver will use thorttle?
The same way they're being scheduled in advance right now. You'd have to rebuild everything post-timer-change in the list which could be a handful of items, so there's a bit of overhead added, but that part of the code doesn't happen directly in the ignition/injection ISR routines and isn't as tight on timing. The impact can also be reduced by pooling the crank timing across more than one timer, as there's no reason everything would have to be done on the same interrupt even if they're being shared.
By GhjEng
#39989
Hi guys...

Just a thought on 6-Cyl sequential fueling on the mega. @pazi88, I’m a fan of your YouTube channel so I know you’re Hans with programming. I’m also fairly advanced with Arduino... just a thought... can we not split the interrupt outputs to two separate registers, then have a flag register for say Cyl 1 & Cyl 6? Then an if condition... something like, IF “interrupt”, AND “Cyl 1” true, then inject. Cyl 1 to False, Cyl 6 to True... and then use the reverse for when Cyl 1 is False...? That way you only use one interrupt for both cylinders and can just add an extra injector output...?

If anyone that’s any good with Arduino wants to let me know your thoughts? It would be like running a mini task-scheduler for each injector pair so you can split them to separate physical outputs.
User avatar
By pazi88
#39990
GhjEng wrote: Fri Dec 20, 2019 8:30 am Hi guys...

Just a thought on 6-Cyl sequential fueling on the mega. @pazi88, I’m a fan of your YouTube channel so I know you’re Hans with programming. I’m also fairly advanced with Arduino... just a thought... can we not split the interrupt outputs to two separate registers, then have a flag register for say Cyl 1 & Cyl 6? Then an if condition... something like, IF “interrupt”, AND “Cyl 1” true, then inject. Cyl 1 to False, Cyl 6 to True... and then use the reverse for when Cyl 1 is False...? That way you only use one interrupt for both cylinders and can just add an extra injector output...?

If anyone that’s any good with Arduino wants to let me know your thoughts? It would be like running a mini task-scheduler for each injector pair so you can split them to separate physical outputs.
Well that would work for ignition but not really viable solution for injection, because to achieve over 50% duty for injectors, you need to inject for longer than one crank rotation. Which means that you would need to open the injector output 2 well before injector output 1 has closed. And doing that with one timer only and changing outputs isn't easy thing to do.

But well when we are in this topic, here's branch that has 6-cyl fully sequential for mega: https://github.com/pazi88/speeduino/tre ... ential_BMW

It's based on Ileeezi's code where he arranged timers differently so that ignition 4 and 5 timers are used to injection 5 and 6. Because those are not really used in 6 cyl case. All other functions remain in use. Then there is that kind of output switching for ignition side. It basically runs as wasted spark, but alters the outputs to do sequential ignition. Technically it's not "real" sequential ignition because dwell times are limited to half of what "real" sequential ignition allows. But for example this system can do 7.5ms of dwell at 7000 RPM. So I don't think it's a problem even if the full 16ms of dwell can't be done . Main benefit from that is to reduce heat load to ignition system when running higher dwell values.

I have tested that in bench quite well and this is scope trace of the ignition outputs. Yeallow line is cam signal:
Image
By GhjEng
#41285
Hmmmm,

@pazi88
Well that would work for ignition but not really viable solution for injection, because to achieve over 50% duty for injectors, you need to inject for longer than one crank rotation. Which means that you would need to open the injector output 2 well before injector output 1 has closed. And doing that with one timer only and changing outputs isn't easy thing to do.

Loose thought here off the top of my head... what about a hardware shift-register chip? Like is used for 7-segment LED displays? Firing order won't change... like I say, havn't thought this through fully yet, but say the shift register has eight outputs.. first ignition pulse goes to output 1 (Then to ignition driver), second ignition pulse goes to output 2, and so on...

Would just need an option in the code to keep tack of the "pulse division" which happens...

Any thoughts on this? In theory there wouldn't be a limit to the number of injector or ignition outputs anymore, due to timer availability on the mega. Just add a shift register, then ignition/injector electronics after the shift register output...?

https://www.sparkfun.com/products/13699

I suppose this isn't really addressing the "sequential" issue for 6+ cylinders... rather helps open speeduino out to 8+ cylinders relatively cheaply... however, with a bit of code tweaking, it could be configure to allow 6+ cylinder sequential.

I must add that I know there is no significant benefit to full sequential and don't need it myself... but I had the thought and guessed I would get an opinion.
By JHolland
#41288
That is similar to the way that early Miatas work - the drawback is that you limit the maximum possible injector opening period.
By Rocket
#41291
Why counter ic like cd4070 is not suitable for sequencing between cylinders? only clock signal is necessary

Had it running for a short period again. Same as […]

Ok, here is the first version of the adapter plate[…]

Ignition Angle doubled?

don't load your old tune in case it is corrupted[…]

Yes, totally wrong setting. Slight noise in TPS ca[…]

Still can't find what you're looking for?