Here's my current (29/05/2005) config and tables:
http://www.vems.hu/files/MembersPage/JasonRussell/may2005config.txt
http://www.vems.hu/files/MembersPage/JasonRussell/may2005tables.txt
The below is really old information. Please consider that if reading and looking for information.
I am in the process of installing a Genboard v3.1 in my 1988 Mazda RX7.
- primary trigger: I had a 24 tooth trigger (no missing teeth). modified to be 12-1,12-1 (two missing teeth from the 24 180 degrees apart)
- I guess the teeth are gone now, but just wondering: why not removed just 1 tooth for 24-1 ?
- secondary trigger: I had a 2 tooth trigger (equally spaced) for trigg2 (home signal): I used a grinder to make this a 1 tooth trigger so cam_sync would work (hopefully).
I get this from Haltech tuners. Haltech is by far the most popular ECU for RX7's.\n
# Haltech setup from Hitman (modify to work with VEMS) # Factory CAS alignment # Use tooth offset (trigger_tooth) = 11 # Trigger angle = 65 degrees # Multitooth trigger # 24 teeth # 4.5mS dwell # falling output edge (coil fire) # trigger1, bit0 0:falling/1:rising, bit1 0:toothwheel/1:coil, bit2 0:no filtering/1:filtering # rising trigger for RX7 CAS - 24 tooth (binary: 111) primary_trigger=07 # trigger2, bit0 0:falling/1:rising, bit1 0:enable/1:disable, bit2 0:no filtering/1:filtering, bit3 0:toothwheel/1:coil, bit4 0:alien advance/1:cam sync, bit5 0:single edge/1:both edges when cranking # rising trigger for RX7 CAS - 1 tooth # Binary: 011101 (rising, enabled, filtering, coil, camsync, single edge) secondary_trigger=1D # tooth wheel, active trigger tooth (00:missing tooth), # # after the missing tooth, ign_tdcdelay = 62 now # so that trigger tooth is ~60 degrees BTDC # This doesn't matter with coil type trigger (no missing teeth on wheel) trigger_tooth=0B tooth_wheel=18 # 24 teeth crank_minper=50 # for std. coil tach signal ** Question about below... what do I do for a non-"missing tooth" setup? # measured 115 degrees from first tooth after missing tooth to cyl#1 tdc #ign_tdcdelay=7C # 62 degrees = 110 (from missing tooth) - 48 (trigger tooth * 6) # good range for rx7 coils: 4.5-5.0mS. # 0x46(70 dec) * 64 usec = 4480 usec when VBatt >= 14V ign_dwell14=46 # dwell6 = (dwell14 * 1.2 * 64) / 27 # add 199 * 27 usec = 5373 usec to dwell14 when VBatt = 6V ign_dwell6=C7 # crank advance = 20 degrees ign_crank_advance=50 ign_out=70 # EDIS:0x0? dummy: 0x7? disable:0xff bit0: invertout ignchmax=01 # CAMSYNC ##################################################################### # the idea here is to use a phase variable internally, that goes from 0 .. reset_engphase_after (practically 240 decimal in your case), all variables are related to that. cam_sync_f_edge_phase=00 cam_sync_r_edge_phase=78 # (cam_sync_f_edge_phase + reset_engphase_after/2) % reset_engphase_after if it's 360 crankdegrees after from falling edge. reset_engphase_after=F0 tooth_wheel_twidth1=05 # reset_engphase_after / 48 tooth_wheel_twidth2=0A
Please make a list of events associted with your trigger:
it will probably have
- 48 crankteeth (-missing ones), only falling edge counts
- 1 camtooth rising, 1 camtooth falling edge (with VR only falling counts)
- TDC (or whatever it's called for rotary)
You can use some abbreviations, but the relation of TDC vs. the syncs are important.
You can look at timing.c update_engphase() and write the engine.engphase in your list of events.
Ok, I see a few problems here: cam sync doesn't do anything when using coil type trigger (comment in timing.c says "the argument is 0 when not using a tooth wheel trigger"). I can't use toothwheel type because I have no missing teeth.
The trigger events for 720 degrees of crank rotation (normal 4 cyl engine cycle) are:
- TDC (camsync)
- 15 crank degrees delay (15 crankdegrees looks suitably large, so the order of campulse and crankpulse can never change here), then starts:
- skip 1 crankwheel signal, fire coil 1 on following tooth (2nd after TDC - total of 45 deg ATDC) to ignite cylA
- skip 5 crankwheel signals, fire coil 1 on 8th tooth, to ignite cylB
- skip 5 crankwheel signals, fire coil 1 on 14th tooth, to ignite cylA
- skip 5 crankwheel signals, fire coil 1 on 20th tooth, to ignite cylB
24 crankwheel signals (30 crank degrees apart: 720 crankdegrees altogether). As you see, in _my_ setup there's only one coil. It fires 4 times per 720 crank degrees.
So this looks like an 8 cyl engine with a multitooth trigger, except the 24 cranktrigger doesn't miss a tooth. Starts to make sense (I really didn't want to make code changes before laying these out clearly). A few more issues:
- it's quite unlikely that you want constant ignition advace as you wrote above. Please find the latest reasonable point of ignition (this we call TDC and configure with ign_tdcdelay normally, although there is nothing to prevent someone to set this later than tdc). Identify the earliest possible time of ignition (this is easy after having the latest, simply tell max ignadv ever applied).
- I will decipher the Haltech base maps to find what others are running with my setup and post the table.
500 | 1000 | 1500 | 2000 | 2500 | 3000 | 3500 | 4000+ |
13 | 15 | 17 | 24 | 33 | 38 | 40 | 38 |
- provide ballpark info on your coil's dwell
- I specified this at the top of the page. 4.5mS
- target RPM-range (I guess 100...15000 RPM should do)
- I've never seen a rotary run over 13000, so 14-15k should be enough. Mine will be 10,500 max.
- we'll want to see the leading sparks as well to see what overlap conditions are there
- I'm not clear on your meaning here, but I'll take a guess.
- I'm specifying leading sparks. The trailing (second plug) is easy... 15 crank degrees after leading. All the time, AFAIK. I'm not running trailing though, 99% of it's purpose is emissions.
- can you make a diagram with all 3 output coilsignals and both 2 inputtrigger (or at least the cam, as crank from it is very clear) signals in it? (the input can be just vertical lines, as we only care about the falling edge of the VR)
- Yes, I will work on that.
In a normal RX7, there's two of the TDC signals (second one is just before the 12th tooth). We need to make this work at some point. I now have a 24&1 tooth and a 24&2 tooth trigger-sets, so I can test both setups. There's also 3 coils in a standard setup. We'll need to support this at some time. I don't mind taking on the code changes needed for the 3 coil setup.
Standard (idle) timing is 5 degrees ATDC (ATDC?? not BTDC?) for coil 1 (wastespark), 20 degrees ATDC for coil 2 & 3 (one for each rotor)
=Trigger Problem=
the 2 VR sensors output good waves, the lm1815 get good inputs, the lm1815 output looks good, but the RPM doesn't show up. In MegaTunix the status changes to "RUNNING" when I spin the VR sensor, so it's working in some capacity. Please help. I am on short deadline to get the car running (24 hours left!)
primary_trigger is setup for toothwheel but the wheel doesn't miss a tooth. When no missing tooth then RPM calc will NOT be triggered: it explains everything. I guess you need the teeth for mechanical reasons. The secondary trigger should probably fire RPM-calc and sync the teeth.
No matter what the divider is set to, I get an RPM of ~1400-1500 at cranking. RX7's have high speed (versus high torque) starters, but I know they aren't THAT high. ;-) Should be 350-500 RPM cranking. 24 tooth divided by 06 should be 4 triggers on the primary, exactly what I need for wasted spark. Please provide full commented config, not just extracts. Very easy to miss a constant, eg. rpm_k[] or config11..13 would be interesting here.
The cam_sync setup isn't documented at all (that I could find) here in the wiki and global.h either isn't clear to me or has no useful information about cam_sync. I would love to put a new page under the Manual, but the manual is disappearing from the wiki. *shrug* Yep, that's a problem, it's impossible to maintain that way. (or even to read it, very often).
2004-09-15 Trigger confusion
I got a little bit frustrated today at the trigger confusion I have with the coil type trigger not producing the correct output and camsync not working. I ground a tooth off the 24 tooth wheel (now it's 23-1). Set my trigger1=05 and tooth_wheel=17 (23). It's a reasonable RPM now! The injectors are firing. The injector lightbulb glows when I spin the sensor with the drill (~200 engine RPM). I used scope channel 2 connected to the IGBT and injector FETs, but I see only one pulse per CAM rotation. That's probably normal for injectors (alternate=03) however the engine won't run very happily with only one spark per 720 crank degrees. Any ideas here that I can try to fix this? I only have one coil (dual post wastespark) so it should fire 4 times per 720 crank degree cycle.
Jason,
If i understand correctly you have created a multitooth setup now (23-1) and you want to fire a single coil 4 times per cam revolution (720 crank degrees). Lets start out with the firmware, you wil have to compile the code with this added to my_make\n
# enable the coil to fire twice per crank revolation (on trigger # tooth and on trigger tooth + 12) MY_CONF += -D ANOTHER_TRIGGER_TOOTH=12
config variables:\nÿ3ÿ
if you set everything up like above you should be able to produce 4 sparks per cam rotation, and 4 injections too (you can adjust config.divider to fire less often) - DB