Any strange behaviour, crashing issues etc, post them here! Problems compiling the firmware should go in the General support section rather than here
By Ilotalo
#36758
I have try to figure why my tachometer is jerking. Now i catch it whit oscilloscope. Where this is coming? My pulse is 3ms.
Attachments
RPM Signal2.jpg
RPM Signal2.jpg (228.95 KiB) Viewed 8430 times
RPM Signal.jpg
RPM Signal.jpg (190.41 KiB) Viewed 8430 times
By Ilotalo
#36771
I just looked that problem and i put one code line to set zero that ms_counter after tacho is set high. That help that problem mostly.
I don't know where else this is used so i don't know side effects.
Code: Select all
  //Tacho output check
  //Tacho is flagged as being ready for a pulse by the ignition outputs. 
  if(tachoOutputFlag == READY)
  {
    //Check for half speed tacho
    if( (configPage2.tachoDiv == 0) || (tachoAlt == true) ) 
    { 
      TACHO_PULSE_LOW();
      //ms_counter is cast down to a byte as the tacho duration can only be in the range of 1-6, so no extra resolution above that is required
      tachoEndTime = (uint8_t)ms_counter + configPage2.tachoDuration;
      tachoOutputFlag = ACTIVE;
    }
    else
    {
      //Don't run on this pulse (Half speed tacho)
      tachoOutputFlag = DEACTIVE;
    }
    tachoAlt = !tachoAlt; //Flip the alternating value incase half speed tacho is in use. 
  }
  else if(tachoOutputFlag == ACTIVE)
  {
    //If the tacho output is already active, check whether it's reached it's end time
    if((uint8_t)ms_counter >= tachoEndTime)
    {
      TACHO_PULSE_HIGH();
      tachoOutputFlag = DEACTIVE;
      ms_counter = 0;
    }
  }
By noisymime
#36947
Cause of this turned out to be an overflow bug which is now fixed in the master code

@Ilotalo
Rather than setting the ms_counter to 0, all you need to do is change the >= to ==
EG:
Code: Select all
    //If the tacho output is already active, check whether it's reached it's end time
    if((uint8_t)ms_counter == tachoEndTime)
    {
      TACHO_PULSE_HIGH();
      tachoOutputFlag = DEACTIVE;
    }
User avatar
By Krycholrc
#55785
Hello
I don't want to open a new thread so I'll post here.
I have a problem with the tachometer rippling above 4000 rpm. No matter how much I set Pulse duration, it works badly (preferably at 1ms). When connecting the status analyzer, I noticed that the pulse duration is 1ms, but the time between pulses is not always the same (on the screen). At such moments the pointer jumps up a lot.
I'm using version 202202 and it's more of a software bug, how to deal with it?
I also did a test with a simple arduino program like below and the tachometer worked very well and was showing 7000rpm on the tacho.

void loop() {
digitalWrite(49, HIGH);
delay(2);
digitalWrite(49, LOW);
delay(1);
}

Regards
Attachments
RPM.png
RPM.png (5.74 KiB) Viewed 4602 times
By Ilotalo
#55814
Krycholrc wrote: Mon Mar 07, 2022 9:58 pm Hello
I don't want to open a new thread so I'll post here.
I have a problem with the tachometer rippling above 4000 rpm.
This is common problem. I have had this as long as i have used speeduino. There is few rpm areas where it apears.

Problem come's from that 1ms loop and that ms timer. I have try to resolve this but i haven't find solution for it.
User avatar
By Krycholrc
#55815
Hello

I was able to solve this problem. I did as in FW from 2018 before adding the Pulse Duration function which gives a resolution of 1ms which causes the meter to go crazy. The only drawback is you can not set the Ignition Dwell too high, in my case, max 2.8ms for a good reading of 7000RPM in BMW tacho.

In scheduledIO.ino change this line:
Code: Select all
inline void beginCoil1Charge() { if(ignitionOutputControl != OUTPUT_CONTROL_MC33810) { coil1Charging_DIRECT(); } else { coil1Charging_MC33810(); } TACHO_PULSE_LOW(); }
inline void endCoil1Charge() { if(ignitionOutputControl != OUTPUT_CONTROL_MC33810) { coil1StopCharging_DIRECT(); } else { coil1StopCharging_MC33810(); } TACHO_PULSE_HIGH(); }

inline void beginCoil2Charge() { if(ignitionOutputControl != OUTPUT_CONTROL_MC33810) { coil2Charging_DIRECT(); } else { coil2Charging_MC33810(); } TACHO_PULSE_LOW(); }
inline void endCoil2Charge() { if(ignitionOutputControl != OUTPUT_CONTROL_MC33810) { coil2StopCharging_DIRECT(); } else { coil2StopCharging_MC33810(); } TACHO_PULSE_HIGH(); }

inline void beginCoil3Charge() { if(ignitionOutputControl != OUTPUT_CONTROL_MC33810) { coil3Charging_DIRECT(); } else { coil3Charging_MC33810(); } TACHO_PULSE_LOW(); }
inline void endCoil3Charge() { if(ignitionOutputControl != OUTPUT_CONTROL_MC33810) { coil3StopCharging_DIRECT(); } else { coil3StopCharging_MC33810(); } TACHO_PULSE_HIGH(); }

inline void beginCoil4Charge() { if(ignitionOutputControl != OUTPUT_CONTROL_MC33810) { coil4Charging_DIRECT(); } else { coil4Charging_MC33810(); } TACHO_PULSE_LOW(); }
inline void endCoil4Charge() { if(ignitionOutputControl != OUTPUT_CONTROL_MC33810) { coil4StopCharging_DIRECT(); } else { coil4StopCharging_MC33810(); } TACHO_PULSE_HIGH(); }

