Basically, we can say the CAPL is the event-driven programming language. The CAPL applications can be developed to respond to the different system events such as on start, on-message, keypress, on the timer, software timers, CAN-messages, CAN bus off states, etc. There are several CAN-based functions in CAPL for the purpose of diagnostic communication that will extensively be used in the preferred project for the UDS protocol communication between the test environment and the ECU during to the software flashing process. This will enable the reuse of the commonly used variables and functions. Maximum support for one or more communication channels.

Author:Akim Faezragore
Language:English (Spanish)
Published (Last):10 July 2016
PDF File Size:2.55 Mb
ePub File Size:17.72 Mb
Price:Free* [*Free Regsitration Required]

ID ; this. Also, you do not have to output the messages to the opposite CAN channel — there are many possibilities for this configuration. This can be done to simulate human interaction, i. CAPL provides a random function which you can use as the basis for a random input generator. By combining timers with random numbers, random inputs can be achieved by sending messages on the bus or by changing the value of environmental variables.

We will show an example of a system that uses two rolls of the die to determine how long to wait between inputs and which input to use. If you are using CANoe, your inputs will probably correspond to environmental variables. However, if you are using CANalyzer, your inputs will probably be in the form of messages. For this example, we will use a set of three different inputs.

The first will be an environmental variable, the second a CAPL-declared message, and the third a database-defined message. The environmental variable, as required, is defined in the associated database. We need to declare a timer to keep track of when the next random input should occur. Finally, we declare maxMsDelay and minMsDelay to represent the maximum and minimum number of milliseconds between random inputs.

The following code is from the Global Variables window upper right corner.


CAPL Documentation

Thisfacility can be used to create a cyclic event if you reset the timer at the end of the timer event procedure. Timers can also be used to respond to an event after a delay. The setTimer function takes two parameters, the name of the timer and the length of time to setthe timer. The length of time parameter has different units depending on what kind of timer youare using.


C Tutorial


16N50C3 PDF

CAPL Language


Related Articles