Hi Sasha,
I recommend you use the Processer Expert , "Capture_LDD" or "TimerInt_LDD " both are ok .
After configuration the component , then generate code , you can see the init code .
And you can refer to the help on component , there have input capture demo , in the "Typical Usage ".
![]()

![]()
The Processor Expert can directly generate code, if you do not want use it , you can refer to the generated code to write your own code.
Have a great day,
Alice
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------