inline void beginCoil5Charge() { if(ignitionOutputControl != OUTPUT_CONTROL_MC33810) { coil5Charging_DIRECT(); } else { coil5Charging_MC33810(); } TACHO_PULSE_LOW(); }
inline void endCoil5Charge() { if(ignitionOutputControl != OUTPUT_CONTROL_MC33810) { coil5StopCharging_DIRECT(); } else { coil5StopCharging_MC33810(); } TACHO_PULSE_HIGH(); }

inline void beginCoil6Charge() { if(ignitionOutputControl != OUTPUT_CONTROL_MC33810) { coil6Charging_DIRECT(); } else { coil6Charging_MC33810(); } TACHO_PULSE_LOW(); }
inline void endCoil6Charge() { if(ignitionOutputControl != OUTPUT_CONTROL_MC33810) { coil6StopCharging_DIRECT(); } else { coil6StopCharging_MC33810(); } TACHO_PULSE_HIGH(); }

inline void beginCoil7Charge() { if(ignitionOutputControl != OUTPUT_CONTROL_MC33810) { coil7Charging_DIRECT(); } else { coil7Charging_MC33810(); } TACHO_PULSE_LOW(); }
inline void endCoil7Charge() { if(ignitionOutputControl != OUTPUT_CONTROL_MC33810) { coil7StopCharging_DIRECT(); } else { coil7StopCharging_MC33810(); } TACHO_PULSE_HIGH(); }

inline void beginCoil8Charge() { if(ignitionOutputControl != OUTPUT_CONTROL_MC33810) { coil8Charging_DIRECT(); } else { coil8Charging_MC33810(); } TACHO_PULSE_LOW(); }
inline void endCoil8Charge() { if(ignitionOutputControl != OUTPUT_CONTROL_MC33810) { coil8StopCharging_DIRECT(); } else { coil8StopCharging_MC33810(); } TACHO_PULSE_HIGH(); }

//The below 3 calls are all part of the rotary ignition mode
inline void beginTrailingCoilCharge() { beginCoil2Charge(); }
inline void endTrailingCoilCharge1() { endCoil2Charge(); beginCoil3Charge(); } //Sets ign3 (Trailing select) high
inline void endTrailingCoilCharge2() { endCoil2Charge(); endCoil3Charge(); } //sets ign3 (Trailing select) low

//As above but for ignition (Wasted COP mode)
void beginCoil1and3Charge() { beginCoil1Charge(); beginCoil3Charge(); TACHO_PULSE_LOW(); }
void endCoil1and3Charge()   { endCoil1Charge();  endCoil3Charge(); TACHO_PULSE_HIGH(); }
void beginCoil2and4Charge() { beginCoil2Charge(); beginCoil4Charge(); TACHO_PULSE_LOW(); }
void endCoil2and4Charge()   { endCoil2Charge();  endCoil4Charge(); TACHO_PULSE_HIGH(); }

//For 6cyl wasted COP mode)
void beginCoil1and4Charge() { beginCoil1Charge(); beginCoil4Charge(); TACHO_PULSE_LOW(); }
void endCoil1and4Charge()   { endCoil1Charge();  endCoil4Charge(); TACHO_PULSE_HIGH(); }
void beginCoil2and5Charge() { beginCoil2Charge(); beginCoil5Charge(); TACHO_PULSE_LOW(); }
void endCoil2and5Charge()   { endCoil2Charge();  endCoil5Charge(); TACHO_PULSE_HIGH(); }
void beginCoil3and6Charge() { beginCoil3Charge(); beginCoil6Charge(); TACHO_PULSE_LOW(); }
void endCoil3and6Charge()   { endCoil3Charge();  endCoil6Charge(); TACHO_PULSE_HIGH(); }

//For 8cyl wasted COP mode)
void beginCoil1and5Charge() { beginCoil1Charge(); beginCoil5Charge(); TACHO_PULSE_LOW(); }
void endCoil1and5Charge()   { endCoil1Charge();  endCoil5Charge(); TACHO_PULSE_HIGH(); }
void beginCoil2and6Charge() { beginCoil2Charge(); beginCoil6Charge(); TACHO_PULSE_LOW(); }
void endCoil2and6Charge()   { endCoil2Charge();  endCoil6Charge(); TACHO_PULSE_HIGH(); }
void beginCoil3and7Charge() { beginCoil3Charge(); beginCoil7Charge(); TACHO_PULSE_LOW(); }
void endCoil3and7Charge()   { endCoil3Charge(); endCoil7Charge(); TACHO_PULSE_HIGH(); }
void beginCoil4and8Charge() { beginCoil4Charge(); beginCoil8Charge(); TACHO_PULSE_LOW(); }
void endCoil4and8Charge()   { endCoil4Charge(); endCoil8Charge(); TACHO_PULSE_HIGH(); }
In timers.ino uncoment all tacho output like this:
Attachments
Zrzut ekranu 2022-03-09 090324.png
Zrzut ekranu 2022-03-09 090324.png (48.72 KiB) Viewed 4510 times
User avatar
By pazi88
#55817
Yes the current way of having configurable tacho pulse duration is really crappy in sense of signal timing. The old way fixing it to dwell duration was much better. But not sure how to fix that and also keep the tacho pulse duration setting there.
User avatar
By Krycholrc
#55818
The above method works very well with BMW meters, provided that the ignition dwell does not exceed 2.8ms

I rewired a few grounds and tested the TPS and rel[…]

Thanks, car runs great now !!! Going to drift even[…]

sauver moteur v8

bonsoir je m appel jean marie et j habite en Franc[…]

Ignition Angle doubled?

I just erased the flash, went back to 2023-10, cre[…]

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