by gtihk on Fri Aug 31, 2018 4:58 pm
Please comment.
the Project currently validated with no errors.
Scheduled Function :
local rx = false;
local rxtimeout = false;
local anytimeout = false;
local <Unsigned Integer> h = 0;
/*
* Message 0x43F
*/
h = CanComms.RxOpenStandard(0, 0x43F, 0x000, true);
rx = CanComms.RxMessage(h);
rx = CanComms.RxMessage(h) or rx;
rxtimeout = Delay.Rising(not rx, 0.5);
anytimeout = anytimeout or rxtimeout;
if (rx)
{
if (CanComms.GetBit(h,0))
{
Gear.Neutral Switch State = Gear.Neutral Switch State.Off;
}
else
{
Gear.Neutral Switch State = Gear.Neutral Switch State.On;
}
}