E67
This commit is contained in:
parent
3e9f8fe5cc
commit
f94d7ca78f
|
@ -198,6 +198,8 @@ end
|
||||||
STARTER_OUTPUT_INDEX = 0
|
STARTER_OUTPUT_INDEX = 0
|
||||||
startPwm(STARTER_OUTPUT_INDEX, 100, 0)
|
startPwm(STARTER_OUTPUT_INDEX, 100, 0)
|
||||||
|
|
||||||
|
-- 201
|
||||||
|
ECMEngineStatus = 0xC9
|
||||||
IGN_STATUS = 0x1f1
|
IGN_STATUS = 0x1f1
|
||||||
-- 0x514
|
-- 0x514
|
||||||
VIN_Part1 = 1300
|
VIN_Part1 = 1300
|
||||||
|
@ -217,11 +219,15 @@ canRxAdd(IGN_STATUS, canIgnStatus)
|
||||||
-- todo: take VIN from configuration? encode VIN?
|
-- todo: take VIN from configuration? encode VIN?
|
||||||
canVin1 = { 0x47, 0x4E, 0x4C, 0x43, 0x32, 0x45, 0x30, 0x34 }
|
canVin1 = { 0x47, 0x4E, 0x4C, 0x43, 0x32, 0x45, 0x30, 0x34 }
|
||||||
canVin2 = { 0x42, 0x52, 0x32, 0x31, 0x36, 0x33, 0x36, 0x36 }
|
canVin2 = { 0x42, 0x52, 0x32, 0x31, 0x36, 0x33, 0x36, 0x36 }
|
||||||
|
dataECMEngineStatus = { 0x84, 0x09, 0x99, 0x0A, 0x00, 0x40, 0x08, 0x00 }
|
||||||
|
|
||||||
function onTick()
|
function onTick()
|
||||||
txCan(1, VIN_Part1, 0, canVin1)
|
txCan(1, VIN_Part1, 0, canVin1)
|
||||||
txCan(1, VIN_Part2, 0, canVin2)
|
txCan(1, VIN_Part2, 0, canVin2)
|
||||||
|
|
||||||
|
-- good enough for fuel module!
|
||||||
|
txCan(1, ECMEngineStatus, 0, dataECMEngineStatus)
|
||||||
|
|
||||||
if isCranking then
|
if isCranking then
|
||||||
setPwmDuty(STARTER_OUTPUT_INDEX, 1)
|
setPwmDuty(STARTER_OUTPUT_INDEX, 1)
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in New Issue