![]() |
Speeduino
|
Functions | |
| uint16_t | PW (int REQ_FUEL, byte VE, long MAP, uint16_t corrections, int injOpen) |
| This function calculates the required pulsewidth time (in us) given the current system state. | |
| uint16_t | calculatePWLimit () |
| void | calculateStaging (uint32_t pwLimit) |
Variables | |
| uint16_t | req_fuel_uS = 0 |
| uint16_t | inj_opentime_uS = 0 |
| uint16_t | staged_req_fuel_mult_pri = 0 |
| uint16_t | staged_req_fuel_mult_sec = 0 |
| uint16_t calculatePWLimit | ( | ) |




This function calculates the required pulsewidth time (in us) given the current system state.
| REQ_FUEL | The required fuel value in uS, as calculated by TunerStudio |
| VE | Lookup from the main fuel table. This can either have been MAP or TPS based, depending on the algorithm used |
| MAP | In KPa, read from the sensor (This is used when performing a multiply of the map only. It is applicable in both Speed density and Alpha-N) |
| corrections | Sum of Enrichment factors (Cold start, acceleration). This is a multiplication factor (Eg to add 10%, this should be 110) |
| injOpen | Injector opening time. The time the injector take to open minus the time it takes to close (Both in uS) |


| uint16_t inj_opentime_uS = 0 |
The injector opening time. This is set within Tuner Studio, but stored here in uS rather than mS
| uint16_t req_fuel_uS = 0 |
The required fuel variable (As calculated by TunerStudio) in uS
| uint16_t staged_req_fuel_mult_pri = 0 |
| uint16_t staged_req_fuel_mult_sec = 0 |