rusEFI
The most advanced open source ECU
engine_state_generated.h
Go to the documentation of this file.
1 // this section was generated automatically by rusEFI tool config_definition_base-all.jar based on (unknown script) controllers/algo/engine_state.txt Wed Apr 17 22:33:58 UTC 2024
2 // by class com.rusefi.output.CHeaderConsumer
3 // begin
4 #pragma once
5 #include "rusefi_types.h"
6 // start of LuaAdjustments
7 struct LuaAdjustments {
8  /**
9  * Lua: Fuel add
10  * units: g
11  * offset 0
12  */
13  float fuelAdd = (float)0;
14  /**
15  * Lua: Fuel mult
16  * offset 4
17  */
18  float fuelMult = (float)0;
19  /**
20  offset 8 bit 0 */
21  bool clutchUpState : 1 {};
22  /**
23  offset 8 bit 1 */
24  bool brakePedalState : 1 {};
25  /**
26  offset 8 bit 2 */
27  bool acRequestState : 1 {};
28  /**
29  offset 8 bit 3 */
30  bool luaDisableEtb : 1 {};
31  /**
32  offset 8 bit 4 */
33  bool luaIgnCut : 1 {};
34  /**
35  offset 8 bit 5 */
36  bool unusedBit_7_5 : 1 {};
37  /**
38  offset 8 bit 6 */
39  bool unusedBit_7_6 : 1 {};
40  /**
41  offset 8 bit 7 */
42  bool unusedBit_7_7 : 1 {};
43  /**
44  offset 8 bit 8 */
45  bool unusedBit_7_8 : 1 {};
46  /**
47  offset 8 bit 9 */
48  bool unusedBit_7_9 : 1 {};
49  /**
50  offset 8 bit 10 */
51  bool unusedBit_7_10 : 1 {};
52  /**
53  offset 8 bit 11 */
54  bool unusedBit_7_11 : 1 {};
55  /**
56  offset 8 bit 12 */
57  bool unusedBit_7_12 : 1 {};
58  /**
59  offset 8 bit 13 */
60  bool unusedBit_7_13 : 1 {};
61  /**
62  offset 8 bit 14 */
63  bool unusedBit_7_14 : 1 {};
64  /**
65  offset 8 bit 15 */
66  bool unusedBit_7_15 : 1 {};
67  /**
68  offset 8 bit 16 */
69  bool unusedBit_7_16 : 1 {};
70  /**
71  offset 8 bit 17 */
72  bool unusedBit_7_17 : 1 {};
73  /**
74  offset 8 bit 18 */
75  bool unusedBit_7_18 : 1 {};
76  /**
77  offset 8 bit 19 */
78  bool unusedBit_7_19 : 1 {};
79  /**
80  offset 8 bit 20 */
81  bool unusedBit_7_20 : 1 {};
82  /**
83  offset 8 bit 21 */
84  bool unusedBit_7_21 : 1 {};
85  /**
86  offset 8 bit 22 */
87  bool unusedBit_7_22 : 1 {};
88  /**
89  offset 8 bit 23 */
90  bool unusedBit_7_23 : 1 {};
91  /**
92  offset 8 bit 24 */
93  bool unusedBit_7_24 : 1 {};
94  /**
95  offset 8 bit 25 */
96  bool unusedBit_7_25 : 1 {};
97  /**
98  offset 8 bit 26 */
99  bool unusedBit_7_26 : 1 {};
100  /**
101  offset 8 bit 27 */
102  bool unusedBit_7_27 : 1 {};
103  /**
104  offset 8 bit 28 */
105  bool unusedBit_7_28 : 1 {};
106  /**
107  offset 8 bit 29 */
108  bool unusedBit_7_29 : 1 {};
109  /**
110  offset 8 bit 30 */
111  bool unusedBit_7_30 : 1 {};
112  /**
113  offset 8 bit 31 */
114  bool unusedBit_7_31 : 1 {};
115 };
116 static_assert(sizeof(LuaAdjustments) == 12);
117 
118 // start of speed_density_s
120  /**
121  * Air: Charge temperature estimate
122  * units: deg C
123  * offset 0
124  */
125  scaled_channel<int16_t, 100, 1> tCharge = (int16_t)0;
126  /**
127  * need 4 byte alignment
128  * units: units
129  * offset 2
130  */
131  uint8_t alignmentFill_at_2[2];
132  /**
133  * Air: Charge temperature estimate K
134  * offset 4
135  */
136  float tChargeK = (float)0;
137 };
138 static_assert(sizeof(speed_density_s) == 8);
139 
140 // start of cranking_fuel_s
142  /**
143  * Fuel: cranking CLT mult
144  * offset 0
145  */
147  /**
148  * Fuel: cranking TPS mult
149  * offset 4
150  */
151  float tpsCoefficient = (float)0;
152  /**
153  * Fuel: cranking duration mult
154  * offset 8
155  */
156  float durationCoefficient = (float)0;
157  /**
158  * Fuel: Cranking cycle mass
159  * units: mg
160  * offset 12
161  */
162  scaled_channel<uint16_t, 100, 1> fuel = (uint16_t)0;
163  /**
164  * need 4 byte alignment
165  * units: units
166  * offset 14
167  */
169 };
170 static_assert(sizeof(cranking_fuel_s) == 16);
171 
172 // start of engine_state_s
174  /**
175  * offset 0
176  */
178  /**
179  * offset 12
180  */
182  /**
183  * offset 20
184  */
186  /**
187  * @@GAUGE_NAME_FUEL_BARO_CORR@@
188  * offset 36
189  */
190  float baroCorrection = (float)0;
191  /**
192  * Detected Board ID
193  * units: id
194  * offset 40
195  */
196  int16_t hellenBoardId = (int16_t)0;
197  /**
198  * @@INDICATOR_NAME_CLUTCH_UP@@
199  * offset 42
200  */
201  int8_t clutchUpState = (int8_t)0;
202  /**
203  * @@INDICATOR_NAME_CLUTCH_DOWN@@
204  * offset 43
205  */
206  int8_t clutchDownState = (int8_t)0;
207  /**
208  * @@INDICATOR_NAME_BRAKE_DOWN@@
209  * offset 44
210  */
211  int8_t brakePedalState = (int8_t)0;
212  /**
213  * offset 45
214  */
215  int8_t startStopState = (int8_t)0;
216  /**
217  * offset 46
218  */
219  int8_t smartChipState = (int8_t)0;
220  /**
221  * offset 47
222  */
223  int8_t smartChipRestartCounter = (int8_t)0;
224  /**
225  * offset 48
226  */
227  int8_t smartChipAliveCounter = (int8_t)0;
228  /**
229  * need 4 byte alignment
230  * units: units
231  * offset 49
232  */
234  /**
235  offset 52 bit 0 */
237  /**
238  * Harley ACR Active
239  offset 52 bit 1 */
240  bool acrActive : 1 {};
241  /**
242  offset 52 bit 2 */
244  /**
245  offset 52 bit 3 */
246  bool heaterControlEnabled : 1 {};
247  /**
248  offset 52 bit 4 */
249  bool luaDigitalState0 : 1 {};
250  /**
251  offset 52 bit 5 */
252  bool luaDigitalState1 : 1 {};
253  /**
254  offset 52 bit 6 */
255  bool luaDigitalState2 : 1 {};
256  /**
257  offset 52 bit 7 */
258  bool luaDigitalState3 : 1 {};
259  /**
260  offset 52 bit 8 */
261  bool unusedBit_21_8 : 1 {};
262  /**
263  offset 52 bit 9 */
264  bool unusedBit_21_9 : 1 {};
265  /**
266  offset 52 bit 10 */
267  bool unusedBit_21_10 : 1 {};
268  /**
269  offset 52 bit 11 */
270  bool unusedBit_21_11 : 1 {};
271  /**
272  offset 52 bit 12 */
273  bool unusedBit_21_12 : 1 {};
274  /**
275  offset 52 bit 13 */
276  bool unusedBit_21_13 : 1 {};
277  /**
278  offset 52 bit 14 */
279  bool unusedBit_21_14 : 1 {};
280  /**
281  offset 52 bit 15 */
282  bool unusedBit_21_15 : 1 {};
283  /**
284  offset 52 bit 16 */
285  bool unusedBit_21_16 : 1 {};
286  /**
287  offset 52 bit 17 */
288  bool unusedBit_21_17 : 1 {};
289  /**
290  offset 52 bit 18 */
291  bool unusedBit_21_18 : 1 {};
292  /**
293  offset 52 bit 19 */
294  bool unusedBit_21_19 : 1 {};
295  /**
296  offset 52 bit 20 */
297  bool unusedBit_21_20 : 1 {};
298  /**
299  offset 52 bit 21 */
300  bool unusedBit_21_21 : 1 {};
301  /**
302  offset 52 bit 22 */
303  bool unusedBit_21_22 : 1 {};
304  /**
305  offset 52 bit 23 */
306  bool unusedBit_21_23 : 1 {};
307  /**
308  offset 52 bit 24 */
309  bool unusedBit_21_24 : 1 {};
310  /**
311  offset 52 bit 25 */
312  bool unusedBit_21_25 : 1 {};
313  /**
314  offset 52 bit 26 */
315  bool unusedBit_21_26 : 1 {};
316  /**
317  offset 52 bit 27 */
318  bool unusedBit_21_27 : 1 {};
319  /**
320  offset 52 bit 28 */
321  bool unusedBit_21_28 : 1 {};
322  /**
323  offset 52 bit 29 */
324  bool unusedBit_21_29 : 1 {};
325  /**
326  offset 52 bit 30 */
327  bool unusedBit_21_30 : 1 {};
328  /**
329  offset 52 bit 31 */
330  bool unusedBit_21_31 : 1 {};
331  /**
332  * offset 56
333  */
334  uint32_t startStopStateToggleCounter = (uint32_t)0;
335  /**
336  * offset 60
337  */
338  float luaSoftSparkSkip = (float)0;
339  /**
340  * offset 64
341  */
342  float luaHardSparkSkip = (float)0;
343  /**
344  * offset 68
345  */
346  float tractionControlSparkSkip = (float)0;
347  /**
348  * User-defined RPM hard limit
349  * units: rpm
350  * offset 72
351  */
352  int16_t desiredRpmLimit = (int16_t)0;
353  /**
354  * need 4 byte alignment
355  * units: units
356  * offset 74
357  */
359  /**
360  * Fuel: Injection counter
361  * offset 76
362  */
363  uint32_t fuelInjectionCounter = (uint32_t)0;
364  /**
365  * Ign: Spark counter
366  * offset 80
367  */
368  uint32_t globalSparkCounter = (uint32_t)0;
369  /**
370  * @@GAUGE_NAME_FUEL_LOAD@@
371  * offset 84
372  */
373  float fuelingLoad = (float)0;
374  /**
375  * @@GAUGE_NAME_IGNITION_LOAD@@
376  * offset 88
377  */
378  float ignitionLoad = (float)0;
379  /**
380  * units: %
381  * offset 92
382  */
383  scaled_channel<uint16_t, 100, 1> veTableYAxis = (uint16_t)0;
384  /**
385  * offset 94
386  */
387  uint8_t overDwellCounter = (uint8_t)0;
388  /**
389  * offset 95
390  */
391  uint8_t overDwellNotScheduledCounter = (uint8_t)0;
392  /**
393  * offset 96
394  */
395  uint8_t sparkOutOfOrderCounter = (uint8_t)0;
396  /**
397  * need 4 byte alignment
398  * units: units
399  * offset 97
400  */
402 };
403 static_assert(sizeof(engine_state_s) == 100);
404 
405 // end
406 // this section was generated automatically by rusEFI tool config_definition_base-all.jar based on (unknown script) controllers/algo/engine_state.txt Wed Apr 17 22:33:58 UTC 2024
scaled_channel< uint16_t, 100, 1 > fuel
uint8_t alignmentFill_at_74[2]
cranking_fuel_s crankingFuel
scaled_channel< uint16_t, 100, 1 > veTableYAxis
uint8_t alignmentFill_at_49[3]
uint8_t alignmentFill_at_97[3]
uint32_t startStopStateToggleCounter
uint8_t overDwellNotScheduledCounter
scaled_channel< int16_t, 100, 1 > tCharge