Re:Setting start value of new variable (1 viewing) (1) Guest
Favoured: 0
|
|
|
TOPIC: Re:Setting start value of new variable
|
|
|
|
Setting start value of new variable 3 Months, 1 Week ago
|
|
|
Hi,
sorry for my little english.
I have a question.
I'm using CANcapture to emulate a truck can bus.
I'm using default example, and I would like to add a variable :
FUEL LEVEL.
I don't understand how I can do it, and how i can set start value for it?
After this, how i can emulate a behavior for it?
I would like to decrease it linear.
Thanks for your help.
Bye
|
|
|
|
Logged
|
|
|
The administrator has disabled public write access.
|
|
|
|
Re:Setting start value of new variable 3 Months ago
|
|
|
It sounds like the best way to do this would be to create a custom CANCapture script.
The scripts do not have built in support for timers, so what I would suggest is to use a transmitter block to send a recurring "dummy" packet that goes only to the script block. Then when the script block receives this "dummy" packet at whichever interval you set, it can then change the packet to the same PGN as the FUEL LEVEL. It will then have to insert the FUEL LEVEL value into the data where you can apply whatever function (i.e. decreasing linearly or sine wave, etc).
Regards,
Jonathan
|
|
|
|
Logged
|
|
|
The administrator has disabled public write access.
|
|
|
|
|